This is an automated email from the ASF dual-hosted git repository.

jan pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/couchdb.git


The following commit(s) were added to refs/heads/master by this push:
     new d35f00a  Simplify make dist approach
d35f00a is described below

commit d35f00aae7f32a97988e5dac4c37de7030c74a0d
Author: Joan Touzet <jo...@atypical.net>
AuthorDate: Tue Nov 7 04:16:27 2017 -0500

    Simplify make dist approach
---
 .gitignore |  4 +++-
 Makefile   | 13 +++++++++++--
 2 files changed, 14 insertions(+), 3 deletions(-)

diff --git a/.gitignore b/.gitignore
index 3e22192..be12160 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1,7 +1,9 @@
 *.o
-*.pyc
+*.sha256
+*.sha512
 *.snap
 *.so
+*.pyc
 .DS_Store
 .rebar/
 .eunit/
diff --git a/Makefile b/Makefile
index bd3b8ac..ed8fc63 100644
--- a/Makefile
+++ b/Makefile
@@ -14,8 +14,17 @@ include version.mk
 
 REBAR?=$(shell echo `pwd`/bin/rebar)
 IN_RELEASE = $(shell if [ ! -d .git ]; then echo true; fi)
-COUCHDB_VERSION_SUFFIX = $(shell if [ ! -z "$(COUCH_RC)" ]; then echo 
'-RC$(COUCH_RC)'; else if [ -d .git ]; then echo '-`git rev-parse --short 
--verify HEAD`'; fi; fi)
-COUCHDB_VERSION = 
$(vsn_major).$(vsn_minor).$(vsn_patch)$(COUCHDB_VERSION_SUFFIX)
+ifeq ($(IN_RELEASE), true)
+COUCHDB_VERSION = $(vsn_major).$(vsn_minor).$(vsn_patch)
+else
+RELTAG = $(shell git describe | grep -E '^[0-9]+\.[0-9]\.[0-9]+(-RC[0-9]+)?$$')
+ifeq ($(RELTAG),)
+COUCHDB_VERSION_SUFFIX = $(shell git rev-parse --short --verify HEAD)
+COUCHDB_VERSION = 
$(vsn_major).$(vsn_minor).$(vsn_patch)-$(COUCHDB_VERSION_SUFFIX)
+else
+COUCHDB_VERSION = $(RELTAG)
+endif
+endif
 
 DESTDIR=
 

-- 
To stop receiving notification emails like this one, please contact
j...@apache.org.

Reply via email to