summaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorJavier Viguera <javier.viguera@digi.com>2010-04-27 11:29:50 +0200
committerJavier Viguera <javier.viguera@digi.com>2010-04-27 11:29:50 +0200
commit69bc23ee90101387154b2a25dda90b0605a296f7 (patch)
tree1f6a4ce9c30eb16826a07c8b13a73db3aaff4c07 /scripts
parente48c2d698321b17402aba686e6347020f29f535e (diff)
setlocalversion: add digiel tags to kernel version
Signed-off-by: Javier Viguera <javier.viguera@digi.com>
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/setlocalversion11
1 files changed, 11 insertions, 0 deletions
diff --git a/scripts/setlocalversion b/scripts/setlocalversion
index 46989b88d734..469042b6bc88 100755
--- a/scripts/setlocalversion
+++ b/scripts/setlocalversion
@@ -34,6 +34,17 @@ if head=`git rev-parse --verify --short HEAD 2>/dev/null`; then
fi
fi
+ # Do we have a DEL-tag?
+ if git name-rev --tags HEAD | grep -i "del-" > /dev/null; then
+ # -- The option 'exact-match' is available first by v1.5.5.1
+ ver=$(git --version | cut -d " " -f 3 | sed 's#\.##g')
+ if [ ${ver} -gt 1551 ]; then
+ printf '%s' - $(git describe --tags --exact-match HEAD)
+ else
+ printf '%s' - $(git describe --tags)
+ fi
+ fi
+
# Is this git on svn?
if git config --get svn-remote.svn.url >/dev/null; then
printf -- '-svn%s' "`git svn find-rev $head`"