minimize.sh make file ordering deterministic

Do find | sort | cat instead of find -exec cat when building
resources/openpgp.js. The order of files returned by find isn't
deterministic, which could lead to spurious differences.
This commit is contained in:
Brian Bloniarz
2013-02-13 22:34:35 -08:00
parent 2bb3c30025
commit ef3c0ecc60
3 changed files with 8679 additions and 8682 deletions

View File

@@ -11,7 +11,7 @@ _majorVersion=".1"
:>"$_min"
echo "Concatenating..."
find "$_src" -name "*.js" -exec cat "{}" >> "$_tmp" \;
find "$_src" -name "*.js" | sort | xargs --delimiter='\n' cat > "$_tmp"
sed "s/OpenPGP.js VERSION/OpenPGP.js v$_majorVersion.$(date +%Y%m%d)/g" "$_tmp" > "$_raw";
rm "$_tmp";