13 lines
206 B
Bash
13 lines
206 B
Bash
|
#!/bin/sh
|
||
|
|
||
|
UPSTREAM=${1:-'@{u}'}
|
||
|
LOCAL=$(git rev-parse @)
|
||
|
REMOTE=$(git rev-parse "$UPSTREAM")
|
||
|
BASE=$(git merge-base @ "$UPSTREAM")
|
||
|
|
||
|
if [ $LOCAL = $BASE ]; then
|
||
|
git stash
|
||
|
git pull
|
||
|
npm install
|
||
|
fi
|