blob: 6e339a75fc7f8f14d841a3be283ca167eb2673f0 [file] [log] [blame]
Vincent Driessen61ade552010-01-21 01:28:08 +01001#!/bin/sh
Vincent Driessen093a1472010-01-21 01:36:44 +01002#
3# gitflow -- A collection of Git wrapper scripts to provide high-level
4# repository operations for Vincent Driessen's branching model:
5#
6# Original blog post presenting this model is found at:
7# http://nvie.com/archives/323
8#
9# Feel free to contribute to this project at:
10# http://github.com/nvie/gitflow
11#
12# Copyright (c) 2010 by Vincent Driessen
13#
Vincent Driessen61ade552010-01-21 01:28:08 +010014
15usage() {
16 echo "usage: gitflow start hotfix <release>"
17 echo " gitflow finish hotfix <release>"
18}
19
Vincent Driessenf7f687c2010-01-21 01:32:18 +010020parse_args() {
21 RELEASE="$1"
22 if [ "$RELEASE" = "" ]; then
23 echo "Missing argument <release>."
24 usage
25 exit 1
26 fi
27}
28
Vincent Driessen61ade552010-01-21 01:28:08 +010029start() {
30 # TODO
Vincent Driessenf7f687c2010-01-21 01:32:18 +010031 parse_args "$@"
Vincent Driessen61ade552010-01-21 01:28:08 +010032 gitflow_check_clean_working_tree
33 echo "git checkout -b hotfix-$RELEASE master"
34 echo "Bump version number"
35 echo "Fix bug"
36}
37
38finish() {
39 # TODO
Vincent Driessenf7f687c2010-01-21 01:32:18 +010040 parse_args "$@"
Vincent Driessen61ade552010-01-21 01:28:08 +010041 gitflow_check_clean_working_tree
42 echo "git checkout master"
43 echo "git merge --no-ff hotfix-$RELEASE"
44 echo "git checkout develop"
45 echo "git merge --no-ff hotfix-$RELEASE"
46 echo "git branch -d hotfix-$RELEASE"
47}
48