From 632b3d37736ce0df4f74edb2cdcbb88db4c9e975 Mon Sep 17 00:00:00 2001 From: Eric Wong Date: Sat, 28 Sep 2013 19:19:16 +0000 Subject: rework packaging to use GNU make + gemspec instead of Hoe Currently, this allows us to use different manpage paths for the tarball and gem; as gem-man and setup.rb expect different paths for manpages. Additionally, Hoe is designed for Ruby projects. dtas may include Perl/shell/Python/whatever in the future. So use GNU make as it is more suited for language agnosticism. --- GIT-VERSION-GEN | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'GIT-VERSION-GEN') diff --git a/GIT-VERSION-GEN b/GIT-VERSION-GEN index df7feb1..dd8ae37 100755 --- a/GIT-VERSION-GEN +++ b/GIT-VERSION-GEN @@ -3,6 +3,7 @@ # License: GPLv3 or later (https://www.gnu.org/licenses/gpl-3.0.txt) CONSTANT = "DTAS::VERSION" RVF = "lib/dtas/version.rb" +GVF = "GIT-VERSION-FILE" DEF_VER = "v0.4.0" vn = DEF_VER @@ -28,4 +29,13 @@ if new_ruby_version != cur_ruby_version File.open(RVF, "w") { |fp| fp.write(new_ruby_version) } end File.chmod(0644, RVF) + +# generate the makefile snippet +new_make_version = "VERSION = #{vn}\n" +cur_make_version = File.read(GVF) rescue nil +if new_make_version != cur_make_version + File.open(GVF, "w") { |fp| fp.write(new_make_version) } +end +File.chmod(0644, GVF) + puts vn if $0 == __FILE__ -- cgit v1.2.3-24-ge0c7