3 # Copyright (c) Josef "Jeff" Sipek, 2006, 2007
6 DO_NOT_CHECK_BRANCH_EXISTENCE
=1
11 while case $# in 0) break ;; esac; do
26 if [ -d "$GUILT_DIR/$branch" ]; then
27 die
"Branch $branch appears to be already initialized (GIT_DIR=$GIT_DIR)"
30 [ ! -d "$GUILT_DIR" ] && mkdir
"$GUILT_DIR"
31 mkdir
-p "$GUILT_DIR/$branch"
32 touch "$GUILT_DIR/$branch/series"
33 touch "$GUILT_DIR/$branch/status"
35 mkdir
-p "$GIT_DIR/hooks/guilt"
36 cat > "$GIT_DIR/hooks/guilt/delete" <<EOF
38 # Usage: <script> <patch being removed>
40 echo "Removing patch '\$1'..."
43 # if there's no guilt.autotag config, set it to default
44 cur
=`git config --int --get guilt.autotag`
45 if [ -z "$cur" -o ! -z "$req_autotag" ]; then
46 [ -z "$req_autotag" ] && req_autotag
=$AUTOTAG_DEFAULT
48 git config
--int --replace-all guilt.autotag
$req_autotag