aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorIgnacio Burgueño <ignaciob@inconcertcc.com>2012-05-11 17:00:07 -0300
committerIgnacio Burgueño <ignaciob@inconcertcc.com>2012-05-11 17:00:07 -0300
commit838c54621041ddd2ab905729dc25a9aca2284238 (patch)
tree2ddef11c6612a3152e7726db656493904ed9d3d5 /src
parentf0eb7d195ddb73eb292cfb62ae9f25f328392808 (diff)
downloadluarocks-838c54621041ddd2ab905729dc25a9aca2284238.tar.gz
luarocks-838c54621041ddd2ab905729dc25a9aca2284238.tar.bz2
luarocks-838c54621041ddd2ab905729dc25a9aca2284238.zip
Clone using --branch flag when needed.
Diffstat (limited to 'src')
-rw-r--r--src/luarocks/fetch/git.lua5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/luarocks/fetch/git.lua b/src/luarocks/fetch/git.lua
index c7cc7008..0b33e76b 100644
--- a/src/luarocks/fetch/git.lua
+++ b/src/luarocks/fetch/git.lua
@@ -26,8 +26,9 @@ function get_sources(rockspec, extract, dest_dir)
26 local checkout_command 26 local checkout_command
27 local tag_or_branch = rockspec.source.tag or rockspec.source.branch 27 local tag_or_branch = rockspec.source.tag or rockspec.source.branch
28 if tag_or_branch then 28 if tag_or_branch then
29 -- ensure the branch is available 29 -- ensure the branch (or tag) is available
30 table.insert(command, 4, "--no-single-branch") 30 table.insert(command, 4, "--branch")
31 table.insert(command, 5, tag_or_branch)
31 checkout_command = {git_cmd, "checkout", tag_or_branch} 32 checkout_command = {git_cmd, "checkout", tag_or_branch}
32 end 33 end
33 local store_dir 34 local store_dir