aboutsummaryrefslogtreecommitdiff
path: root/config.go
diff options
context:
space:
mode:
authorMaria <m5ka+github@posteo.de>2024-05-21 19:09:28 +0100
committerGitHub <noreply@github.com>2024-05-21 11:09:28 -0700
commitd9a9a9071d16c779a390d94666f736e1e96c48dc (patch)
tree6d4a677f2fda60ba3c99c08a47d15b559fd739de /config.go
parente6df748e5cbb326b77dac6086bff78ac814e1708 (diff)
downloadsally-d9a9a9071d16c779a390d94666f736e1e96c48dc.tar.gz
feat: Allow packages to define custom documentation URL and badge (#147)
feat: Allow packages to define custom doc URL and badge Co-authored-by: Jacob Oaks <jacoboaks.8@gmail.com> Co-authored-by: r-hang <rhang@uber.com>
Diffstat (limited to 'config.go')
-rw-r--r--config.go13
1 files changed, 13 insertions, 0 deletions
diff --git a/config.go b/config.go
index 25b32fd..1c8c069 100644
--- a/config.go
+++ b/config.go
@@ -53,6 +53,19 @@ type PackageConfig struct {
// Desc is a plain text description of this module.
Desc string `yaml:"description"`
+
+ // DocURL is the link to this module's documentation.
+ //
+ // Defaults to the base doc URL specified in the top-level config
+ // with the package path appended.
+ DocURL string `yaml:"doc_url"`
+
+ // DocBadge is the URL of the badge which links to this module's
+ // documentation.
+ //
+ // Defaults to the pkg.go.dev badge URL with this module's path as a
+ // parameter.
+ DocBadge string `yaml:"doc_badge"`
}
// Parse takes a path to a yaml file and produces a parsed Config