Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/ldez/grignotin
A collection of small helpers around Go proxy, Go meta information, etc.
https://github.com/ldez/grignotin
go golang golang-library
Last synced: 13 days ago
JSON representation
A collection of small helpers around Go proxy, Go meta information, etc.
- Host: GitHub
- URL: https://github.com/ldez/grignotin
- Owner: ldez
- License: apache-2.0
- Created: 2020-02-29T19:20:21.000Z (over 4 years ago)
- Default Branch: main
- Last Pushed: 2024-07-15T14:06:42.000Z (4 months ago)
- Last Synced: 2024-10-14T13:08:48.948Z (21 days ago)
- Topics: go, golang, golang-library
- Language: Go
- Homepage:
- Size: 64.5 KB
- Stars: 1
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: readme.md
- Funding: .github/FUNDING.yml
Awesome Lists containing this project
README
# Grignotin
[![GitHub tag (latest SemVer)](https://img.shields.io/github/tag/ldez/grignotin.svg)](https://github.com/ldez/grignotin/releases)
[![PkgGoDev](https://pkg.go.dev/badge/github.com/ldez/grignotin)](https://pkg.go.dev/github.com/ldez/grignotin)
[![Build Status](https://github.com/ldez/grignotin/actions/workflows/ci.yml/badge.svg)](https://github.com/ldez/grignotin/actions)A collection of small helpers around Go proxy, Go meta information, etc.
## goproxy
A small Go proxy client to get information about a module from a Go proxy.
```go
package mainimport (
"fmt""github.com/ldez/grignotin/goproxy"
)func main() {
client := goproxy.NewClient("")versions, err := client.GetVersions("github.com/ldez/grignotin")
if err != nil {
panic(err)
}fmt.Println(versions)
}
```## metago
A small lib to fetch meta information (`go-import`, `go-source`) for a module.
```go
package mainimport (
"fmt""github.com/ldez/grignotin/metago"
)func main() {
meta, err := metago.Get("github.com/ldez/grignotin")
if err != nil {
panic(err)
}fmt.Println(meta)
}
```## Version
Gets information about releases and build.
```go
package mainimport (
"fmt""github.com/ldez/grignotin/version"
)func main() {
includeAll := false
releases, err := version.GetReleases(includeAll)
if err != nil {
panic(err)
}fmt.Println(releases)
}
``````go
package mainimport (
"fmt""github.com/ldez/grignotin/version"
)func main() {
build, err := version.GetBuild()
if err != nil {
panic(err)
}fmt.Println(build)
}
```## SumDB
- I recommend using the package [sumdb](https://pkg.go.dev/golang.org/x/mod/sumdb?tab=doc)