cvsimport: add <remote>/HEAD reference in separate remotes more
[gitweb.git] / git-cvsimport.perl
index 7837c7bfb61fdbdc8313eb98f317edd4688a47c5..598b9c8da9f0e8eecac3d9ec13a1431b0466854e 100755 (executable)
@@ -1026,6 +1026,8 @@ sub commit {
        print "DONE; creating $orig_branch branch\n" if $opt_v;
        system("git-update-ref", "refs/heads/master", "$remote/$opt_o")
                unless -f "$git_dir/refs/heads/master";
+       system("git-symbolic-ref", "$remote/HEAD", "$remote/$opt_o")
+               if ($opt_r && $opt_o ne 'HEAD');
        system('git-update-ref', 'HEAD', "$orig_branch");
        unless ($opt_i) {
                system('git checkout');