mirror of
https://github.com/stedolan/jq.git
synced 2024-05-11 05:55:39 +00:00
This commit is contained in:
@ -1,7 +1,4 @@
|
|||||||
m4_define([jq_version],
|
m4_define([jq_version], m4_esyscmd_s([scripts/version])))
|
||||||
m4_esyscmd_s([(git rev-parse --verify -q jq-1.0 > /dev/null &&
|
|
||||||
(git describe --tags --dirty --match 'jq-*'|sed 's/^jq-//')) ||
|
|
||||||
echo `git rev-parse --abbrev-ref HEAD`-`git describe --always --dirty`])))
|
|
||||||
|
|
||||||
AC_INIT([jq], [jq_version], [https://github.com/jqlang/jq/issues],
|
AC_INIT([jq], [jq_version], [https://github.com/jqlang/jq/issues],
|
||||||
[jq], [https://jqlang.github.io/jq])
|
[jq], [https://jqlang.github.io/jq])
|
||||||
|
@ -1,10 +1,11 @@
|
|||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
set -e
|
set -eu
|
||||||
cd `dirname "$0"`
|
|
||||||
if git rev-parse --verify -q jq-1.0 > /dev/null 2>&1; then
|
cd "$(dirname "$0")"
|
||||||
|
if git describe --tags --match 'jq-*' >/dev/null 2>&1; then
|
||||||
git describe --tags --match 'jq-*' --dirty | sed 's/^jq-//'
|
git describe --tags --match 'jq-*' --dirty | sed 's/^jq-//'
|
||||||
else
|
else
|
||||||
b=`git rev-parse --abbrev-ref HEAD`
|
branch=$(git rev-parse --abbrev-ref HEAD)
|
||||||
c=`git describe --always --dirty`
|
commit=$(git describe --always --dirty)
|
||||||
echo "${b}-${c}"
|
echo "${branch}-${commit}"
|
||||||
fi
|
fi
|
||||||
|
Reference in New Issue
Block a user