diff options
author | Angelo Mantellini (manangel) <angelo.mantellini@irt-systemx.fr> | 2017-06-06 14:22:24 +0200 |
---|---|---|
committer | Angelo Mantellini (manangel) <angelo.mantellini@irt-systemx.fr> | 2017-06-07 15:01:28 +0200 |
commit | 6358e611e09092ad121f4a85e548c0d9411ab09f (patch) | |
tree | 1e9ac163ce10ab44402dcce1566b7920afbe1bf1 /iGetAndroid/app/cmake/get_version.sh | |
parent | dca773280df13ce3ecc6d306dffd603715cf25a5 (diff) |
update applications to use new version libicnet
Change-Id: I4b2381a13cf64488baf83056fc1fa11b359d1147
Signed-off-by: Angelo Mantellini (manangel) <angelo.mantellini@irt-systemx.fr>
Diffstat (limited to 'iGetAndroid/app/cmake/get_version.sh')
-rwxr-xr-x | iGetAndroid/app/cmake/get_version.sh | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/iGetAndroid/app/cmake/get_version.sh b/iGetAndroid/app/cmake/get_version.sh new file mode 100755 index 00000000..34c6ddb2 --- /dev/null +++ b/iGetAndroid/app/cmake/get_version.sh @@ -0,0 +1,20 @@ +#!/bin/sh + +DATE_VERSION=`date "+%Y%m%d"` + +if [ ! -d $1 ]; then + echo 0.$DATE_VERSION + exit +fi + +if [ -f $1/BASE_VERSION ]; then + BASE_VERSION=`cat $1/BASE_VERSION`. +fi + +GIT=`which git` + +if test -x $GIT -a -f $1/.git/config; then + GIT_VERSION=.`git -C $1 rev-parse HEAD | cut -c 1-8` +fi + +echo $BASE_VERSION$DATE_VERSION$GIT_VERSION |