Skip to content

Commit

Permalink
Bugfix: Detect genbuild.sh in repo correctly
Browse files Browse the repository at this point in the history
  • Loading branch information
luke-jr committed Dec 29, 2016
1 parent df63490 commit ed1fcdc
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion share/genbuild.sh
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,13 @@ else
exit 1
fi

git_check_in_repo() {
! { git status --porcelain -uall --ignored "$@" 2>/dev/null || echo '??'; } | grep -q '?'
}

DESC=""
SUFFIX=""
if [ "${BITCOIN_GENBUILD_NO_GIT}" != "1" -a -e "$(which git 2>/dev/null)" -a "$(git rev-parse --is-inside-work-tree 2>/dev/null)" = "true" -a "$(git status --porcelain -u no --ignored "$0" | cut -b1)" != "?" ]; then
if [ "${BITCOIN_GENBUILD_NO_GIT}" != "1" -a -e "$(which git 2>/dev/null)" -a "$(git rev-parse --is-inside-work-tree 2>/dev/null)" = "true" ] && git_check_in_repo share/genbuild.sh; then
# clean 'dirty' status of touched files that haven't been modified
git diff >/dev/null 2>/dev/null

Expand Down

0 comments on commit ed1fcdc

Please sign in to comment.