all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* [bug#41032] [PATCH] Add makepasswd package
@ 2020-05-02 20:37 Jean-Baptiste Note
  2020-05-05 16:49 ` Marius Bakke
  0 siblings, 1 reply; 4+ messages in thread
From: Jean-Baptiste Note @ 2020-05-02 20:37 UTC (permalink / raw)
  To: 41032


[-- Attachment #1.1: Type: text/plain, Size: 377 bytes --]

Dear Guix maintainers,

Here is an attempt at packaging makepasswd, a run-time dependency of
x2go.

I've placed it in its own file which may be ill-advised for now; please
let me know where I could more sensibly move it.

Hopefully patches will follow that put more flesh in this x2go.scm file;
however I find this program useful in its own right.

Kind regards,
Jean-Baptiste

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1.2: add makepasswd --]
[-- Type: text/x-patch, Size: 3313 bytes --]

From f8c9c93e359f4f65a12709f244e6e8952db4bad9 Mon Sep 17 00:00:00 2001
From: Jean-Baptiste Note <jean-baptiste.note@m4x.org>
Date: Sat, 2 May 2020 05:50:20 +0000
Subject: [PATCH] x2go: Add makepasswd.

* gnu/packages/x2go.scm: New file.

* gnu/packages/xorg.scm (makepasswd): New variable.
---
 gnu/packages/x2go.scm | 66 +++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 66 insertions(+)
 create mode 100644 gnu/packages/x2go.scm

diff --git a/gnu/packages/x2go.scm b/gnu/packages/x2go.scm
new file mode 100644
index 0000000000..b77f81cee5
--- /dev/null
+++ b/gnu/packages/x2go.scm
@@ -0,0 +1,66 @@
+;;; GNU Guix --- Functional package management for GNU
+;;;
+;;; This file is part of GNU Guix.
+;;;
+;;; GNU Guix is free software; you can redistribute it and/or modify it
+;;; under the terms of the GNU General Public License as published by
+;;; the Free Software Foundation; either version 3 of the License, or (at
+;;; your option) any later version.
+;;;
+;;; GNU Guix is distributed in the hope that it will be useful, but
+;;; WITHOUT ANY WARRANTY; without even the implied warranty of
+;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+;;; GNU General Public License for more details.
+;;;
+;;; You should have received a copy of the GNU General Public License
+;;; along with GNU Guix.  If not, see <http://www.gnu.org/licenses/>.
+
+(define-module (gnu packages x2go)
+  #:use-module ((guix licenses) #:prefix license:)
+  #:use-module (guix packages)
+  #:use-module (guix git-download)
+  #:use-module (guix build-system gnu)
+  #:use-module (guix utils)
+  #:use-module (gnu packages)
+  #:use-module (gnu packages pkg-config)
+  #:use-module (gnu packages tls)
+  #:use-module (gnu packages xml)
+  #:use-module (gnu packages docbook))
+
+(define-public makepasswd
+  (let ((commit "3545d57d3a589a392d7eb0df36a5286785345c9e")
+        (revision "1"))
+    (package
+      (name "makepasswd")
+      (version (git-version "0.5.4" revision commit))
+      (source
+       (origin
+         (method git-fetch)
+         (uri (git-reference
+               (url "https://github.com/khorben/makepasswd")
+               (commit commit)))
+         (file-name (git-file-name name version))
+         (sha256
+          (base32 "0lspqyyxbk6h28yxnp7pd5aib161vrkzgasam5jpzn35n1jacx2j"))))
+      (build-system gnu-build-system)
+      (native-inputs
+       `(("pkg-config" ,pkg-config)
+         ("libxslt" ,libxslt)
+         ("libxml2" ,libxml2)
+         ("docbook-xsl" ,docbook-xsl)
+         ("docbook-xml" ,docbook-xml)))
+      (inputs
+       `(("openssl" ,openssl)))
+      (arguments
+       `(#:phases
+         (modify-phases %standard-phases
+           (delete 'configure))
+         #:make-flags (list "CC=gcc" (string-append "PREFIX=" (assoc-ref %outputs "out")))
+         #:tests? #f))
+      (synopsis "Generate (pseudo-)random passwords and hashes")
+      (description
+       "Makepasswd is a program that generates pseudo-random passwords of a
+desired length.  It can also generate their corresponding hashes for a given
+encryption algorithm if so desired.")
+      (home-page "https://github.com/khorben/makepasswd")
+      (license license:gpl3))))
-- 
2.26.2


[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 832 bytes --]

^ permalink raw reply related	[flat|nested] 4+ messages in thread

* [bug#41032] [PATCH] Add makepasswd package
  2020-05-02 20:37 [bug#41032] [PATCH] Add makepasswd package Jean-Baptiste Note
@ 2020-05-05 16:49 ` Marius Bakke
  2020-05-05 18:47   ` Jean-Baptiste Note
  0 siblings, 1 reply; 4+ messages in thread
From: Marius Bakke @ 2020-05-05 16:49 UTC (permalink / raw)
  To: Jean-Baptiste Note, 41032

[-- Attachment #1: Type: text/plain, Size: 347 bytes --]

Jean-Baptiste Note <jean-baptiste.note@m4x.org> writes:

> Dear Guix maintainers,
>
> Here is an attempt at packaging makepasswd, a run-time dependency of
> x2go.
>
> I've placed it in its own file which may be ill-advised for now; please
> let me know where I could more sensibly move it.

Perhaps password-utils.scm could work for this package?

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 487 bytes --]

^ permalink raw reply	[flat|nested] 4+ messages in thread

* [bug#41032] [PATCH] Add makepasswd package
  2020-05-05 16:49 ` Marius Bakke
@ 2020-05-05 18:47   ` Jean-Baptiste Note
  2020-05-06 20:29     ` bug#41032: " Marius Bakke
  0 siblings, 1 reply; 4+ messages in thread
From: Jean-Baptiste Note @ 2020-05-05 18:47 UTC (permalink / raw)
  To: Marius Bakke; +Cc: 41032


[-- Attachment #1.1: Type: text/plain, Size: 304 bytes --]

Hi Marius,

Thanks for your review and the heads up on the correct file.
Please find an updated patch.

I've used guix-devel-mode and ran indent-according-to-mode on the buffer
before producing the patch; let me know if this is not sufficient to
correctly indent the code :)

Kind regards,
Jean-Baptiste

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1.2: update makepasswd patch --]
[-- Type: text/x-patch, Size: 2602 bytes --]

From 3d8786e2b818e28e79fc62eb6872bea1400a1d24 Mon Sep 17 00:00:00 2001
From: Jean-Baptiste Note <jean-baptiste.note@m4x.org>
Date: Sat, 2 May 2020 05:50:20 +0000
Subject: [PATCH] gnu: Add makepasswd.

* gnu/packages/password-utils.scm (makepasswd): New variable.
---
 gnu/packages/password-utils.scm | 39 +++++++++++++++++++++++++++++++++
 1 file changed, 39 insertions(+)

diff --git a/gnu/packages/password-utils.scm b/gnu/packages/password-utils.scm
index 2a570691a4..59c7befddc 100644
--- a/gnu/packages/password-utils.scm
+++ b/gnu/packages/password-utils.scm
@@ -61,6 +61,7 @@
   #:use-module (gnu packages crypto)
   #:use-module (gnu packages cryptsetup)
   #:use-module (gnu packages curl)
+  #:use-module (gnu packages docbook)
   #:use-module (gnu packages file)
   #:use-module (gnu packages freedesktop)
   #:use-module (gnu packages gettext)
@@ -1168,3 +1169,41 @@ exhaustive mode to try every password given a charset or in dictionary mode to
 try every password contained in a file.")
     (home-page "https://github.com/glv2/bruteforce-luks")
     (license license:gpl3+)))
+
+(define-public makepasswd
+  (let ((commit "3545d57d3a589a392d7eb0df36a5286785345c9e")
+        (revision "1"))
+    (package
+      (name "makepasswd")
+      (version (git-version "0.5.4" revision commit))
+      (source
+       (origin
+         (method git-fetch)
+         (uri (git-reference
+               (url "https://github.com/khorben/makepasswd")
+               (commit commit)))
+         (file-name (git-file-name name version))
+         (sha256
+          (base32 "0lspqyyxbk6h28yxnp7pd5aib161vrkzgasam5jpzn35n1jacx2j"))))
+      (build-system gnu-build-system)
+      (native-inputs
+       `(("pkg-config" ,pkg-config)
+         ("libxslt" ,libxslt)
+         ("libxml2" ,libxml2)
+         ("docbook-xsl" ,docbook-xsl)
+         ("docbook-xml" ,docbook-xml)))
+      (inputs
+       `(("openssl" ,openssl)))
+      (arguments
+       `(#:phases
+         (modify-phases %standard-phases
+           (delete 'configure))
+         #:make-flags (list "CC=gcc" (string-append "PREFIX=" (assoc-ref %outputs "out")))
+         #:tests? #f))
+      (synopsis "Generate (pseudo-)random passwords and hashes")
+      (description
+       "Makepasswd is a program that generates pseudo-random passwords of a
+desired length.  It can also generate their corresponding hashes for a given
+encryption algorithm if so desired.")
+      (home-page "https://github.com/khorben/makepasswd")
+      (license license:gpl3))))
-- 
2.26.2


[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 832 bytes --]

^ permalink raw reply related	[flat|nested] 4+ messages in thread

* bug#41032: [PATCH] Add makepasswd package
  2020-05-05 18:47   ` Jean-Baptiste Note
@ 2020-05-06 20:29     ` Marius Bakke
  0 siblings, 0 replies; 4+ messages in thread
From: Marius Bakke @ 2020-05-06 20:29 UTC (permalink / raw)
  To: Jean-Baptiste Note; +Cc: 41032-done

[-- Attachment #1: Type: text/plain, Size: 1174 bytes --]

Jean-Baptiste Note <jean-baptiste.note@m4x.org> writes:

> Hi Marius,
>
> Thanks for your review and the heads up on the correct file.
> Please find an updated patch.
>
> I've used guix-devel-mode and ran indent-according-to-mode on the buffer
> before producing the patch; let me know if this is not sufficient to
> correctly indent the code :)

Thanks!  My Emacs agrees, so LGTM.

[...]

> +      (arguments
> +       `(#:phases
> +         (modify-phases %standard-phases
> +           (delete 'configure))
> +         #:make-flags (list "CC=gcc" (string-append "PREFIX=" (assoc-ref %outputs "out")))

I moved the second flag to its own line as 89 characters is a bit much.

> +         #:tests? #f))

And added a comment about why tests are disabled.

> +      (synopsis "Generate (pseudo-)random passwords and hashes")
> +      (description
> +       "Makepasswd is a program that generates pseudo-random passwords of a
> +desired length.  It can also generate their corresponding hashes for a given
> +encryption algorithm if so desired.")
> +      (home-page "https://github.com/khorben/makepasswd")
> +      (license license:gpl3))))

Indeed GPL3 only :-/

Applied!

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 487 bytes --]

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2020-05-06 20:31 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-05-02 20:37 [bug#41032] [PATCH] Add makepasswd package Jean-Baptiste Note
2020-05-05 16:49 ` Marius Bakke
2020-05-05 18:47   ` Jean-Baptiste Note
2020-05-06 20:29     ` bug#41032: " Marius Bakke

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/guix.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.