forked from mCaptcha/website
feat: stash changes before checkout
This commit is contained in:
parent
b79e6fa2ba
commit
a1d1e7413d
1 changed files with 2 additions and 0 deletions
|
@ -101,10 +101,12 @@ deploy() {
|
|||
if [[ -z $(git ls-remote --heads origin ${1}) ]]
|
||||
then
|
||||
echo "[*] Creating deployment branch $1"
|
||||
git stash
|
||||
git checkout --orphan $1
|
||||
else
|
||||
echo "[*] Deployment branch $1 exists, pulling changes from remote"
|
||||
git fetch origin $1
|
||||
git stash
|
||||
git switch $1
|
||||
fi
|
||||
|
||||
|
|
Loading…
Reference in a new issue