3 # Change an existing remote branch repository URL
4 # Copyright (c) Petr Baudis, 2005
6 # Takes the branch name and new source location as parameters.
8 # Terminology note: This command concerns remote branches, not the local
9 # ones (those managed by `cg-switch`).
13 USAGE
="cg-branch-chg BRANCH_NAME NEW_LOCATION"
16 .
"${COGITO_LIB}"cg-Xlib ||
exit 1
20 ([ -n "$name" ] && [ -n "$location" ]) || usage
22 [ -s "$_git/branches/$name" ] || die
"branch does not exist"
23 echo "$location" >"$_git/branches/$name"