mirror of
https://git.savannah.gnu.org/git/guix.git
synced 2026-05-26 11:01:48 +02:00
Merge remote-tracking branch 'origin/master' into core-updates
This commit is contained in:
+33
-5
@@ -298,13 +298,17 @@ actual file name."
|
||||
(loop rest))
|
||||
((('strong _ ...) _ ...)
|
||||
#t)
|
||||
(_ #f))))
|
||||
((('span ('@ ('class "symbol-definition-category"))
|
||||
(? string-or-entity?) ...) rest ...)
|
||||
#t)
|
||||
(x
|
||||
#f))))
|
||||
|
||||
(let ((shtml (call-with-input-file file html->shtml)))
|
||||
(let loop ((shtml shtml)
|
||||
(anchors anchors))
|
||||
(match shtml
|
||||
(('dt ('@ ('id id)) rest ...)
|
||||
(('dt ('@ ('id id) _ ...) rest ...)
|
||||
(if (and (string-prefix? "index-" id)
|
||||
(worthy-entry? rest))
|
||||
(alist-cons (anchor-id->key id)
|
||||
@@ -479,6 +483,19 @@ its <pre class=\"lisp\"> blocks (as produced by 'makeinfo --html')."
|
||||
(pk 'unsupported-code-snippet something)
|
||||
(primitive-exit 1)))))
|
||||
|
||||
(define (highlight-definition id category symbol args)
|
||||
;; Produce stylable HTML for the given definition (an @deftp,
|
||||
;; @deffn, or similar).
|
||||
`(dt (@ (id ,id) (class "symbol-definition"))
|
||||
(span (@ (class "symbol-definition-category"))
|
||||
,@category)
|
||||
(span (@ (class "symbol-definition-prototype"))
|
||||
,symbol " " ,@args)))
|
||||
|
||||
(define (space? obj)
|
||||
(and (string? obj)
|
||||
(string-every char-set:whitespace obj)))
|
||||
|
||||
(define (syntax-highlight sxml anchors)
|
||||
;; Recurse over SXML and syntax-highlight code snippets.
|
||||
(let loop ((sxml sxml))
|
||||
@@ -497,6 +514,15 @@ its <pre class=\"lisp\"> blocks (as produced by 'makeinfo --html')."
|
||||
(highlight lex-scheme
|
||||
(concatenate-snippets code-snippet)))
|
||||
anchors)))
|
||||
|
||||
;; Replace the ugly <strong> used for @deffn etc., which
|
||||
;; translate to <dt>, with more stylable markup.
|
||||
(('dt (@ ('id id)) category ... ('strong thing))
|
||||
(highlight-definition id category thing '()))
|
||||
(('dt (@ ('id id)) category ... ('strong thing)
|
||||
(? space?) ('em args ...))
|
||||
(highlight-definition id category thing args))
|
||||
|
||||
((tag ('@ attributes ...) body ...)
|
||||
`(,tag (@ ,@attributes) ,@(map loop body)))
|
||||
((tag body ...)
|
||||
@@ -1172,7 +1198,8 @@ by 'html-identifier-indexes'."
|
||||
#:manual-name "guix"
|
||||
#:base-url (if (string=? %manual "guix")
|
||||
(const "")
|
||||
(cut string-append "/manual/" <>))
|
||||
(cut string-append
|
||||
"/manual/devel/" <>))
|
||||
#:languages %languages))
|
||||
|
||||
(define guix-split-node-indexes
|
||||
@@ -1181,8 +1208,9 @@ by 'html-identifier-indexes'."
|
||||
#:manual-name "guix"
|
||||
#:base-url (if (string=? %manual "guix")
|
||||
(const "")
|
||||
(cut string-append "/manual/" <>
|
||||
"/html_node"))
|
||||
(cut string-append
|
||||
"/manual/devel/" <>
|
||||
"/html_node"))
|
||||
#:languages %languages))
|
||||
|
||||
(define mono-node-indexes
|
||||
|
||||
+50
-2
@@ -28,6 +28,7 @@ choice.
|
||||
* Submitting Patches:: Share your work.
|
||||
* Tracking Bugs and Patches:: Using Debbugs.
|
||||
* Commit Access:: Pushing to the official repository.
|
||||
* Updating the Guix Package:: Updating the Guix package definition.
|
||||
@end menu
|
||||
|
||||
@node Building from Git
|
||||
@@ -139,6 +140,16 @@ make authenticate
|
||||
|
||||
The first run takes a couple of minutes, but subsequent runs are faster.
|
||||
|
||||
Or, when your configuration for your local Git repository doesn't match
|
||||
the default one, you can provide the reference for the @code{keyring}
|
||||
branch through the variable @code{GUIX_GIT_KEYRING}. The following
|
||||
example assumes that you have a Git remote called @samp{myremote}
|
||||
pointing to the official repository:
|
||||
|
||||
@example
|
||||
make authenticate GUIX_GIT_KEYRING=myremote/keyring
|
||||
@end example
|
||||
|
||||
@quotation Note
|
||||
You are advised to run @command{make authenticate} after every
|
||||
@command{git pull} invocation. This ensures you keep receiving valid
|
||||
@@ -604,11 +615,11 @@ to make recommendations or instructions visible to them by inserting
|
||||
special comments like this (@pxref{xgettext Invocation,,, gettext, GNU
|
||||
Gettext}):
|
||||
|
||||
@example
|
||||
@lisp
|
||||
;; TRANSLATORS: "X11 resize-and-rotate" should not be translated.
|
||||
(description "ARandR is designed to provide a simple visual front end
|
||||
for the X11 resize-and-rotate (RandR) extension. @dots{}")
|
||||
@end example
|
||||
@end lisp
|
||||
|
||||
@node Snippets versus Phases
|
||||
@subsection Snippets versus Phases
|
||||
@@ -1323,3 +1334,40 @@ only push their own awesome changes, but also offer some of their time
|
||||
@emph{reviewing} and pushing other people's changes. As a committer,
|
||||
you're welcome to use your expertise and commit rights to help other
|
||||
contributors, too!
|
||||
|
||||
@node Updating the Guix Package
|
||||
@section Updating the Guix Package
|
||||
|
||||
@cindex update-guix-package, updating the guix package
|
||||
It is sometimes desirable to update the @code{guix} package itself (the
|
||||
package defined in @code{(gnu packages package-management)}), for
|
||||
example to make new daemon features available for use by the
|
||||
@code{guix-service-type} service type. In order to simplify this task,
|
||||
the following command can be used:
|
||||
|
||||
@example
|
||||
make update-guix-package
|
||||
@end example
|
||||
|
||||
The @code{update-guix-package} make target will use the last known
|
||||
@emph{commit} corresponding to @code{HEAD} in your Guix checkout,
|
||||
compute the hash of the Guix sources corresponding to that commit and
|
||||
update the @code{commit}, @code{revision} and hash of the @code{guix}
|
||||
package definition.
|
||||
|
||||
To validate that the updated @code{guix} package hashes are correct and
|
||||
that it can be built successfully, the following command can be run from
|
||||
the directory of your Guix checkout:
|
||||
|
||||
@example
|
||||
./pre-inst-env guix build guix
|
||||
@end example
|
||||
|
||||
To guard against accidentally updating the @code{guix} package to a
|
||||
commit that others can't refer to, a check is made that the commit used
|
||||
has already been pushed to the Savannah-hosted Guix git repository.
|
||||
|
||||
This check can be disabled, @emph{at your own peril}, by setting the
|
||||
@code{GUIX_ALLOW_ME_TO_USE_PRIVATE_COMMIT} environment variable. When
|
||||
this variable is set, the updated package source is also added to the
|
||||
store. This is used as part of the release process of Guix.
|
||||
|
||||
+1291
-250
File diff suppressed because it is too large
Load Diff
+10
-8
@@ -96,14 +96,16 @@ define xref_command
|
||||
cat "$@.tmp" | egrep '@p?x?ref' -A1 | sed 'N;s|--\n||g;P;D' | sed 's|^| |g' | \
|
||||
tr -d '\012' | sed 's|\(@p\?x\?ref\)|\n\1|g' | egrep '@p?x?ref' | \
|
||||
sed 's|^.*@p\?x\?ref{\([^,}]*\).*$$|\1|g' | sort | uniq | while read e; do \
|
||||
line=$$(grep -n "^msgid \"$$e\"" "$<" | cut -f1 --delimiter=":") ;\
|
||||
((line++)) ;\
|
||||
if [ "$$line" != "1" ]; then \
|
||||
translation=$$(head -n $$line "$<" | tail -1 | grep msgstr | sed 's|msgstr "\(.*\)"|\1|') ;\
|
||||
if [ "$$translation" != "" ]; then \
|
||||
sed "N;s@\(p\?x\?ref\){$$(echo $$e | sed 's| |[\\n ]|g')\(,\|}\)@\1{$$translation\2@g;P;D" -i "$@.tmp" ;\
|
||||
fi ;\
|
||||
fi ;\
|
||||
if [ -n "$$e" ]; then \
|
||||
line=$$(grep -n "^msgid \"$$e\"" "$<" | cut -f1 --delimiter=":") ;\
|
||||
((line++)) ;\
|
||||
if [ "$$line" != "1" ]; then \
|
||||
translation=$$(head -n "$$line" "$<" | tail -1 | grep msgstr | sed 's|msgstr "\(.*\)"|\1|') ;\
|
||||
if [ "$$translation" != "" ]; then \
|
||||
sed "N;s@\(p\?x\?ref\){$$(echo $$e | sed 's| |[\\n ]|g')\(,\|}\)@\1{$$translation\2@g;P;D" -i "$@.tmp" ;\
|
||||
fi ;\
|
||||
fi ;\
|
||||
fi ;\
|
||||
done
|
||||
endef
|
||||
|
||||
|
||||
Reference in New Issue
Block a user