Peter Melnichenko

Results 117 comments of Peter Melnichenko

Luarocks could split out the revision itself, of course.

> Which brings me to an alternate idea: we already have a branch field: why not just allow commit hashes in there too? (that works with some git sub commands...

But then we have to always clone full repo.

And in hererocks I do full clone if the ref is hexadecimal and pass it to `--branch` otherwise. But for LuaRocks I don't think there is need to overload `source.branch`...

I think it should work if the path is quoted as usual and then `*.*` is simply appended, should be easier to implement.

Seems like to fix this we need _proper_ argument quoting :smile: ``` win32\tools\cp -d -R ^"lua 2\*.*^" ^"lua 3^" ``` I've recently implemented it in [penlight](https://github.com/stevedonovan/Penlight/blob/1.4.1/lua/pl/utils.lua#L230-L259).

At least, this works for me? I'll test it a bit more.

By the way, I can't reproduce the original issue for some reason: the copy command succeeds and files appear in lua dir. However, something else then clears the directory before...

For reference, when I install lua-cjson using `luarocks make` it executes a command similar to yours: `C: & cd "C:\Users\mpete\lua-cjson" & "C:\Users\mpete\lua53\luarocks\tools\cp" "-dR" "lua\*.*" "c:\users\mpete\lua53\\lib\luarocks\rocks\lua-cjson\2.1devel-1\lua"`, except it runs fine.

@moteus can you reproduce the problem if you use `fs.copy_contents` directly? You'll probably need to add path to luarocks sources to `package.path` for it to word, like it's done in...