Patchwork [4,of,5] debian: install hgk as part of mercurial-common (issue4829)

login
register
mail settings
Submitter Augie Fackler
Date Sept. 22, 2015, 6:54 p.m.
Message ID <7c2fdad0044ce76b0a83.1442948040@arthedain.pit.corp.google.com>
Download mbox | patch
Permalink /patch/10580/
State Accepted
Headers show

Comments

Augie Fackler - Sept. 22, 2015, 6:54 p.m.
# HG changeset patch
# User Augie Fackler <augie@google.com>
# Date 1442946737 14400
#      Tue Sep 22 14:32:17 2015 -0400
# Node ID 7c2fdad0044ce76b0a83a5dc1c4dd7f515175f19
# Parent  cc656c239796d3eec5d9401be2fd63174440a376
debian: install hgk as part of mercurial-common (issue4829)

Leaving the hgk binary in /usr/bin causes some lintian warnings, and
downstream packages poke it in /usr/share/mercurial, so we'll just
stash it in there. Rather than patch hgk.py as part of the Mercurial
install, just drop a config file in /etc/mercurial/hgrc.d that points
to the installed hgk.

Patch

diff --git a/contrib/debian/hgkpath.rc b/contrib/debian/hgkpath.rc
new file mode 100644
--- /dev/null
+++ b/contrib/debian/hgkpath.rc
@@ -0,0 +1,2 @@ 
+[hgk]
+path = /usr/share/mercurial/hgk
diff --git a/contrib/debian/rules b/contrib/debian/rules
--- a/contrib/debian/rules
+++ b/contrib/debian/rules
@@ -27,6 +27,8 @@  override_dh_install:
 		-name '*.so' ! -type d -delete , \
 		-type d -empty -delete
 	cp contrib/hg-ssh $(CURDIR)/debian/mercurial-common/usr/bin
+	mkdir -p $(CURDIR)/debian/mercurial-common/usr/share/mercurial
+	cp contrib/hgk $(CURDIR)/debian/mercurial-common/usr/share/mercurial
 	mkdir -p $(CURDIR)/debian/mercurial-common/etc/mercurial/hgrc.d/
 	cp contrib/debian/*.rc $(CURDIR)/debian/mercurial-common/etc/mercurial/hgrc.d/
 	rm $(CURDIR)/debian/mercurial-common/usr/bin/hg