forked from platypush/platypush
🐛 [CI/CD] Fixed build-ui.sh script.
After doing "cd $SRCDIR", it should reference the `dist` directory in the webapp by full relative path.
This commit is contained in:
parent
22cfe777fa
commit
ed697c0ad2
1 changed files with 4 additions and 3 deletions
|
@ -1,12 +1,13 @@
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
|
|
||||||
export SRCDIR="$PWD"
|
export SRCDIR="$PWD"
|
||||||
|
export WEBAPP_DIR="$SRCDIR/platypush/backend/http/webapp"
|
||||||
export SKIPCI="$PWD/.skipci"
|
export SKIPCI="$PWD/.skipci"
|
||||||
rm -rf "$SKIPCI"
|
rm -rf "$SKIPCI"
|
||||||
|
|
||||||
. .drone/macros/configure-git.sh
|
. .drone/macros/configure-git.sh
|
||||||
|
|
||||||
cd platypush/backend/http/webapp
|
cd "$WEBAPP_DIR"
|
||||||
if [ $(git log --pretty=oneline $DRONE_COMMIT_AFTER...$DRONE_COMMIT_BEFORE . | wc -l) -eq 0 ]; then
|
if [ $(git log --pretty=oneline $DRONE_COMMIT_AFTER...$DRONE_COMMIT_BEFORE . | wc -l) -eq 0 ]; then
|
||||||
echo "No UI changes detected, skipping build"
|
echo "No UI changes detected, skipping build"
|
||||||
exit 0
|
exit 0
|
||||||
|
@ -35,8 +36,8 @@ cd "$SRCDIR"
|
||||||
. .drone/macros/configure-ssh.sh
|
. .drone/macros/configure-ssh.sh
|
||||||
. .drone/macros/configure-gpg.sh
|
. .drone/macros/configure-gpg.sh
|
||||||
|
|
||||||
git add dist
|
git add "${WEBAPP_DIR}/dist"
|
||||||
git commit dist -S -m "[Automatic] Updated UI files" --no-verify
|
git commit "${WEBAPP_DIR}/dist" -S -m "[Automatic] Updated UI files" --no-verify
|
||||||
git remote rm origin
|
git remote rm origin
|
||||||
git remote add origin git@git.platypush.tech:platypush/platypush.git
|
git remote add origin git@git.platypush.tech:platypush/platypush.git
|
||||||
git push -f origin master
|
git push -f origin master
|
||||||
|
|
Loading…
Reference in a new issue