aboutsummaryrefslogtreecommitdiff
path: root/gnu
diff options
context:
space:
mode:
authorGiovanni Biscuolo <g@xelera.eu>2019-03-18 17:46:05 +0100
committerLeo Famulari <leo@famulari.name>2019-03-18 13:23:42 -0400
commit4ddf067f214b83c2ab03ed52a7e9ddf6f4f6de66 (patch)
tree1fdc89280ecb3e0b820a52b3194318bf0df8a69b /gnu
parenta91f4eba2c923405ccdce5bdb390b12a40a856c2 (diff)
downloadpatches-4ddf067f214b83c2ab03ed52a7e9ddf6f4f6de66.tar
patches-4ddf067f214b83c2ab03ed52a7e9ddf6f4f6de66.tar.gz
gnu: Add go-github-com-burntsushi-locker
* gnu/packages/golang.scm (go-github-com-burntsushi-locker): New variable. Signed-off-by: Leo Famulari <leo@famulari.name>
Diffstat (limited to 'gnu')
-rw-r--r--gnu/packages/golang.scm35
1 files changed, 35 insertions, 0 deletions
diff --git a/gnu/packages/golang.scm b/gnu/packages/golang.scm
index 4bcd5cfcfe..6b5b9a4cb9 100644
--- a/gnu/packages/golang.scm
+++ b/gnu/packages/golang.scm
@@ -13,6 +13,7 @@
;;; Copyright © 2018 Pierre-Antoine Rouby <pierre-antoine.rouby@inria.fr>
;;; Copyright © 2018 Pierre Neidhardt <mail@ambrevar.xyz>
;;; Copyright @ 2018 Katherine Cox-Buday <cox.katherine.e@gmail.com>
+;;; Copyright @ 2019 Giovanni Biscuolo <g@xelera.eu>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -3177,3 +3178,37 @@ format in Go.")
(description "This package provides a text formatting functions in Go.")
(home-page "https://github.com/kr/text")
(license license:expat)))
+
+(define-public go-github-com-burntsushi-locker
+ (let ((commit "a6e239ea1c69bff1cfdb20c4b73dadf52f784b6a")
+ (revision "0"))
+ (package
+ (name "go-github-com-burntsushi-locker")
+ (version (git-version "0.0.0" revision commit))
+ (source
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/BurntSushi/locker")
+ (commit commit)))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+ "1xak4aync4klswq5217qvw191asgla51jr42y94vp109lirm5dzg"))))
+ (build-system go-build-system)
+ (arguments
+ '(#:import-path "github.com/BurntSushi/locker"))
+ (home-page "https://github.com/BurntSushi/locker")
+ (synopsis "Manage named ReadWrite mutexes in Go")
+ (description "Golang package for conveniently using named read/write
+locks. These appear to be especially useful for synchronizing access to
+session based information in web applications.
+
+The common use case is to use the package level functions, which use a package
+level set of locks (safe to use from multiple goroutines
+simultaneously). However, you may also create a new separate set of locks
+test.
+
+All locks are implemented with read-write mutexes. To use them like a regular
+mutex, simply ignore the RLock/RUnlock functions.")
+ (license license:unlicense))))