We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 94c09f1 commit d0f1d63Copy full SHA for d0f1d63
deploy.sh
@@ -9,11 +9,17 @@ BASE=$(git merge-base @ @{u})
9
if [ $LOCAL = $REMOTE ]; then
10
echo "Local repository is already up to date."
11
elif [ $LOCAL = $BASE ]; then
12
+ CHANGES=$(git diff --name-only "$LOCAL" "$REMOTE")
13
git pull
14
if [ $? -eq 0 ]; then
- echo "Updated repository. Building with Grunt..."
15
- grunt build
16
- echo "Build done."
+ echo "Repository updated."
+ if grep -q "\.js$\|\.css$" <<< "$CHANGES"; then
17
+ echo "Grunt build required. Building..."
18
+ grunt build
19
+ echo "Build done."
20
+ else
21
+ echo "No Grunt build required."
22
+ fi
23
else
24
echo "Repository update failed. Aborting..."
25
fi
0 commit comments