Skip to content

Commit

Permalink
ci(aio): Fix the payload script only check for changes in aio/scripts
Browse files Browse the repository at this point in the history
  • Loading branch information
tinayuangao authored and petebacondarwin committed Jul 3, 2017
1 parent dc88e0a commit 9263da5
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions aio/scripts/payload.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,11 @@
set +x -eu -o pipefail

readonly thisDir=$(cd $(dirname $0); pwd)
readonly parentDir=$(dirname $thisDir)
readonly TOKEN=${ANGULAR_PAYLOAD_FIREBASE_TOKEN:-}
readonly PROJECT_NAME="angular-payload-size"

source scripts/_payload-limits.sh
source ${thisDir}/_payload-limits.sh

failed=false
payloadData=""
Expand Down Expand Up @@ -43,8 +44,8 @@ payloadData="$payloadData\"timestamp\": $timestamp, "

# Add change source: application, dependencies, or 'application+dependencies'
yarnChanged=false
allChangedFiles=$(git diff --name-only $TRAVIS_COMMIT_RANGE $thisDir | wc -l)
allChangedFileNames=$(git diff --name-only $TRAVIS_COMMIT_RANGE $thisDir)
allChangedFiles=$(git diff --name-only $TRAVIS_COMMIT_RANGE $parentDir | wc -l)
allChangedFileNames=$(git diff --name-only $TRAVIS_COMMIT_RANGE $parentDir)

if [[ $allChangedFileNames == *"yarn.lock"* ]]; then
yarnChanged=true
Expand Down

0 comments on commit 9263da5

Please sign in to comment.