Files
sdk/tools/dom/scripts/go.sh
T
William Hesse 634e5a1d02 Refs #25328 Use a portable shebang
BSD systems don't place bash in /bin and a lot of the dart tools
hardcode a #!/bin/bash shebang that fails the 'all' target build
(not able to execute dart2js since the interpreter is not found).

Solve the issue by using #!/usr/bin/env as the shebang. For scripts
that need to pass arguments to bash modify the script to use the set
command as the first executed line of shell.

BUG=
R=whesse@google.com

Review URL: https://codereview.chromium.org/1552313002 .
2016-01-05 16:26:28 +01:00

41 lines
1.1 KiB
Bash
Executable File

#!/usr/bin/env bash
#
set -x
# go.sh [systems]
#
# Convenience script to generate systems. Do not call from build steps or tests
# - call fremontcutbuilder and dartdomgenerator instead. Do not add 'real'
# functionality here - change the python code instead.
#
# I find it essential to generate all the systems so I know if I am breaking
# other systems. My habit is to run:
#
# ./go.sh | tee Q
#
# I can inspect file Q if needed.
#
# To generate a subset of systems:
#
# ./go.sh dart2js,htmldart2js
#
# The following gives a picture of the changes due to 'work'
#
# git checkout master # select client without changes
# ./go.sh
# mv ../generated ../generated0 # save generated files
# git checkout work # select client with changes
# ./go.sh
# meld ../generated0 ../generated # compare directories with too
ALLSYSTEMS="htmldart2js,htmldartium"
SYSTEMS="$ALLSYSTEMS"
if [[ "$1" != "" ]] ; then
SYSTEMS="$1"
fi
reset && \
./dartdomgenerator.py --systems="$SYSTEMS" --logging=40 --update-dom-metadata --gen-interop