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

Unified Diff: remoting/host/installer/linux/build-deb.sh

Issue 10872092: Update build-deb.sh to automatically detect version number. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 4 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: remoting/host/installer/linux/build-deb.sh
diff --git a/remoting/host/installer/linux/build-deb.sh b/remoting/host/installer/linux/build-deb.sh
index 520477622b757e8e67a82d880e21bb118604a9ad..14231cb3e32e17a1a8c326c0e4cbe448bb99205f 100755
--- a/remoting/host/installer/linux/build-deb.sh
+++ b/remoting/host/installer/linux/build-deb.sh
@@ -5,10 +5,23 @@
# found in the LICENSE file.
if [[ -z "$version_full" ]]; then
- echo 'Error: $version_full not set'
+ src_root=./../../../..
+ version_helper=$src_root/chrome/tools/build/version.py
+ version_base=$($version_helper -f $src_root/remoting/VERSION \
+ -t "@MAJOR@.@MINOR@")
+ version_build=$($version_helper -f $src_root/chrome/VERSION \
+ -t "@BUILD@.@PATCH@")
+ version_full="$version_base.$version_build"
+fi
+
+if !(echo $version_full | grep -E \
Lambros 2012/08/27 21:39:33 Optional: maybe move this check into the first if.
Sergey Ulanov 2012/08/28 00:41:07 It's intentionally outside of the previous if to m
+ "^[[:digit:]]+.[[:digit:]]+.[[:digit:]]+.[[:digit:]]+$" > /dev/null); then
Jamie 2012/08/27 21:03:31 Strictly speaking, you should escape the . charact
+ echo "Error: Invalid \$version_full value: $version_full" >&2
exit 1
fi
+echo "Building version $version_full"
+
# Create a fresh debian/changelog.
export DEBEMAIL="The Chromium Authors <chromium-dev@chromium.org>"
rm -f debian/changelog
« 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