diff mbox series

[bug#44969,2/7] gnu: Added go-github-com-felixge-httpsnoop.

Message ID 20201130202408.27437-2-mjbecze@riseup.net
State Accepted
Headers show
Series Update trezord to 2.0.30 | expand

Checks

Context Check Description
cbaines/submitting builds success
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

Martin Becze Nov. 30, 2020, 8:24 p.m. UTC
* gnu/packages/golang.scm (go-github-com-felixge-httpsnoop): New variable.
---
 gnu/packages/golang.scm | 25 +++++++++++++++++++++++++
 1 file changed, 25 insertions(+)

Comments

Christopher Baines Dec. 8, 2020, 9:01 a.m. UTC | #1
Martin Becze <mjbecze@riseup.net> writes:

> * gnu/packages/golang.scm (go-github-com-felixge-httpsnoop): New variable.

So, the commit message should say Add rather than Added. This is both
for consistency, and because it makes more sense for commits to say what
they will do when applied, rather than reading like something's already
happened.

> ---
>  gnu/packages/golang.scm | 25 +++++++++++++++++++++++++
>  1 file changed, 25 insertions(+)
>
> diff --git a/gnu/packages/golang.scm b/gnu/packages/golang.scm
> index fed32d65ec..e72d7026de 100644
> --- a/gnu/packages/golang.scm
> +++ b/gnu/packages/golang.scm
> @@ -22,6 +22,7 @@
>  ;;; Copyright © 2020 Ryan Prior <rprior@protonmail.com>
>  ;;; Copyright © 2020 Marius Bakke <marius@gnu.org>
>  ;;; Copyright © 2020 raingloom <raingloom@riseup.net>
> +;;; Copyright © 2020 Martin Becze <mjbecze@riseup.net>
>  ;;;
>  ;;; This file is part of GNU Guix.
>  ;;;
> @@ -6039,3 +6040,27 @@ JSON data to the machine.")
>  systems can import this package to enable running programs as services without
>  modifying them.")
>      (license license:zlib)))
> +
> +(define-public go-github-com-felixge-httpsnoop
> +  (package
> +    (name "go-github-com-felixge-httpsnoop")
> +    (version "1.0.1")
> +    (source
> +     (origin
> +       (method git-fetch)
> +       (uri (git-reference
> +             (url "https://github.com/felixge/httpsnoop")
> +             (commit (string-append "v" version))))
> +       (file-name (git-file-name name version))
> +       (sha256
> +        (base32
> +         "0ncd8lar5zxiwjhsp315s4hsl4bhnm271h49jhyxc66r5yffgmac"))))
> +    (build-system go-build-system)
> +    (arguments
> +     '(#:import-path "github.com/felixge/httpsnoop"))
> +    (home-page "https://github.com/felixge/httpsnoop/")
> +    (synopsis "Capture http related metric")
> +    (description "Httpsnoop provides an easy way to capture http
> +related metrics (i.e. response time, bytes written, and http status
> + code) from your application's http.Handlers.")
> +    (license license:expat)))

Adding packages at the bottom of modules is something to try and
avoid. When other patches do the same thing, it causes merge conflicts.
diff mbox series

Patch

diff --git a/gnu/packages/golang.scm b/gnu/packages/golang.scm
index fed32d65ec..e72d7026de 100644
--- a/gnu/packages/golang.scm
+++ b/gnu/packages/golang.scm
@@ -22,6 +22,7 @@ 
 ;;; Copyright © 2020 Ryan Prior <rprior@protonmail.com>
 ;;; Copyright © 2020 Marius Bakke <marius@gnu.org>
 ;;; Copyright © 2020 raingloom <raingloom@riseup.net>
+;;; Copyright © 2020 Martin Becze <mjbecze@riseup.net>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -6039,3 +6040,27 @@  JSON data to the machine.")
 systems can import this package to enable running programs as services without
 modifying them.")
     (license license:zlib)))
+
+(define-public go-github-com-felixge-httpsnoop
+  (package
+    (name "go-github-com-felixge-httpsnoop")
+    (version "1.0.1")
+    (source
+     (origin
+       (method git-fetch)
+       (uri (git-reference
+             (url "https://github.com/felixge/httpsnoop")
+             (commit (string-append "v" version))))
+       (file-name (git-file-name name version))
+       (sha256
+        (base32
+         "0ncd8lar5zxiwjhsp315s4hsl4bhnm271h49jhyxc66r5yffgmac"))))
+    (build-system go-build-system)
+    (arguments
+     '(#:import-path "github.com/felixge/httpsnoop"))
+    (home-page "https://github.com/felixge/httpsnoop/")
+    (synopsis "Capture http related metric")
+    (description "Httpsnoop provides an easy way to capture http
+related metrics (i.e. response time, bytes written, and http status
+ code) from your application's http.Handlers.")
+    (license license:expat)))