mirror of
https://github.com/flatcar/scripts.git
synced 2025-09-22 22:21:10 +02:00
Add a warning to users trying to run old build scripts.
Add an exception for chrome-bot user for continuous builders. Review URL: http://codereview.chromium.org/595009
This commit is contained in:
parent
b6fb706f38
commit
b7eb3a2be6
24
common.sh
24
common.sh
@ -108,6 +108,28 @@ fi
|
||||
# Directory locations inside the dev chroot
|
||||
CHROOT_TRUNK_DIR="/home/$USER/trunk"
|
||||
|
||||
# Check to ensure not running old scripts
|
||||
V_REVERSE='[7m'
|
||||
V_VIDOFF='[m'
|
||||
case "$(basename $0)" in
|
||||
build_image.sh|build_platform_packages.sh|customize_rootfs.sh|make_chroot.sh)
|
||||
echo
|
||||
echo "$V_REVERSE============================================================"
|
||||
echo "=========================== WARNING ======================"
|
||||
echo "============================================================$V_VIDOFF"
|
||||
echo
|
||||
echo "RUNNING OLD BUILD SYSTEM SCRIPTS. RUN THE PORTAGE-BASED BUILD HERE:"
|
||||
echo "http://www.chromium.org/chromium-os/building-chromium-os/portage-based-build"
|
||||
echo
|
||||
if [ "$USER" != "chrome-bot" ]
|
||||
then
|
||||
read -n1 -p "Press any key to continue using the OLD build system..."
|
||||
echo
|
||||
echo
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
|
||||
# -----------------------------------------------------------------------------
|
||||
# Functions
|
||||
|
||||
@ -193,7 +215,7 @@ function install_if_missing {
|
||||
#
|
||||
# $1 - The file to check
|
||||
is_whitelisted() {
|
||||
local file=$1
|
||||
local file=$1
|
||||
local whitelist="$FLAGS_whitelist"
|
||||
test -f "$whitelist" || (echo "Whitelist file missing ($whitelist)" && exit 1)
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user