summaryrefslogtreecommitdiffstats
path: root/build/mergejschecker.sh
blob: a8c5c37a1f1e991ed86077e4e636749a37471016 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
#!/usr/bin/env bash

#Regenerate the vendors core.js
echo
echo "Regenerating core/vendor/core.js"

d=`dirname $(readlink -f $0)`

php $d/mergejs.php

files=`git diff --name-only`

for file in $files
do
    if [[ $file == core/vendor/core.js ]]
    then
        echo "The merged vendor file is not up to date"
        echo "Please run: php build/mergejs.php"
        echo "And commit the result"
        exit 1
        break
    fi
done

echo "Vendor js merged as expected. Carry on"
exit 0