[DRE-commits] [ruby-combustion] 01/01: Automate manpage creation

Lucas Moura lucasmoura-guest at moszumanska.debian.org
Sat Mar 5 19:16:54 UTC 2016


This is an automated email from the git hooks/post-receive script.

lucasmoura-guest pushed a commit to branch master
in repository ruby-combustion.

commit 4293279246ff1479610e836fd7d9e6f7301d0ed2
Author: Lucas Albuquerque Medeiros de Moura <lucas.moura128 at gmail.com>
Date:   Sat Mar 5 16:15:35 2016 -0300

    Automate manpage creation
---
 debian/changelog                |  5 +++--
 debian/combust.1                | 50 -----------------------------------------
 debian/combust.h2m              |  9 ++++++++
 debian/control                  |  1 +
 debian/ruby-combustion.manpages |  2 +-
 debian/rules                    | 11 +++++++++
 6 files changed, 25 insertions(+), 53 deletions(-)

diff --git a/debian/changelog b/debian/changelog
index 8e8e310..aae9b21 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -3,10 +3,11 @@ ruby-combustion (0.5.4-1) unstable; urgency=medium
   * Team upload.
   * New upstream release.
   * Add package tests.
-  * Add manpage for generated binary.
   * Remove 'git ls-files' command from gemspec.
   * debian/control: Add new build dependencies.
-  * debian/rules: Add check-dependencies command.
+  * debian/rules:
+     - Add check-dependencies command.
+     - Create manpage during package build.
 
  -- Lucas Albuquerque Medeiros de Moura <lucas.moura128 at gmail.com>  Fri, 04 Mar 2016 17:50:27 -0300
 
diff --git a/debian/combust.1 b/debian/combust.1
deleted file mode 100644
index 65266f5..0000000
--- a/debian/combust.1
+++ /dev/null
@@ -1,50 +0,0 @@
-.\" DO NOT MODIFY THIS FILE!  It was generated by help2man 1.47.3.
-.TH COMBUST "1" "March 2016" "combust       create  spec/internal" "User Commands"
-.SH NAME
-combust \- creates a minimal set of files expected by Rails. Run this in the directory of your engine
-.SH DESCRIPTION
-.SS "Usage:"
-.IP
-combust combustion:generator
-.TP
-create
-spec/internal/config
-.TP
-create
-spec/internal/db
-.TP
-create
-spec/internal/log
-.TP
-create
-spec/internal/public
-.TP
-create
-spec/internal/config/routes.rb
-.TP
-create
-spec/internal/config/database.yml
-.TP
-create
-spec/internal/db/schema.rb
-.TP
-create
-config.ru
-.TP
-create
-spec/internal/public/favicon.ico
-.TP
-create
-spec/internal/log/.gitignore
-.SH "SEE ALSO"
-The full documentation for
-.B combust
-is maintained as a Texinfo manual.  If the
-.B info
-and
-.B combust
-programs are properly installed at your site, the command
-.IP
-.B info combust
-.PP
-should give you access to the complete manual.
diff --git a/debian/combust.h2m b/debian/combust.h2m
new file mode 100644
index 0000000..2edf6fd
--- /dev/null
+++ b/debian/combust.h2m
@@ -0,0 +1,9 @@
+[name]
+combust \-creates a minimal set of files expected by Rails
+
+[description]
+`Combustion` is a library to help you test your Rails Engines in a simple and
+effective manner, instead of creating a full Rails application in your spec or
+test folder.
+It allows you to write your specs within the context of your engine, using only
+the parts of a Rails app you need.
diff --git a/debian/control b/debian/control
index 2349969..62bca7d 100644
--- a/debian/control
+++ b/debian/control
@@ -4,6 +4,7 @@ Priority: optional
 Maintainer: Debian Ruby Extras Maintainers <pkg-ruby-extras-maintainers at lists.alioth.debian.org>
 Uploaders: Andrew Lee (李健秋) <andrew.lee at collabora.co.uk>
 Build-Depends: debhelper (>= 9~),
+               help2man,
                gem2deb,
                ruby-rspec,
                ruby-sqlite3,
diff --git a/debian/ruby-combustion.manpages b/debian/ruby-combustion.manpages
index 8c3d881..69ba49e 100644
--- a/debian/ruby-combustion.manpages
+++ b/debian/ruby-combustion.manpages
@@ -1 +1 @@
-debian/combust.1
+combust.1
diff --git a/debian/rules b/debian/rules
index aa5d94e..65083b0 100755
--- a/debian/rules
+++ b/debian/rules
@@ -10,6 +10,8 @@
 #
 # If you need to specify the .gemspec (eg there is more than one)
 #export DH_RUBY_GEMSPEC=gem.gemspec
+UPSTREAM_VERSION = $(shell dpkg-parsechangelog | awk '{ if ($$1 == "Version:") { print($$2) } }' | cut -d - -f 1)
+
 export GEM2DEB_TEST_RUNNER = --check-dependencies
 
 %:
@@ -17,3 +19,12 @@ export GEM2DEB_TEST_RUNNER = --check-dependencies
 
 override_dh_installchangelogs:
 	dh_installchangelogs HISTORY -O--buildsystem=ruby
+
+override_dh_installman:
+	INLINEDIR=. help2man --no-info --include=debian/combust.h2m \
+      -h "-I lib/ bin/combust"  --version-string $(UPSTREAM_VERSION) /usr/bin/ruby  > combust.1
+	dh_installman
+
+override_dh_clean:
+	rm -f combust.1
+	dh_clean

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-ruby-extras/ruby-combustion.git



More information about the Pkg-ruby-extras-commits mailing list