diff mbox series

[bug#56951] gnu: packages: Add jrnlc.

Message ID 20220803131731.8771-1-paren@disroot.org
State New
Headers show
Series [bug#56951] gnu: packages: Add jrnlc. | expand

Checks

Context Check Description
cbaines/comparison success View comparision
cbaines/git-branch success View Git branch
cbaines/applying patch success View Laminar job
cbaines/issue success View issue

Commit Message

\( Aug. 3, 2022, 1:17 p.m. UTC
* gnu/packages/admin.scm (jrnlc): New variable.
---
 gnu/packages/admin.scm | 41 +++++++++++++++++++++++++++++++++++++++++
 1 file changed, 41 insertions(+)
diff mbox series

Patch

diff --git a/gnu/packages/admin.scm b/gnu/packages/admin.scm
index 146423d068..2d84787aef 100644
--- a/gnu/packages/admin.scm
+++ b/gnu/packages/admin.scm
@@ -5447,3 +5447,44 @@  (define-public fail2ban
 up services to use only two factor, or public/private authentication
 mechanisms if you really want to protect services.")
     (license license:gpl2+)))
+
+(define-public jrnlc
+  (package
+    (name "jrnlc")
+    (version "2022.a")
+    (source
+      (origin
+        (method git-fetch)
+        (uri (git-reference
+               (url "https://github.com/thexhr/jrnlc")
+               (commit version)))
+        (file-name (git-file-name name version))
+        (sha256
+          (base32 "10j4iyac41ndr9yic7vdkajf4kvvwzbd5jxpjypzybcygj9jq8h6"))))
+    (build-system gnu-build-system)
+    (arguments
+     (list #:make-flags
+           #~(list (string-append "PREFIX=" #$output)
+                   (string-append "CC=" #$(cc-for-target)))
+           #:tests? #f ; no check target
+           #:phases
+           #~(modify-phases %standard-phases
+               (add-after 'unpack 'patch-install-invocations
+                 (lambda _
+                  (substitute* "Makefile"
+                    (("-o root") ""))))
+               (delete 'configure)
+               (add-before 'install 'create-output-dirs
+                 (lambda* (#:key outputs #:allow-other-keys)
+                   (let ((out (assoc-ref outputs "out")))
+                     (mkdir-p (string-append out "/bin"))
+                     (mkdir-p (string-append out "/man"))))))))
+    (inputs (list json-c libsodium))
+    (native-inputs (list pkg-config))
+    (home-page "https://github.com/thexhr/jrnlc")
+    (synopsis "Opinionated command-line journal")
+    (description "@code{jrnlc} is a opinionated command line application
+for note-taking.  You can take notes by entering them on the command line
+or piping them from a file.  It supports full encryption of the journal,
+so that your notes remain secret.")
+    (license license:isc)))