Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/maragudk/snorkel
Scuba for the rest of us.
https://github.com/maragudk/snorkel
Last synced: 6 days ago
JSON representation
Scuba for the rest of us.
- Host: GitHub
- URL: https://github.com/maragudk/snorkel
- Owner: maragudk
- License: mit
- Created: 2024-04-29T10:54:10.000Z (9 months ago)
- Default Branch: main
- Last Pushed: 2024-09-19T09:28:22.000Z (4 months ago)
- Last Synced: 2025-01-03T02:17:21.223Z (7 days ago)
- Language: Go
- Homepage:
- Size: 736 KB
- Stars: 2
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# snorkel
[![GoDoc](https://pkg.go.dev/badge/maragu.dev/snorkel)](https://pkg.go.dev/maragu.dev/snorkel)
[![Go](https://github.com/maragudk/snorkel/actions/workflows/ci.yml/badge.svg)](https://github.com/maragudk/snorkel/actions/workflows/ci.yml)[Scuba](https://research.facebook.com/publications/scuba-diving-into-data-at-facebook/) for the rest of us.
```shell
go get maragu.dev/snorkel
```Made in 🇩🇰 by [maragu](https://www.maragu.dk/), maker of [online Go courses](https://www.golang.dk/).
## Features
- Simple logger with just a single method, `Event`, which logs named events with a given sample rate.
- Sane defaults log to STD_ERR and include event name, sample rate, time, and build info. More to come.
- No external dependencies.## Usage
```go
package mainimport (
"maragu.dev/snorkel"
)func main() {
log := snorkel.New(snorkel.Options{})// Log an event with the name "Yo", sample rate 1, and env=sparkly
log.Event("Yo", 1, "env", "sparkly")
}
```