diff options
author | Andrei Karas <akaras@inbox.ru> | 2014-11-05 17:53:52 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2014-11-05 17:54:43 +0300 |
commit | 0628d73427b1f3461ecde5639e7b5ce8839dcbfb (patch) | |
tree | ad852379d92cd1c099a0b14d5c154a5d881fd893 | |
parent | 541a09360b35780ae599da84ef74621c599e702a (diff) | |
download | all-0628d73427b1f3461ecde5639e7b5ce8839dcbfb.tar.gz all-0628d73427b1f3461ecde5639e7b5ce8839dcbfb.tar.bz2 all-0628d73427b1f3461ecde5639e7b5ce8839dcbfb.tar.xz all-0628d73427b1f3461ecde5639e7b5ce8839dcbfb.zip |
Add ability to init.sh clone only task related repos.
Build in tasks:
all
client
server
music
default
Example: ./init.sh client
-rwxr-xr-x | init.sh | 28 |
1 files changed, 22 insertions, 6 deletions
@@ -1,11 +1,27 @@ #!/bin/bash -git clone git@gitorious.org:evol/clientdata.git client-data -git clone git@gitorious.org:evol/hercules.git server-code -git clone git@gitorious.org:evol/serverdata.git server-data -git clone git@gitorious.org:evol/evol-tools.git tools -git clone git@gitorious.org:evol/evol-hercules.git server-code/src/evol +CMD="$1" +if [[ -z "${CMD}" ]]; then + export CMD="default" +fi + +if [[ "${CMD}" == "all" || "${CMD}" == "default" ]]; then + git clone git@gitorious.org:evol/clientdata.git client-data + git clone git@gitorious.org:evol/hercules.git server-code + git clone git@gitorious.org:evol/serverdata.git server-data + git clone git@gitorious.org:evol/evol-tools.git tools + git clone git@gitorious.org:evol/evol-hercules.git server-code/src/evol +elif [[ "${CMD}" == "server" ]]; then + git clone git@gitorious.org:evol/hercules.git server-code + git clone git@gitorious.org:evol/serverdata.git server-data + git clone git@gitorious.org:evol/evol-hercules.git server-code/src/evol +elif [[ "${CMD}" == "client" ]]; then + git clone git@gitorious.org:evol/clientdata.git client-data + git clone git@gitorious.org:evol/evol-tools.git tools +elif [[ "${CMD}" == "music" ]]; then + git clone git@gitorious.org:evol/evol-music.git music +fi -if [[ "$1" == "all" ]]; then +if [[ "${CMD}" == "all" ]]; then git clone git@gitorious.org:evol/evol-music.git music fi |