mirror of
https://invent.kde.org/network/falkon.git
synced 2024-12-20 02:36:34 +01:00
Edited getrevision.sh script and added one git hook
- git hook to automatically update revision number after commiting changes
This commit is contained in:
parent
085a8938c0
commit
4fc30fca05
5
git_hooks/post-commit
Executable file
5
git_hooks/post-commit
Executable file
@ -0,0 +1,5 @@
|
||||
#!/bin/sh
|
||||
#
|
||||
# Writes git revision into git_revision file
|
||||
#
|
||||
git show-ref refs/heads/master | cut -d " " -f 1 > git_revision
|
@ -2,7 +2,9 @@
|
||||
#git show-ref refs/heads/master | cut -d " " -f 1 | cut -c 1-10
|
||||
|
||||
cd ..
|
||||
if [ -e "git_revision" ]; then
|
||||
if [ -e "/usr/bin/git" ] && [ -e ".git" ]; then
|
||||
git show-ref refs/heads/master | cut -d " " -f 1 | cut -c 1-10;
|
||||
elif [ -e "git_revision" ]; then
|
||||
cat git_revision | cut -c 1-10;
|
||||
fi
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user