From c25f7af7f27425f2e529b6f6505441ed8c012813 Mon Sep 17 00:00:00 2001 From: Claudio Matsuoka Date: Mon, 24 Jan 2011 23:10:51 -0200 Subject: [PATCH] Add version check to Makefile dist target Show version info in serveral files including README, FAQ and manual pages when building the distribution package, to ensure consistency. Output is like: Infocode: 20204 Version: 2.2.4, date: 26 January 2011 README: release 2.2.4, 26 January 2011 FAQ: The latest version of FIGlet is 2.2.4 .TH CHKFONT 6 "26 January 2011" "v2.2.4" .TH FIGLET 6 "26 January 2011" "v2.2.4" .TH FIGLIST 6 "26 January 2011" "v2.2.4" .TH SHOWFIGFONTS 6 "26 January 2011" "v2.2.4" Signed-off-by: Claudio Matsuoka --- Makefile | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/Makefile b/Makefile index 74dba25..6c82acb 100644 --- a/Makefile +++ b/Makefile @@ -96,9 +96,15 @@ dist: tar cvf - $(DIST) | gzip -9c > $(DIST).tar.gz rm -Rf $(DIST) tar xf $(DIST).tar.gz - (cd $(DIST); make all test) - rm -Rf $(DIST) - ls -l $(DIST).tar.gz + (cd $(DIST); make all test; \ + echo -n "\nInfocode: "; ./figlet -I1; \ + ./figlet -v|sed -n '/Version/s/.*\(Version\)/\1/p'; \ + echo -n "README: "; head -1 < README|sed 's/.*) //'; \ + echo -n "FAQ: "; grep latest FAQ|sed 's/ and can.*//'; \ + grep -h "^\.TH" *.6) + @rm -Rf $(DIST) + @echo + @ls -l $(DIST).tar.gz test: @echo -n "Run tests in "