Skip to content

Commit e46d209

Browse files
reidmvsmortex
authored andcommitted
Don't assume git is in /usr/bin; expect it on PATH
1 parent ada9415 commit e46d209

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

scripts/config_version.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,9 +24,9 @@ elif [ -e /opt/puppetlabs/server/pe_version ]; then
2424
# being available.
2525
ruby $1/$2/scripts/config_version-rugged.rb $1 $2
2626

27-
elif [ -x /usr/bin/git ]; then
27+
elif type git >/dev/null; then
2828
# The git command is available.
29-
/usr/bin/git --git-dir $1/$2/.git rev-parse HEAD
29+
git --git-dir $1/$2/.git rev-parse HEAD
3030

3131
else
3232
# Nothing else available; just use the date.

0 commit comments

Comments
 (0)