forked from openshift-metal3/dev-scripts
-
Notifications
You must be signed in to change notification settings - Fork 0
/
03_ocp_repo_sync.sh
executable file
·51 lines (38 loc) · 1.55 KB
/
03_ocp_repo_sync.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
#!/bin/bash
set -ex
source common.sh
eval "$(go env)"
echo "$GOPATH" | lolcat # should print $HOME/go or something like that
function sync_go_repo_and_patch {
DEST="$GOPATH/src/$1"
figlet "Syncing $1" | lolcat
if [ ! -d $DEST ]; then
mkdir -p $DEST
git clone $2 $DEST
fi
pushd $DEST
git am --abort || true
git checkout master
git pull --rebase origin master
git branch -D we_dont_need_no_stinkin_patches || true
git checkout -b we_dont_need_no_stinkin_patches
shift; shift;
for arg in "$@"; do
curl -L $arg | git am
done
popd
}
# sync_go_repo_and_patch github.com/openshift/origin https://github.com/openshift/origin.git
# sync_go_repo_and_patch github.com/openshift/release https://github.com/openshift/release.git
# sync_go_repo_and_patch github.com/openshift/machine-config-operator https://github.com/openshift/machine-config-operator.git
# sync_go_repo_and_patch github.com/openshift/machine-api-operator https://github.com/openshift/machine-api-operator.git
sync_go_repo_and_patch github.com/metalkube/kni-installer https://github.com/metalkube/kni-installer.git
# sync_go_repo_and_patch github.com/openshift/ci-operator https://github.com/openshift/ci-operator.git
# sync_go_repo_and_patch github.com/sallyom/installer-e2e https://github.com/sallyom/installer-e2e.git
sync_go_repo_and_patch github.com/metalkube/facet https://github.com/metalkube/facet.git
# Build facet
go get -v github.com/rakyll/statik
pushd "${GOPATH}/src/github.com/metalkube/facet"
yarn install
./build.sh
popd