unofficial mirror of guix-patches@gnu.org 
 help / color / mirror / code / Atom feed
* [bug#63729] [PATCH] gnu: Add greaseweazle-host-tools.
@ 2023-05-25 19:17 Rikard Nordgren
  2023-07-01 10:17 ` bug#63729: " Nicolas Goaziou
  2023-07-02 18:08 ` [bug#63729] Thanks Rikard Nordgren
  0 siblings, 2 replies; 3+ messages in thread
From: Rikard Nordgren @ 2023-05-25 19:17 UTC (permalink / raw)
  To: 63729; +Cc: hrn

---
 gnu/packages/disk.scm | 37 +++++++++++++++++++++++++++++++++++++
 1 file changed, 37 insertions(+)

diff --git a/gnu/packages/disk.scm b/gnu/packages/disk.scm
index 894a542171..93be910aef 100644
--- a/gnu/packages/disk.scm
+++ b/gnu/packages/disk.scm
@@ -76,6 +76,9 @@ (define-module (gnu packages disk)
   #:use-module (gnu packages pkg-config)
   #:use-module (gnu packages popt)
   #:use-module (gnu packages python)
+  #:use-module (gnu packages python-build)
+  #:use-module (gnu packages python-crypto)
+  #:use-module (gnu packages python-web)
   #:use-module (gnu packages python-xyz)
   #:use-module (gnu packages qt)
   #:use-module (gnu packages readline)
@@ -572,6 +575,40 @@ (define-public idle3-tools
 and can dramatically shorten the lifespan of the drive if left unchecked.")
     (license license:gpl3+)))
 
+(define-public greaseweazle-host-tools
+  (package
+    (name "greaseweazle-host-tools")
+    (version "1.12")
+    (source (origin
+              (method git-fetch)
+              (uri (git-reference
+                    (url "https://github.com/keirf/greaseweazle")
+                    (commit "v1.12")))
+              (file-name (git-file-name name version))
+              (sha256
+               (base32
+                "1lpvjlf2xg4ccwik8npiihi0lgw9dx5h12pp4ry343gkz4pwgk9x"))))
+    (build-system python-build-system)
+    (arguments
+     `(#:phases (modify-phases %standard-phases
+                  (add-before 'build 'setuptools-version
+                    (lambda _
+                      (setenv "SETUPTOOLS_SCM_PRETEND_VERSION" "1.8") #t))
+                  (add-after 'install 'install-udev-rules
+                    (lambda* (#:key outputs #:allow-other-keys)
+                      (install-file "scripts/49-greaseweazle.rules"
+                                    (string-append (assoc-ref outputs "out")
+                                                   "/lib/udev/rules.d/")))))))
+    (native-inputs (list python-setuptools-scm))
+    (propagated-inputs (list python-bitarray python-pyserial python-requests
+                             python-crcmod))
+    (synopsis "Tools for accessing a floppy drive at the raw flux level")
+    (description
+     "The host tools for controlling a Greaseweazle: an Open Source USB device
+capable of reading and writing raw data on nearly any type of floppy disk")
+    (home-page "https://github.com/keirf/greaseweazle")
+    (license license:public-domain)))
+
 (define-public gparted
   (package
     (name "gparted")

base-commit: 1be6baed2b58a75868cdcc9f51b78624c2fefc4f
-- 
2.30.2





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

* bug#63729: [PATCH] gnu: Add greaseweazle-host-tools.
  2023-05-25 19:17 [bug#63729] [PATCH] gnu: Add greaseweazle-host-tools Rikard Nordgren
@ 2023-07-01 10:17 ` Nicolas Goaziou
  2023-07-02 18:08 ` [bug#63729] Thanks Rikard Nordgren
  1 sibling, 0 replies; 3+ messages in thread
From: Nicolas Goaziou @ 2023-07-01 10:17 UTC (permalink / raw)
  To: Rikard Nordgren; +Cc: 63729-done

Hello,

Rikard Nordgren <hrn@posteo.net> writes:

> ---
>  gnu/packages/disk.scm | 37 +++++++++++++++++++++++++++++++++++++
>  1 file changed, 37 insertions(+)

Applied with a proper commit message and changes described below. Thank you.

> +(define-public greaseweazle-host-tools
> +  (package
> +    (name "greaseweazle-host-tools")
> +    (version "1.12")
> +    (source (origin
> +              (method git-fetch)
> +              (uri (git-reference
> +                    (url "https://github.com/keirf/greaseweazle")
> +                    (commit "v1.12")))

I re-used the version here:

  (commit (string-append "v" version))

> +    (arguments
> +     `(#:phases (modify-phases %standard-phases

I used G-expressions:

  (arguments (list #:phases #~(modify-phases ...)))

> +                  (add-before 'build 'setuptools-version
> +                    (lambda _
> +                      (setenv "SETUPTOOLS_SCM_PRETEND_VERSION" "1.8") #t))

No need for trailing #T at the end of phases; il removed it.

> +                  (add-after 'install 'install-udev-rules
> +                    (lambda* (#:key outputs #:allow-other-keys)

I removed the outputs argument...

> +                      (install-file "scripts/49-greaseweazle.rules"
> +                                    (string-append (assoc-ref outputs "out")

... and used (string-append #$output ...)

> +                                                   "/lib/udev/rules.d/")))))))
> +    (native-inputs (list python-setuptools-scm))
> +    (propagated-inputs (list python-bitarray python-pyserial python-requests
> +                             python-crcmod))

Indentation is surprising here. I changed it.

> +    (synopsis "Tools for accessing a floppy drive at the raw flux level")
> +    (description
> +     "The host tools for controlling a Greaseweazle: an Open Source USB device
> +capable of reading and writing raw data on nearly any type of floppy disk")

Descriptions should consist of full sentences:

  "This package provides host tools for..."

Regards,
-- 
Nicolas Goaziou




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

* [bug#63729] Thanks
  2023-05-25 19:17 [bug#63729] [PATCH] gnu: Add greaseweazle-host-tools Rikard Nordgren
  2023-07-01 10:17 ` bug#63729: " Nicolas Goaziou
@ 2023-07-02 18:08 ` Rikard Nordgren
  1 sibling, 0 replies; 3+ messages in thread
From: Rikard Nordgren @ 2023-07-02 18:08 UTC (permalink / raw)
  To: 63729

Thanks for reviewing and the fixes!




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

end of thread, other threads:[~2023-07-03 13:09 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-05-25 19:17 [bug#63729] [PATCH] gnu: Add greaseweazle-host-tools Rikard Nordgren
2023-07-01 10:17 ` bug#63729: " Nicolas Goaziou
2023-07-02 18:08 ` [bug#63729] Thanks Rikard Nordgren

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).