* New license headers
@ 2013-01-05 23:53 Ludovic Courtès
0 siblings, 0 replies; only message in thread
From: Ludovic Courtès @ 2013-01-05 23:53 UTC (permalink / raw
To: bug-guix
[-- Attachment #1: Type: text/plain, Size: 114 bytes --]
Hi,
I’ve changed license headers to read “GNU Guix” and to use the copyright
sign using this script:
[-- Attachment #2: Type: text/x-scheme, Size: 1607 bytes --]
(use-modules (guix build utils)
(srfi srfi-1))
(fluid-set! %default-port-encoding "UTF-8")
(substitute* (remove (lambda (f)
(or (string-contains f ".tar.")
(string-contains f ".git/")
(string-contains f ".so")
(string-suffix? ".o" f)
(string-suffix? ".a" f)
(string-suffix? ".go" f)
(string-suffix? ".pdf" f)
(string-suffix? ".png" f)
(string-suffix? ".info" f)
(equal? (basename f) "guix-daemon")
(equal? (basename f) "nix-setuid-helper")
(string-contains f "nix-upstream/")
(string-contains f "distro/packages/bootstrap/")))
(find-files "." "\\.[a-z]+$"))
(("^([[:graph:]]+) This file is part of Guix." _ comment-start)
(string-append comment-start " This file is part of GNU Guix."))
(("^([[:graph:]]+) Guix --- Nix package management.*" _ comment-start)
(string-append comment-start
" GNU Guix --- Functional package management for GNU\n"))
(("^([[:graph:]]+) Guix is " _ comment-start)
(string-append comment-start " GNU Guix is "))
(("^([[:graph:]]+) along with Guix." _ comment-start)
(string-append comment-start " along with GNU Guix."))
(("^([[:graph:]]+) Copyright \\(C\\)" _ comment-start)
(string-append comment-start " Copyright ©")))
[-- Attachment #3: Type: text/plain, Size: 96 bytes --]
Notice how find + sed look old-fashioned and clunky in comparison. ;-)
Thanks,
Ludo’.
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2013-01-05 23:53 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-01-05 23:53 New license headers Ludovic Courtès
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/guix.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).