unofficial mirror of guix-patches@gnu.org 
 help / color / mirror / code / Atom feed
From: Tanguy Le Carrour <tanguy@bioneland.org>
To: 46170@debbugs.gnu.org
Cc: Tanguy Le Carrour <tanguy@bioneland.org>
Subject: [bug#46170] [PATCH] gnu: Add licenseheaders.
Date: Fri, 29 Jan 2021 11:09:48 +0100	[thread overview]
Message-ID: <20210129100948.26041-1-tanguy@bioneland.org> (raw)

* gnu/packages/license.scm (licenseheaders): New variable.
---
 gnu/packages/license.scm | 35 +++++++++++++++++++++++++++++++++++
 1 file changed, 35 insertions(+)

diff --git a/gnu/packages/license.scm b/gnu/packages/license.scm
index 369426768b..568275e510 100644
--- a/gnu/packages/license.scm
+++ b/gnu/packages/license.scm
@@ -2,6 +2,7 @@
 ;;; Copyright © 2018 Oleg Pykhalov <go.wigust@gmail.com>
 ;;; Copyright © 2018, 2019, 2020 Tobias Geerinckx-Rice <me@tobias.gr>
 ;;; Copyright © 2020, 2021 Michael Rohleder <mike@rohleder.de>
+;;; Copyright © 2021 Tanguy Le Carrour <tanguy@bioneland.org>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -205,3 +206,37 @@ tools that have a lot more features and functionality surrounding the analysis
 and inspection of copyright and licenses in software projects.  This one is
 designed to be simple.")
     (license (list asl2.0 gpl3+))))
+
+(define-public licenseheaders
+  (package
+    (name "licenseheaders")
+    (version "0.8.6")
+    (source
+     (origin
+       (method url-fetch)
+       (uri (pypi-uri "licenseheaders" version))
+       (sha256
+        (base32
+         "073xcm10gyg5kcxqmbsyaz9sr0slbdwgr0r9qanch0zl8i0z9259"))))
+    (build-system python-build-system)
+    (arguments
+     `(#:phases
+       (modify-phases %standard-phases
+         ;; Reported upstream:
+         ;; <https://github.com/johann-petrak/licenseheaders/issues/47>.
+         (add-after 'unpack 'patch-code
+           (lambda _
+             (substitute* "licenseheaders.py"
+               (("\\\"filenames\\\": \\[\\\"CMakeLists.txt\\\"\\],")
+                "\"filenames\": [\"CMakeLists.txt\"], \n        \"extensions\": [],"))
+             #t)))))
+    (propagated-inputs
+     `(("python-regex" ,python-regex)))
+    (home-page
+     "http://github.com/johann-petrak/licenseheaders")
+    (synopsis
+     "Add or change license headers for all files in a directory")
+    (description
+     "A Python 3 tool to update, change or add license headers to all files
+ of any of the supported types (see below) in or below some directory.")
+    (license expat)))
-- 
2.30.0





             reply	other threads:[~2021-01-29 10:11 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-01-29 10:09 Tanguy Le Carrour [this message]
2021-01-31 16:01 ` bug#46170: [PATCH] gnu: Add licenseheaders Nicolas Goaziou
2021-01-31 16:25   ` [bug#46170] " Tanguy LE CARROUR

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://guix.gnu.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20210129100948.26041-1-tanguy@bioneland.org \
    --to=tanguy@bioneland.org \
    --cc=46170@debbugs.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).