From 9b0a353d7976efbd628166c30766646b2bcc7ba1 Mon Sep 17 00:00:00 2001 From: Ralph Amissah Date: Tue, 5 Nov 2019 09:41:48 -0500 Subject: makefile program version tagging for bin-archive --- org/dr_build_scaffold.org | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) (limited to 'org') diff --git a/org/dr_build_scaffold.org b/org/dr_build_scaffold.org index ca6b224..0b6d901 100644 --- a/org/dr_build_scaffold.org +++ b/org/dr_build_scaffold.org @@ -22,7 +22,8 @@ *** git version stamp :git:version: #+BEGIN_SRC makefile :tangle ../makefile -PROJECT_VERSION :=$(shell echo `git describe --long --tags | sed -e "s/^[ a-z_-]\+\([0-9.]\+\)/\1/;s/\([^-]*-g\)/r\1/;s/-/./g"`) +PROG_VER_GIT :=$(shell echo `git describe --long --tags | sed -e "s/^[ a-z_-]\+\([0-9.]\+\)/\1/;s/\([^-]*-g\)/r\1/;s/-/./g"`) +PROG_VER_DECLARED :=$(shell echo `cat ./views/version.txt | grep --color=never "enum" | sed 's/.\+(\([0-9]\+\),[ \t]\+\([0-9]\+\),[ \t]\+\([0-9]\+\)[ \t]*).\+/\1.\2.\3/g'`) #+END_SRC *** dub (build tool) :dub: @@ -253,8 +254,8 @@ dmd_debug: #+BEGIN_SRC makefile :tangle ../makefile dmd_ver: $(DUB) --compiler=dmd --config=dmd-version - mv bin/doc-reform-dmd-ver bin-archive/doc-reform-$(PROJECT_VERSION)-dmd - notify-send -t 0 'D dmd compiled test release executable ready' 'doc-reform-$(PROJECT_VERSION)-dmd' + mv bin/doc-reform-dmd-ver bin-archive/doc-reform-$(PROG_VER_DECLARED)-tag-$(PROG_VER_GIT)-dmd + notify-send -t 0 'D dmd compiled test release executable ready' 'doc-reform-$(PROG_VER_DECLARED)-tag-$(PROG_VER_GIT)-dmd' dmd_clean_ver: clean tangle dmd_ver #+END_SRC @@ -293,8 +294,8 @@ gdc_debug: #+BEGIN_SRC makefile :tangle ../makefile gdc_ver: $(DUB) --compiler=gdc --config=gdc-version - mv bin/doc-reform-gdc-ver bin-archive/doc-reform-$(PROJECT_VERSION)-gdc - notify-send -t 0 'D gdc compiled test release executable ready' 'doc-reform-$(PROJECT_VERSION)-gdc' + mv bin/doc-reform-gdc-ver bin-archive/doc-reform-$(PROG_VER_DECLARED)-tag-$(PROG_VER_GIT)-gdc + notify-send -t 0 'D gdc compiled test release executable ready' 'doc-reform-$(PROG_VER_DECLARED)-tag-$(PROG_VER_GIT)-gdc' gdc_clean_ver: clean tangle gdc_ver #+END_SRC @@ -333,8 +334,8 @@ ldc_debug: #+BEGIN_SRC makefile :tangle ../makefile ldc_ver: $(DUB) --compiler=ldc2 --config=ldc-version - mv bin/doc-reform-ldc-ver bin-archive/doc-reform-$(PROJECT_VERSION)-ldc - notify-send -t 0 'D ldc2 compiled test release executable ready' 'doc-reform-$(PROJECT_VERSION)-ldc' + mv bin/doc-reform-ldc-ver bin-archive/doc-reform-$(PROG_VER_DECLARED)-tag-$(PROG_VER_GIT)-ldc + notify-send -t 0 'D ldc2 compiled test release executable ready' 'doc-reform-$(PROG_VER_DECLARED)-tag-$(PROG_VER_GIT)-ldc' ldc_clean_ver: clean tangle ldc_ver #+END_SRC @@ -401,7 +402,7 @@ distclean_and_init: expunge #+BEGIN_SRC makefile :tangle ../makefile ver: - echo doc-reform-$(PROJECT_VERSION) + echo doc-reform-$(PROG_VER_DECLARED)-tag-$(PROG_VER_GIT) #+END_SRC ****** tangle build rebuild :clean:tangle:build: -- cgit v1.2.3