only checkout the target branch when topgit is used
[?]
Jul 31, 2014, 7:42 PM
2XGB45G73ZA4FQ6EEKDOWJ5MKMDRPV6LH3WWSOJZ5CEAYW5NZJSQCDependencies
- [2]
6LRC7SIEforcing branch switch - [3]
6STC76Q6added clean command - [4]
JAH3UPWASupport revision control systems via plugins - [5]
3BTJRSU3GitInput.pm: Don't do a chdir to the Git clone
Change contents
- replacement in src/lib/Hydra/Plugin/GitInput.pm at line 42[4.7119]→[4.7119:7173](∅→∅),[4.7173]→[2.0:89](∅→∅),[2.89]→[4.1611:1711](∅→∅),[4.1611]→[4.1611:1711](∅→∅),[4.1711]→[3.0:292](∅→∅)
# Checkout the branch to look at its content.$res = run(cmd => ["git", "checkout", "--force", "$branch"], dir => $clonePath);die "error checking out Git branch '$branch' at `$uri':\n$res->{stderr}" if $res->{status};# Clean to remove potentially present artifacts after forcing branch switch$res = run(cmd => ["git", "clean", "-d", "-x", "--force", "--force"], dir => $clonePath);print STDERR "warning: `git clean -d -x --force --force' failed::\n$res->{stderr}" if $res->{status};# Is the target branch a topgit branch?$res = run(cmd => ["git", "ls-tree", "-r", "$branch", ".topgit"], dir => $clonePath); - replacement in src/lib/Hydra/Plugin/GitInput.pm at line 45
if (-f ".topdeps") {if ($res->{stdout} != "") {# Checkout the branch to look at its content.$res = run(cmd => ["git", "checkout", "--force", "$branch"], dir => $clonePath);die "error checking out Git branch '$branch' at `$uri':\n$res->{stderr}" if $res->{status};