https://github.com/utahta/nsync
A named mutual exclusion lock written in Go
https://github.com/utahta/nsync
go golang mutex named
Last synced: 12 days ago
JSON representation
A named mutual exclusion lock written in Go
- Host: GitHub
- URL: https://github.com/utahta/nsync
- Owner: utahta
- License: mit
- Created: 2017-11-29T05:24:58.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2017-11-29T13:28:25.000Z (over 8 years ago)
- Last Synced: 2025-03-04T17:37:13.543Z (over 1 year ago)
- Topics: go, golang, mutex, named
- Language: Go
- Homepage:
- Size: 5.86 KB
- Stars: 1
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# nsync
[](http://godoc.org/github.com/utahta/nsync)
[](https://travis-ci.org/utahta/nsync)
[](https://codecov.io/gh/utahta/nsync)
[](https://goreportcard.com/report/github.com/utahta/nsync)
A named mutual exclusion lock written in Go.
## Usage
```go
import "github.com/utahta/nsync"
func main() {
var mux nsync.Mutex
name := "lock name"
mux.Lock(name)
defer mux.Unlock(name)
}
```