```
goos: linux
goarch: amd64
pkg: github.com/ucan-wg/go-varsig
cpu: 13th Gen Intel(R) Core(TM) i7-1360P
│ old.txt │ new.txt │
│ sec/op │ sec/op vs base │
DecodeHashAlgorithm-16 145.65n ± 10% 59.62n ± 30% -59.07% (p=0.000 n=10)
DecodePayloadEncoding-16 136.65n ± 46% 50.02n ± 5% -63.40% (p=0.000 n=10)
geomean 141.1n 54.60n -61.29%
│ old.txt │ new.txt │
│ B/op │ B/op vs base │
DecodeHashAlgorithm-16 48.00 ± 0% 48.00 ± 0% ~ (p=1.000 n=10) ¹
DecodePayloadEncoding-16 48.00 ± 0% 48.00 ± 0% ~ (p=1.000 n=10) ¹
geomean 48.00 48.00 +0.00%
¹ all samples are equal
│ old.txt │ new.txt │
│ allocs/op │ allocs/op vs base │
DecodeHashAlgorithm-16 1.000 ± 0% 1.000 ± 0% ~ (p=1.000 n=10) ¹
DecodePayloadEncoding-16 1.000 ± 0% 1.000 ± 0% ~ (p=1.000 n=10) ¹
geomean 1.000 1.000 +0.00%
¹ all samples are equal
```
go-varsig
go-varsig implements the upcoming v1.0.0 release of the varsig specification
with limited (and soon to be deprecated) support for the varsig < v1.0
specification. This is predominatly included to support the UCAN v1.0
use-case.
Usage
Include the go-varsig library by running the following command:
go get github.com/ucan-wg/go-varsig@latest
Documentation
Documentation for this library is provided as Go docs at https://pkg.go.dev/github.com/ucan-wg/go-varsig.
Development
Install the required development tools using asdf by running the
following command in this repository (or install them manually):
asdf install
Checks
This repository contains an set of pre-commit hooks that are run prior to
each git commit. You can also run these checks manually using the
following command:
pre-commit run --all-files
Github workflows development
ASDF installs act to support Github workflow development - in general,
follow these steps to test the workflow:
If you're using podman instead of docker, use the podman socket to
simulate the docker daemon:
export DOCKER_HOST=unix:///var/run/podman/podman.sock
Since there's only one workflow, the simplest command to test it is:
act