From 7bc46ecc34ceb042ff890e5d306d0a2a736e891d Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Sun, 8 Sep 2019 14:35:44 +0200 Subject: doc: Add Guix Cookbook. * .gitignore: Update ignore list. * Makefile.am (assert-no-store-file-names): Exclude the cookbook. * bootstrap: Generate po files for cookbook translations. * doc/guix-cookbook.texi: New file. * doc/local.mk (info_TEXINFOS): Add it; add a rule to build cookbook translations. * po/doc/local.mk (DOC_COOKBOOK_PO_FILES): New variable. (EXTRA_DIST): Add cookbook pot file and po files. (doc-po-update-cookbook-%): New target. (doc-pot-update): Also update cookbook pot file. (doc-po-update): Also update cookbook po files. --- po/doc/local.mk | 33 ++++++++++++++++++++++++++++++++- 1 file changed, 32 insertions(+), 1 deletion(-) (limited to 'po') diff --git a/po/doc/local.mk b/po/doc/local.mk index fb3c5aee03..f1a52615c1 100644 --- a/po/doc/local.mk +++ b/po/doc/local.mk @@ -23,9 +23,13 @@ DOC_PO_FILES= \ %D%/guix-manual.ru.po \ %D%/guix-manual.zh_CN.po +DOC_COOKBOOK_PO_FILES= + EXTRA_DIST = \ %D%/guix-manual.pot \ - $(DOC_PO_FILES) + %D%/guix-cookbook.pot \ + $(DOC_PO_FILES) \ + $(DOC_COOKBOOK_PO_FILES) POT_OPTIONS = --package-name "guix" --package-version "$(VERSION)" \ --copyright-holder "Ludovic Courtès" \ @@ -52,6 +56,27 @@ doc-po-update-%: exit 1; \ fi +doc-po-update-cookbook-%: + @lang=`echo "$@" | sed -e's/^doc-po-update-//'` ; \ + output="$(srcdir)/po/doc/guix-cookbook.$$lang.po" ; \ + input="$(srcdir)/po/doc/guix-cookbook.pot" ; \ + if test -f "$$output"; then \ + test "$(srcdir)" = . && cdcmd="" || cdcmd="cd $(srcdir) && "; \ + echo "$${cdcmd}$(MSGMERGE_UPDATE) $(MSGMERGE_OPTIONS) --lang=$${lang} $$output $$input"; \ + cd $(srcdir) \ + && { case `$(MSGMERGE_UPDATE) --version | sed 1q | sed -e 's,^[^0-9]*,,'` in \ + '' | 0.[0-9] | 0.[0-9].* | 0.1[0-7] | 0.1[0-7].*) \ + $(MSGMERGE_UPDATE) $(MSGMERGE_OPTIONS) "$$output" "$$input";; \ + *) \ + $(MSGMERGE_UPDATE) $(MSGMERGE_OPTIONS) --lang=$${lang} "$$output" "$$input";; \ + esac; \ + }; \ + touch "$$output"; \ + else \ + echo "File $$output does not exist. If you are a translator, you can create it with 'msginit'." 1>&2; \ + exit 1; \ + fi + $(srcdir)/po/doc/%.pot-update: doc/%.texi $(AM_V_PO4A)$(PO4A_UPDATEPO) -M UTF-8 -f texinfo -m "$<" \ -p "$$(echo $@ | sed 's|-update||')" $(POT_OPTIONS) @@ -64,6 +89,7 @@ doc-pot-update: $(MAKE) $(srcdir)/po/doc/guix.pot-update; \ $(MAKE) $(srcdir)/po/doc/contributing.pot-update; \ done + $(MAKE) $(srcdir)/po/doc/guix-cookbook.pot-update; msgcat $(addprefix $(srcdir)/po/doc/, $(TMP_POT_FILES)) > $(srcdir)/po/doc/guix-manual.pot rm -f $(addprefix $(srcdir)/po/doc/, $(TMP_POT_FILES)) @@ -72,5 +98,10 @@ doc-po-update: doc-pot-update lang="`echo "$$f" | $(SED) -es'|.*/guix-manual\.\(.*\)\.po$$|\1|g'`"; \ $(MAKE) "doc-po-update-$$lang"; \ done + for f in $(DOC_COOKBOOK_PO_FILES); do \ + lang="`echo "$$f" | $(SED) -es'|.*/guix-cookbook\.\(.*\)\.po$$|\1|g'`"; \ + $(MAKE) "doc-po-update-cookbook-$$lang"; \ + done + .PHONY: doc-po-update doc-pot-update -- cgit v1.2.3 From aeb51370da7c854e8167066df9b138e15d7363e6 Mon Sep 17 00:00:00 2001 From: zimoun Date: Thu, 19 Sep 2019 19:24:42 +0200 Subject: guix package: Add 'guix show' alias. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * guix/scripts/show.scm: New file. * Makefile.am (MODULES): Add it. * po/guix/POTFILES.in: Add it. * tests/guix-package-aliases.sh: Add test. * doc/guix.texi (Invoking guix package): Document it and use it in a example. Signed-off-by: Ludovic Courtès --- po/guix/POTFILES.in | 1 + 1 file changed, 1 insertion(+) (limited to 'po') diff --git a/po/guix/POTFILES.in b/po/guix/POTFILES.in index 8b556ac0ec..f629034d61 100644 --- a/po/guix/POTFILES.in +++ b/po/guix/POTFILES.in @@ -47,6 +47,7 @@ guix/scripts/install.scm guix/scripts/remove.scm guix/scripts/upgrade.scm guix/scripts/search.scm +guix/scripts/show.scm guix/scripts/gc.scm guix/scripts/hash.scm guix/scripts/import.scm -- cgit v1.2.3