Permalink
Browse files

build-support: make factor.sh check the git branch.

  • Loading branch information...
1 parent a344a6b commit 311a6a42bf3db68379da0a87e4445adcca28f5db @mrjbq7 mrjbq7 committed Jul 11, 2012
Showing with 9 additions and 0 deletions.
  1. +9 −0 build-support/factor.sh
View
@@ -110,6 +110,14 @@ set_make() {
MAKE='make'
}
+check_git_branch() {
+ BRANCH=`git symbolic-ref HEAD | sed -e 's,.*/\(.*\),\1,'`
+ if [ "$BRANCH" != "master" ] ; then
+ $ECHO "git branch is $BRANCH, not master"
+ exit_script 3
+ fi
+}
+
check_installed_programs() {
ensure_program_installed chmod
ensure_program_installed uname
@@ -501,6 +509,7 @@ get_url() {
get_config_info() {
find_build_info
+ check_git_branch
check_installed_programs
check_libraries
}

0 comments on commit 311a6a4

Please sign in to comment.