go-1.20-dredd
Go 1.20+ language plugin for semver-dredd.
Installation
# Install via the core package extra
pip install "semver-dredd[go]"
# Or install the plugin distribution directly
pip install go-1.20-dredd
Or install from local path (development):
pip install ./plugins/go-1.20-dredd
Requirements
- Python 3.10+
- semver-dredd >= 1.0.20260704001
- Go 1.20+ installed and available in PATH
Usage
Once installed, the plugin is automatically discovered by semver-dredd:
# List plugins to verify installation
semver-dredd plugin list
semver-dredd plugin info go
# Generate snapshot for a Go package
semver-dredd snapshot --plugin go --path ./mypackage --version 1.0.0
# Or use the managed init/status/bake workflow
semver-dredd init ./mypackage --plugin go --version 1.0.0
semver-dredd status ./mypackage --plugin go --details
semver-dredd bake ./mypackage --plugin go
How it works
This plugin bundles a Go parser that uses Go's go/ast package to extract:
- Public functions and their signatures
- Public types (structs) with exported fields
- Methods on public types
- Parameter types and return types
The parser is invoked via go run . from the bundled parser directory.
Scope: include / exclude
include and exclude items are Go import paths relative to the analyzed
root directory, using / separators (Go import-path convention), matched
recursively:
include: [sub]
exclude: [sub/internal]
- Empty
include(or omitted) analyzes the whole package tree rooted at--path, exactly as without scope. - The parser walks the root directory recursively; each subdirectory
containing
.gofiles is treated as its own package. The root package's functions/types are unprefixed (preserving pre-scope single-package behavior); nested packages are prefixed with their relative import path, e.g.sub/Areaorsub/internal/Helper. excludeis applied afterincludeand supports a trailing*for non-recursive (single import path level) exclusion, e.g.sub/internal*excludes onlysub/internalitself, not further-nested packages under it._test.gofiles and hidden/vendor/testdatadirectories are never part of the analyzed API surface.includematching no package produces an empty snapshot API (logged as a warning) rather than falling back to no-scope behavior.
Metadata
Release files for go-1.20-dredd 1.1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| go_1_20_dredd-1.1.0.tar.gz | 11.9 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| go_1_20_dredd-1.1.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 24.8 kB
Release files / go_1_20_dredd-1.1.0.tar.gz
| Download URL | go_1_20_dredd-1.1.0.tar.gz |
|---|---|
| Size | 11.9 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
185bf164677e5de430bfcab043e5ddd5ccba5fe0ebeffffec18c33efacdbbf2f
|
|
BLAKE2b-256 checksum How to use checksums |
fe29393a66aeca51b1aacd8cc42b468129d1afb44ed4d1d298610424cc4fc83b
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.10.19
|
Release files / go_1_20_dredd-1.1.0-py3-none-any.whl
| Download URL | go_1_20_dredd-1.1.0-py3-none-any.whl |
|---|---|
| Size | 12.8 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
865ac1e98120e36a9f32821dac0cc9bfd26d408cd89ef4914303d6bf056fb220
|
|
BLAKE2b-256 checksum How to use checksums |
7785f2365ed074f73c144f8d26e6f5d820e18e7d1548c6deb78fe9655365f22d
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.10.19
|