mirror of
https://github.com/lukasbestle/projectr.git
synced 2026-10-11 23:10:19 +02:00
More reliable automatic revision detection
This commit is contained in:
+1
-1
@@ -135,7 +135,7 @@ echo -e "\033[1;35mRun on \033[34m$(date)\033[35m by \033[34m$USER\033[35m:\n---
|
||||
fi
|
||||
|
||||
# Get the commit hash from the set branch
|
||||
revision="$(cd "$project/repo"; git show --format=format:%H "$branch")"
|
||||
revision="$(cd "$project/repo"; git rev-list --max-count=1 "$branch")"
|
||||
if [[ $? != 0 ]]; then
|
||||
echo -e " => \033[31mCould not determine current revision.\033[0m" >&2
|
||||
exit 1
|
||||
|
||||
Reference in New Issue
Block a user