Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1103)

Unified Diff: src/platform/installer/chromeos-common.sh

Issue 2090006: Use new grub2 variables to boot from the device with the bootloader (Closed) Base URL: ssh://git@chromiumos-git//chromeos
Patch Set: respond to feedback Created 10 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | src/platform/installer/chromeos-install » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/platform/installer/chromeos-common.sh
diff --git a/src/platform/installer/chromeos-common.sh b/src/platform/installer/chromeos-common.sh
index c26c42d3a2fcff94714fdd1327d59ac50889bf10..5283145a87bacdffe340226a4060567a97e3eeda 100644
--- a/src/platform/installer/chromeos-common.sh
+++ b/src/platform/installer/chromeos-common.sh
@@ -486,3 +486,15 @@ make_arm_mbr() {
fi
echo ${MBR_SCRIPT_UIMG}
}
+
+
+# The scripts that source this file typically want to use the root password as
+# confirmation, unless the --run_as_root flag is given.
+dont_run_as_root() {
+ if [ $(id -u) -eq "0" -a "${FLAGS_run_as_root}" -eq "${FLAGS_FALSE}" ]
+ then
+ echo "Note: You must be the 'chronos' user to run this script. Unless"
+ echo "you pass --run_as_root and run as root."
+ exit 1
+ fi
+}
« no previous file with comments | « no previous file | src/platform/installer/chromeos-install » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698