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

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

Issue 10882070: Simplify regex matching in build-deb.sh. (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 14231cb3e32e17a1a8c326c0e4cbe448bb99205f..3c0233e429cf972b899b7ee6c73c11c52b0e5d54 100755
--- a/remoting/host/installer/linux/build-deb.sh
+++ b/remoting/host/installer/linux/build-deb.sh
@@ -14,8 +14,7 @@ if [[ -z "$version_full" ]]; then
version_full="$version_base.$version_build"
fi
-if !(echo $version_full | grep -E \
- "^[[:digit:]]+.[[:digit:]]+.[[:digit:]]+.[[:digit:]]+$" > /dev/null); then
+if [[ ! "$version_full" =~ ^[0-9]+\.[0-9]+\.[0-9]+\.[0-9]+$ ]]; then
echo "Error: Invalid \$version_full value: $version_full" >&2
exit 1
fi
« 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