Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions deploy.sh
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,8 @@ ${bold}OPTIONS${normal}

${bold}-c | --config${normal} Replaces a variable in all configuration files containing it. The format is 'key=value'.

${bold}-b | --branch${normal} Sets the branch name to build, by default its main.

${bold}COMPATIBILITY${normal}
The repository must be in ${bold}sisoputnfrba${normal} organization and have makefiles to compile each project or dependency.

Expand Down Expand Up @@ -92,6 +94,7 @@ LIBRARIES=()
DEPENDENCIES=()
PROJECTS=()
CONFIGURATIONS=()
BRANCH="main"

OPTIONS=("${@:1:$#-1}")
for i in "${OPTIONS[@]}"
Expand All @@ -113,6 +116,10 @@ do
CONFIGURATIONS+=("${i#*=}")
shift
;;
-b=*|--branch=*)
BRANCH=("${i#*=}")
shift
;;
*)
echo -e "\n\n${bold}Invalid option:${normal} ${i}" >&2
fail
Expand Down Expand Up @@ -161,6 +168,7 @@ echo -e "\n\n${bold}Cloning project repo...${normal}\n\n"

rm -rf "$REPONAME"
git clone "https://github.com/sisoputnfrba/${REPONAME}.git"
git -C "$REPONAME" checkout "$BRANCH"

echo -e "\n\n${bold}Building dependencies${normal}..."

Expand Down