[Pkg-privacy-commits] [torbrowser-launcher] 02/03: Add script to build manpage automatically

Roger Shimizu rosh at moszumanska.debian.org
Sun Sep 10 04:36:54 UTC 2017


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

rosh pushed a commit to branch debian/sid
in repository torbrowser-launcher.

commit ce1f4b94b04fe7071787db8b81d947f3dd300dca
Author: Roger Shimizu <rogershimizu at gmail.com>
Date:   Sun Sep 10 13:07:19 2017 +0900

    Add script to build manpage automatically
---
 debian/changelog                    | 3 +++
 debian/control                      | 1 +
 debian/help2man/help                | 8 ++++++++
 debian/help2man/torbrowser-launcher | 3 +++
 debian/help2man/update-help         | 3 +++
 debian/rules                        | 5 +++++
 debian/torbrowser-launcher.manpages | 2 +-
 7 files changed, 24 insertions(+), 1 deletion(-)

diff --git a/debian/changelog b/debian/changelog
index 96c652b..d811a3d 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -2,6 +2,9 @@ torbrowser-launcher (0.2.8-2) UNRELEASED; urgency=medium
 
   * debian/control:
     - wrap and sort
+    - Add help2man to Build-Depends.
+  * debian/rules and debian/help2man:
+    - Add script to build manpage automatically.
 
  -- Roger Shimizu <rogershimizu at gmail.com>  Sun, 10 Sep 2017 12:27:52 +0900
 
diff --git a/debian/control b/debian/control
index 8bd5fd6..6740a3e 100644
--- a/debian/control
+++ b/debian/control
@@ -7,6 +7,7 @@ Build-Depends:
  debhelper (>= 9.20120909~),
  dh-apparmor,
  dh-python,
+ help2man,
  lsb-release,
  python-all (>= 2.7.3-4)
 X-Python-Version: >= 2.7
diff --git a/debian/help2man/help b/debian/help2man/help
new file mode 100644
index 0000000..25378c0
--- /dev/null
+++ b/debian/help2man/help
@@ -0,0 +1,8 @@
+usage: torbrowser-launcher [-h] [--settings] [url [url ...]]
+
+positional arguments:
+  url         URL to load
+
+optional arguments:
+  -h, --help  show this help message and exit
+  --settings  Open Tor Browser Launcher settings
diff --git a/debian/help2man/torbrowser-launcher b/debian/help2man/torbrowser-launcher
new file mode 100755
index 0000000..5219a5f
--- /dev/null
+++ b/debian/help2man/torbrowser-launcher
@@ -0,0 +1,3 @@
+#!/bin/sh
+
+cat debian/help2man/help
diff --git a/debian/help2man/update-help b/debian/help2man/update-help
new file mode 100755
index 0000000..8b20b7a
--- /dev/null
+++ b/debian/help2man/update-help
@@ -0,0 +1,3 @@
+#!/bin/sh
+
+torbrowser-launcher --help > $(dirname $0)/help
diff --git a/debian/rules b/debian/rules
index 1bdbe9f..afa7854 100755
--- a/debian/rules
+++ b/debian/rules
@@ -1,5 +1,7 @@
 #!/usr/bin/make -f
 
+include /usr/share/dpkg/pkg-info.mk
+
 %:
 	dh $@ --with python2 --buildsystem=python_distutils
 
@@ -8,6 +10,9 @@ override_dh_install:
 		cp apparmor/$$PROFILE debian/torbrowser-launcher/etc/apparmor.d/ ; \
 		dh_apparmor --profile-name=$$PROFILE -ptorbrowser-launcher ; \
 	done
+	help2man -N -n "helps download and run the Tor Browser Bundle" \
+		--version-string="$(DEB_VERSION)" \
+		-o build/torbrowser-launcher.1 debian/help2man/torbrowser-launcher
 
 override_dh_clean:
 	rm -rf share/locale/
diff --git a/debian/torbrowser-launcher.manpages b/debian/torbrowser-launcher.manpages
index 3592200..7e6b2e3 100644
--- a/debian/torbrowser-launcher.manpages
+++ b/debian/torbrowser-launcher.manpages
@@ -1 +1 @@
-debian/torbrowser-launcher.1
+build/torbrowser-launcher.1

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-privacy/packages/torbrowser-launcher.git



More information about the Pkg-privacy-commits mailing list