run command, cd in build and clean

main
xenia 2023-08-15 12:23:55 +02:00
parent 1201987364
commit c91c80c63f
1 changed files with 16 additions and 2 deletions

View File

@ -50,12 +50,26 @@ setupDb() {
P="$PWD"
clean() {
cd "$(git rev-parse --show-toplevel)"
log "Rensar byggnad"
rm -rf artifacts
cd - >/dev/null
}
build() {
source "$P/buildScripts/build.sh"
cd "$(git rev-parse --show-toplevel)"
( source "buildScripts/build.sh" )
RES=$?
cd - >/dev/null
return $RES
}
run() {
build && {
cd "$(git rev-parse --show-toplevel)"
./artifacts/Main
cd - >/dev/null
}
}
if [ "$IS_OWNER" -ne 0 ] ; then
@ -68,4 +82,4 @@ log "Redo" "!"
set +e
cd - >/dev/null 2>&1
cd - >/dev/null