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

Unified Diff: bin/cros_copy_upgrade_server.sh

Issue 3064025: Add independence to location of cros common.sh (will it move to bin/?) (Closed) Base URL: ssh://gitrw.chromium.org/crosutils.git
Patch Set: Created 10 years, 5 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 | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: bin/cros_copy_upgrade_server.sh
diff --git a/bin/cros_copy_upgrade_server.sh b/bin/cros_copy_upgrade_server.sh
index 86a4f46d4dff59665174f28e0ba3f38f0c06b3f3..30896022c56714ecb79612f697b9603bcb8bc227 100755
--- a/bin/cros_copy_upgrade_server.sh
+++ b/bin/cros_copy_upgrade_server.sh
@@ -6,9 +6,16 @@
# Script to push the output of build_image.sh to a remote image server
-# Load common constants. This should be the first executable line.
-# The path to common.sh should be relative to your script's location.
-. "$(dirname "$0")/common.sh"
+# TODO(pstew): Apparently the script files are in transition from
+# src/scripts to src/scripts/bin. However this state has existed
+# for months now, therefore we need to look for the common libs in
+# both places
+script_root=$(dirname $0)
+if [ -f ${script_root}/../common.sh ] ; then
+ script_root=${script_root}/..
+fi
+
+. "${script_root}/common.sh"
# Flags
DEFINE_string upgrade_server "" "SSH-capable host for upgrade server install"
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698