epic-ts
[kivitendo-erp.git] / build / kivitendo.co
1 #!/bin/bash
2 set -e
3
4 # parameter: $1: git tag to build
5 # options: -g <alternative repository>
6
7 #repos="https://github.com/wagner-tech"
8 #if getopts "g:" opt; then
9 #       repos=$OPTARG
10 #       shift 2
11 #fi
12 #
13 #if [ -e kivitendo-erp ]
14 #then
15 #       pushd kivitendo-erp >/dev/null
16         #branch=$(git rev-parse --abbrev-ref HEAD)
17         #git pull origin $branch
18 #else
19 #       git clone $repos/kivitendo-erp
20 #       pushd kivitendo-erp >/dev/null
21 #fi
22 #       git checkout $1
23 #popd >/dev/null
24
25 # alternativer Versuch: Es wird das lokale Repository geklont:
26
27 cwd=$(pwd)
28 git clone ${cwd%/build/src}
29 pushd kivitendo-erp >/dev/null
30         git checkout $1
31 popd >/dev/null
32