Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

fix GIT_PREFIX

  • Loading branch information...
commit d908b46e18b52a555ec159d482701ff96c8f1e76 1 parent 9d1dc32
@orefalo authored
Showing with 4 additions and 3 deletions.
  1. +1 −1  cmds/g2-freeze.sh
  2. +1 −1  cmds/g2-ig.sh
  3. +2 −1  cmds/g2-undo.sh
View
2  cmds/g2-freeze.sh
@@ -4,7 +4,7 @@
[[ $1 = "-m" ]] && {
[[ -n $2 ]] && { msg=$2; shift 2; } || { echo "Usage: freeze -m message"; exit 1; }
}
-( [[ -z "$@" ]] && "$GIT_EXE" add -A || "$GIT_EXE" add -A "$GIT_PREFIX/$@" ) && {
+( [[ -z "$@" ]] && "$GIT_EXE" add -A || "$GIT_EXE" add -A "$GIT_PREFIX$@" ) && {
[[ -n $msg ]] && {
[[ $("$GIT_EXE" g2iswip) = "true" ]] && echo "fatal: wip detected, please <unwip> and commit <ci>." && exit 1
"$GIT_EXE" commit -m "$msg" && "$GIT_EXE" status -s
View
2  cmds/g2-ig.sh
@@ -2,4 +2,4 @@
#
# Ignores a file and automatically adds it to gitignore & removes from source control
-[[ -z "$@" ]] && echo "usage: ignore [file]" || { ([ ! -e .gitignore ] && touch .gitignore); echo "$GIT_PREFIX/$1" >> .gitignore && echo "Ignoring file $1" && "$GIT_EXE" rm --cached "$GIT_PREFIX/$@" > /dev/null 2>&1 && "$GIT_EXE" st; }
+[[ -z "$@" ]] && echo "usage: ignore [file]" || { ([ ! -e .gitignore ] && touch .gitignore); echo "$GIT_PREFIX$1" >> .gitignore && echo "Ignoring file $1" && "$GIT_EXE" rm --cached "$GIT_PREFIX$@" > /dev/null 2>&1 && "$GIT_EXE" st; }
View
3  cmds/g2-undo.sh
@@ -24,6 +24,7 @@ case "$1" in
echo "Reverting back prior to the last merge."
"$GIT_EXE" reset --hard ORIG_HEAD
;;
- *) "$GIT_EXE" checkout -- "$GIT_PREFIX/$1"
+ *)
+ "$GIT_EXE" checkout -- "$GIT_PREFIX$1"
;;
esac
Please sign in to comment.
Something went wrong with that request. Please try again.