diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml
index 71a9ccb..e37f240 100644
--- a/.github/workflows/ci.yml
+++ b/.github/workflows/ci.yml
@@ -29,14 +29,14 @@ jobs:
uses: purpleclay/github/.github/workflows/go-test.yml@main
strategy:
matrix:
- os: [ubuntu-latest, macos-latest, windows-latest]
+ os: [ubuntu-24.04, macos-14, windows-2022]
with:
go-version: ${{ vars.GO_VERSION }}
secrets:
github-token: ${{ secrets.GITHUB_TOKEN }}
lint:
- runs-on: ubuntu-latest
+ runs-on: ubuntu-24.04
steps:
- name: Checkout
uses: actions/checkout@v4
diff --git a/.github/workflows/codeql.yml b/.github/workflows/codeql.yml
index 0e83063..e058c7c 100644
--- a/.github/workflows/codeql.yml
+++ b/.github/workflows/codeql.yml
@@ -13,7 +13,7 @@ on:
jobs:
analyze:
name: Analyze
- runs-on: ubuntu-latest
+ runs-on: ubuntu-24.04
permissions:
actions: read
contents: read
diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml
index 6e10fe0..9d592c3 100644
--- a/.github/workflows/docs.yml
+++ b/.github/workflows/docs.yml
@@ -19,7 +19,7 @@ permissions:
jobs:
build-docs:
- runs-on: ubuntu-latest
+ runs-on: ubuntu-24.04
steps:
- name: Checkout repository
uses: actions/checkout@v4
@@ -31,7 +31,7 @@ jobs:
with:
registry: ghcr.io
username: ${{ github.repository_owner }}
- password: ${{ secrets.GITHUB_TOKEN }}
+ password: ${{ secrets.GH_GHCR }}
- run: docker pull ghcr.io/purpleclay/mkdocs-material-insiders:${{ vars.MKDOCS_MATERIAL_INSIDERS_VERSION }}
diff --git a/.github/workflows/nsv.yml b/.github/workflows/nsv.yml
index a06c648..8510770 100644
--- a/.github/workflows/nsv.yml
+++ b/.github/workflows/nsv.yml
@@ -4,7 +4,7 @@ on:
jobs:
nsv:
- runs-on: ubuntu-latest
+ runs-on: ubuntu-24.04
permissions:
contents: write
steps:
diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml
index ad9d90e..85247ea 100644
--- a/.github/workflows/release.yml
+++ b/.github/workflows/release.yml
@@ -12,7 +12,7 @@ permissions:
jobs:
goreleaser:
- runs-on: ubuntu-latest
+ runs-on: ubuntu-24.04
steps:
- name: Git Clone
uses: actions/checkout@v4
@@ -48,13 +48,6 @@ jobs:
username: ${{ github.repository_owner }}
password: ${{ secrets.GITHUB_TOKEN }}
- - name: GitLab Login
- uses: docker/login-action@v3
- with:
- registry: registry.gitlab.com
- username: ${{ secrets.GL_DOCKER_USERNAME }}
- password: ${{ secrets.GL_DOCKER_PASSWORD }}
-
- name: GoReleaser
uses: goreleaser/goreleaser-action@v5
with:
diff --git a/.github/workflows/shellcheck.yml b/.github/workflows/shellcheck.yml
index 17acd52..df59143 100644
--- a/.github/workflows/shellcheck.yml
+++ b/.github/workflows/shellcheck.yml
@@ -16,7 +16,7 @@ permissions:
jobs:
shellcheck:
- runs-on: ubuntu-latest
+ runs-on: ubuntu-24.04
name: shellcheck
steps:
- name: Checkout repository
diff --git a/.goreleaser.yaml b/.goreleaser.yaml
index 42602f2..302132d 100644
--- a/.goreleaser.yaml
+++ b/.goreleaser.yaml
@@ -35,7 +35,6 @@ archives:
{{- if .Arm }}v{{ .Arm }}{{ end }}
builds:
- nsv
- rlcp: true
format_overrides:
- goos: windows
format: zip
@@ -58,7 +57,7 @@ changelog:
- "^ci"
groups:
- title: "Dependency Updates"
- regexp: "^.*feat\\(deps\\)*:+.*$"
+ regexp: "^.*fix\\(deps\\)*:+.*$"
order: 30
- title: "New Features"
regexp: "^.*feat[(\\w)]*:+.*$"
@@ -100,7 +99,6 @@ dockers:
- image_templates:
- "purpleclay/nsv:{{ .Tag }}-amd64"
- "ghcr.io/purpleclay/nsv:{{ .Tag }}-amd64"
- - "registry.gitlab.com/purpleclay/nsv:{{ .Tag }}-amd64"
dockerfile: Dockerfile
use: buildx
build_flag_templates:
@@ -117,7 +115,6 @@ dockers:
- image_templates:
- "purpleclay/nsv:{{ .Tag }}-arm64"
- "ghcr.io/purpleclay/nsv:{{ .Tag }}-arm64"
- - "registry.gitlab.com/purpleclay/nsv:{{ .Tag }}-arm64"
dockerfile: Dockerfile
use: buildx
build_flag_templates:
@@ -142,10 +139,6 @@ docker_manifests:
image_templates:
- "ghcr.io/purpleclay/nsv:{{ .Tag }}-amd64"
- "ghcr.io/purpleclay/nsv:{{ .Tag }}-arm64"
- - name_template: "registry.gitlab.com/purpleclay/nsv:{{ .Tag }}"
- image_templates:
- - "registry.gitlab.com/purpleclay/nsv:{{ .Tag }}-amd64"
- - "registry.gitlab.com/purpleclay/nsv:{{ .Tag }}-arm64"
- name_template: "purpleclay/nsv:latest"
image_templates:
- "purpleclay/nsv:{{ .Tag }}-amd64"
@@ -154,10 +147,6 @@ docker_manifests:
image_templates:
- "ghcr.io/purpleclay/nsv:{{ .Tag }}-amd64"
- "ghcr.io/purpleclay/nsv:{{ .Tag }}-arm64"
- - name_template: "registry.gitlab.com/purpleclay/nsv:latest"
- image_templates:
- - "registry.gitlab.com/purpleclay/nsv:{{ .Tag }}-amd64"
- - "registry.gitlab.com/purpleclay/nsv:{{ .Tag }}-arm64"
brews:
- name: nsv
diff --git a/README.md b/README.md
index 0968e12..c95ce6c 100644
--- a/README.md
+++ b/README.md
@@ -17,11 +17,13 @@ The power is at your fingertips.
### Features
- First-class support for semantic versioning. Conventional commits help give it a nudge in the right direction.
+- Configure your Conventional Commit prefixes for complete control.
- If you batch your commits per release or prefer a continuous delivery approach, it has you covered.
- Context-aware, it automatically switches to a monorepo workflow.
- Extend the power of your commits through commands to dynamically change your semantic release workflow.
- Explore how to use it within the purpose-built playground.
- Get up and running in seconds within GitHub and GitLab with the available [action](https://github.com/purpleclay/nsv-action) or [template](https://gitlab.com/purpleclay/nsv).
+- First class [Dagger](https://dagger.io/) support.
## Documentation
diff --git a/Taskfile.yaml b/Taskfile.yaml
index a3ddd16..8c0f711 100644
--- a/Taskfile.yaml
+++ b/Taskfile.yaml
@@ -70,3 +70,10 @@ tasks:
TEST_OPTIONS: '{{default "-bench=. -benchtime 5s -benchmem" .TEST_OPTIONS}}'
cmds:
- go test {{.TEST_OPTIONS}} -run=^# ./...
+
+ docs:
+ desc: Builds and hosts the MkDocs documentation
+ vars:
+ MKDOCS_MATERIAL_VERSION: '{{default "9.5.26-insiders-4.53.11" .MKDOCS_MATERIAL_VERSION}}'
+ cmds:
+ - docker run --rm -it -p 8000:8000 -v $PWD:/docs ghcr.io/purpleclay/mkdocs-material-insiders:{{.MKDOCS_MATERIAL_VERSION}}
diff --git a/docs/ci/dagger.md b/docs/ci/dagger.md
new file mode 100644
index 0000000..9996ea3
--- /dev/null
+++ b/docs/ci/dagger.md
@@ -0,0 +1,84 @@
+---
+icon: material/sword
+social:
+ cards: false
+status: new
+---
+
+# Using Dagger in your CI
+
+:material-test-tube: experimental
+
+## GitHub Action
+
+Run [nsv](https://daggerverse.dev/mod/github.com/purpleclay/daggerverse/nsv) using the official Dagger [GitHub Action](https://github.com/dagger/dagger-for-github). The Dagger Cloud offers enhanced layer caching, which can be enabled by setting a `DAGGER_CLOUD_TOKEN` environment variable.
+
+```{.yaml .no-select linenums="1"}
+name: ci
+on:
+ push:
+ branches:
+ - main
+jobs:
+ nsv:
+ runs-on: ubuntu-latest
+ permissions:
+ contents: write
+ steps:
+ - name: Checkout
+ uses: actions/checkout@v4
+ with:
+ fetch-depth: 0
+ token: ${{ secrets.GH_NSV }} # (1)!
+
+ - name: Tag
+ uses: dagger/dagger-for-github@v5
+ env:
+ GPG_PRIVATE_KEY: "${{ secrets.GPG_PRIVATE_KEY }}"
+ GPG_PASSPHRASE: "${{ secrets.GPG_PASSPHRASE }}"
+ with:
+ verb: call
+ module: github.com/purpleclay/daggerverse/nsv
+ args: --src . tag --show --gpg-private-key env:GPG_PRIVATE_KEY --gpg-passphrase env:GPG_PASSPHRASE
+ cloud-token: ${{ secrets.DAGGER_CLOUD_TOKEN }}
+```
+
+1. A PAT token triggers another workflow after tagging the repository; this is optional.
+
+## GitLab Template
+
+The same Dagger experience is possible within GitLab using the Purple Clay [template](https://gitlab.com/purpleclay/templates/-/blob/main/dagger/README.md?ref_type=heads). The Dagger Cloud offers enhanced layer caching, which can be enabled by setting a `DAGGER_CLOUD_TOKEN` environment variable.
+
+```{.yaml .no-select linenums="1" hl_lines="28-29"}
+include:
+ - "https://gitlab.com/purpleclay/templates/-/raw/dagger/0.11.6/dagger/Mixed.gitlab-ci.yml"
+
+ nsv:
+ extends: [.dagger]
+ stage: release
+ rules:
+ - if: $CI_COMMIT_TAG
+ when: never
+ - if: $CI_PIPELINE_SOURCE == "schedule"
+ when: never
+ - if: $CI_MERGE_REQUEST_IID
+ when: never
+ - if: $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH
+ when: on_success
+ variables:
+ GIT_DEPTH: 0
+ GIT_STRATEGY: clone
+ DAGGER_MODULE: "github.com/purpleclay/daggerverse/nsv"
+ DAGGER_ARGS: >-
+ --src .
+ tag
+ --show
+ --paths ${WORKING_DIRECTORY}
+ --gpg-private-key env:NSV_GPG_PRIVATE_KEY
+ --gpg-passphrase env:NSV_GPG_PASSPHRASE
+ before_script: # (1)!
+ - PROJECT_URL=${CI_PROJECT_URL#"https://"}
+ - git remote set-url origin "https://oauth2:${NSV_GITLAB_TOKEN}@${PROJECT_URL}.git"
+```
+
+1. To push a newly created tag, an access token with `:write_repository` permissions is required. Here, it is assigned to the `NSV_GITLAB_TOKEN` CI variable.
diff --git a/docs/github-action.md b/docs/ci/github-action.md
similarity index 97%
rename from docs/github-action.md
rename to docs/ci/github-action.md
index 2545c72..cd1e2bb 100644
--- a/docs/github-action.md
+++ b/docs/ci/github-action.md
@@ -12,7 +12,7 @@ To get up and running within a GitHub workflow, include the publicly available `
If you wish to tag the repository without triggering another workflow, you must set the permissions of the job to `contents: write`.
-```{.yaml linenums="1" hl_lines="10"}
+```{.yaml .no-select linenums="1" hl_lines="10"}
name: ci
on:
push:
diff --git a/docs/gitlab-template.md b/docs/ci/gitlab-template.md
similarity index 92%
rename from docs/gitlab-template.md
rename to docs/ci/gitlab-template.md
index bc23d21..17a9371 100644
--- a/docs/gitlab-template.md
+++ b/docs/ci/gitlab-template.md
@@ -10,7 +10,7 @@ To get up and running within a GitLab pipeline, include the publicly available `
## Tagging a repository
-```{.yaml linenums="1"}
+```{.yaml .no-select linenums="1"}
include:
- https://gitlab.com/purpleclay/nsv/-/raw/main/nsv.gitlab-ci.yml
```
diff --git a/docs/commands.md b/docs/commands.md
index 76b8da4..623af8a 100644
--- a/docs/commands.md
+++ b/docs/commands.md
@@ -1,7 +1,6 @@
---
icon: material/apple-keyboard-command
description: Advanced control of semantic versioning through dedicated commands
-status: new
---
# Control your workflow with Commands
diff --git a/docs/configurable-prefixes.md b/docs/configurable-prefixes.md
new file mode 100644
index 0000000..08daa10
--- /dev/null
+++ b/docs/configurable-prefixes.md
@@ -0,0 +1,46 @@
+---
+icon: material/apple-keyboard-command
+description: Advanced control of semantic versioning through dedicated commands
+status: new
+---
+
+# Configure your Conventional prefixes
+
+[Conventional Commits](https://www.conventionalcommits.org/en/v1.0.0/) offers a fantastic approach to controlling semantic versioning through commit prefixes. An industry standard convention devised by the Angular team is most commonly used to date.
+
+- `BREAKING CHANGE`: any commit with this footer triggers a major update.
+- `!`: any conventional prefix with this suffix (e.g. `refactor!`) triggers a major update.
+- `feat`: triggers a minor update.
+- `fix`: triggers a patch update.
+
+## Defining your own rules
+
+- `breaking`: triggers a major update `1.0.0` ~> `2.0.0`.
+- `feat`, `deps`: triggers a minor update `0.1.0` ~> `0.2.0`.
+- `fix`, `docs`, `styles`: triggers a patch update `0.3.1` ~> `0.3.2`.
+
+=== "ENV"
+
+ ```{ .sh .no-select }
+ NSV_MAJOR_PREFIXES=breaking \
+ NSV_MINOR_PREFIXES=feat,deps \
+ NSV_PATCH_PREFIXES=fix,docs,styles \
+ nsv next
+ ```
+
+=== "CLI"
+
+ ```{ .sh .no-select }
+ nsv next --major-prefixes breaking \
+ --minor-prefixes feat,deps \
+ --patch-prefixes fix,docs,styles
+ ```
+
+Don't worry—when defining your custom prefixes, both the `BREAKING CHANGE` footer and the `!` suffix are automatically supported.
+
+## How prefix matching works
+
+`nsv` matches a prefix in one of two ways:
+
+- `breaking` is a wildcard prefix capable of matching against an optional scope.
+- `breaking(api)` is an exact match only.
diff --git a/docs/docker/dagger.md b/docs/docker/dagger.md
new file mode 100644
index 0000000..c4edb21
--- /dev/null
+++ b/docs/docker/dagger.md
@@ -0,0 +1,83 @@
+---
+icon: material/sword
+social:
+ cards: false
+status: new
+---
+
+# Running with Dagger
+
+:material-test-tube: experimental
+
+[Dagger](https://dagger.io/) provides a way to define tasks that can run on your favorite CI/CD platform or locally. Powered by Docker, it is incredibly easy to get up and running.
+
+## Installing Dagger
+
+Read the official documentation for complete [instructions](https://docs.dagger.io/install).
+
+=== "macOS"
+
+ ```{ .sh .no-select }
+ brew install dagger/tap/dagger
+ ```
+
+=== "Linux"
+
+ ```{ .sh .no-select }
+ curl -L https://dl.dagger.io/dagger/install.sh | BIN_DIR=$HOME/.local/bin sh
+ ```
+
+=== "Windows"
+
+ ```{ .sh .no-select }
+ Invoke-WebRequest -UseBasicParsing -Uri https://dl.dagger.io/dagger/install.ps1 | Invoke-Expression
+ ```
+
+=== "Nix Flake"
+
+ ```{ .nix .no-select }
+ {
+ inputs = {
+ nixpkgs.url = "github:nixos/nixpkgs?ref=nixos-unstable";
+ flake-utils.url = "github:numtide/flake-utils";
+
+ dagger = {
+ url = "github:dagger/nix";
+ inputs = {
+ nixpkgs.follows = "nixpkgs";
+ };
+ };
+ };
+
+ outputs = { self, nixpkgs, flake-utils, dagger }:
+ flake-utils.lib.eachDefaultSystem (system:
+ let
+ pkgs = nixpkgs.legacyPackages.${system};
+ in
+ with pkgs;
+ {
+ devShells.default = mkShell {
+ buildInputs = [
+ dagger.packages.${system}.dagger
+ ];
+ };
+ }
+ );
+ }
+ ```
+
+## Next semantic version
+
+Calculates the next semantic version and prints it to stdout. For full configuration [options](../next-version.md).
+
+```{ .sh .no-select }
+dagger call -m github.com/purpleclay/daggerverse/nsv --src . next
+```
+
+## Tagging the next version
+
+Tags a repository with the next semantic version. For full configuration [options](../tag-version.md).
+
+```{ .sh .no-select }
+dagger call -m github.com/purpleclay/daggerverse/nsv --src . tag
+```
diff --git a/docs/docker/running.md b/docs/docker/running.md
index fae2969..788579b 100644
--- a/docs/docker/running.md
+++ b/docs/docker/running.md
@@ -11,13 +11,13 @@ You can run `nsv` directly from a docker image. Just mount your repository as a
=== "DockerHub"
```{ .sh .no-select }
- docker run --rm -v $PWD:/work -w /work purpleclay/nsv:v0.3.0
+ docker run --rm -v $PWD:/work -w /work purpleclay/nsv:v0.8.0
```
=== "GHCR"
```{ .sh .no-select }
- docker run --rm -v $PWD:/work -w /work ghcr.io/purpleclay/nsv:v0.3.0
+ docker run --rm -v $PWD:/work -w /work ghcr.io/purpleclay/nsv:v0.8.0
```
## Verifying with cosign
@@ -28,16 +28,16 @@ Docker images can be verified using [cosign](https://github.com/sigstore/cosign)
```{ .sh .no-select }
cosign verify \
- --certificate-identity 'https://github.com/purpleclay/nsv/.github/workflows/release.yml@refs/tags/v0.3.0' \
+ --certificate-identity 'https://github.com/purpleclay/nsv/.github/workflows/release.yml@refs/tags/v0.8.0' \
--certificate-oidc-issuer 'https://token.actions.githubusercontent.com' \
- purpleclay/nsv:v0.3.0
+ purpleclay/nsv:v0.8.0
```
=== "GHCR"
```{ .sh .no-select }
cosign verify \
- --certificate-identity 'https://github.com/purpleclay/nsv/.github/workflows/release.yml@refs/tags/v0.3.0' \
+ --certificate-identity 'https://github.com/purpleclay/nsv/.github/workflows/release.yml@refs/tags/v0.8.0' \
--certificate-oidc-issuer 'https://token.actions.githubusercontent.com' \
- ghcr.io/purpleclay/nsv:v0.3.0
+ ghcr.io/purpleclay/nsv:v0.8.0
```
diff --git a/docs/index.md b/docs/index.md
index fa3dcdb..f543448 100644
--- a/docs/index.md
+++ b/docs/index.md
@@ -27,8 +27,10 @@ The power is at your fingertips.
### Features
- First-class support for semantic versioning. Conventional commits help give it a nudge in the right direction.
+- Configure your Conventional Commit prefixes for complete control.
- If you batch your commits per release or prefer a continuous delivery approach, it has you covered.
- Context-aware, it automatically switches to a monorepo workflow.
- Extend the power of your commits through commands to dynamically change your semantic release workflow.
- Explore how to use it within the purpose-built playground. :material-test-tube: experimental
- Get up and running in seconds within GitHub :material-github: and GitLab :material-gitlab: with the available [action](https://github.com/purpleclay/nsv-action) or [template](https://gitlab.com/purpleclay/nsv).
+- First class [Dagger](https://dagger.io/) :material-sword: support. :material-test-tube: experimental
diff --git a/docs/overrides/main.html b/docs/overrides/main.html
index 2c5b7d4..f0c17e5 100644
--- a/docs/overrides/main.html
+++ b/docs/overrides/main.html
@@ -9,11 +9,10 @@
{% block announce %}
For updates follow @purpleclaydev on
-
+
- Twitter
and
diff --git a/docs/reference/cli/nsv-next.md b/docs/reference/cli/nsv-next.md
index ea7388a..996ebd6 100644
--- a/docs/reference/cli/nsv-next.md
+++ b/docs/reference/cli/nsv-next.md
@@ -13,14 +13,26 @@ of your repository.
Environment Variables:
-| Name | Description |
-|------------|----------------------------------------------------------------|
-| NO_COLOR | switch to using an ASCII color profile within the terminal |
-| NSV_FORMAT | provide a go template for changing the default version format |
-| NSV_PRETTY | pretty-print the output of the next semantic version in a |
-| | given format. The format can be one of either full or compact. |
-| | full is the default. Must be used in conjunction with NSV_SHOW |
-| NSV_SHOW | show how the next semantic version was generated |
+| Name | Description |
+|--------------------|--------------------------------------------------------|
+| LOG_LEVEL | the level of logging when printing to stderr |
+| | (default: info) |
+| NO_COLOR | switch to using an ASCII color profile within the |
+| | terminal |
+| NO_LOG | disable all log output |
+| NSV_FORMAT | provide a go template for changing the default version |
+| | format |
+| NSV_MAJOR_PREFIXES | a comma separated list of conventional commit prefixes |
+| | or triggering a major semantic version increment |
+| NSV_MINOR_PREFIXES | a comma separated list of conventional commit prefixes |
+| | for triggering a minor semantic version increment |
+| NSV_PATCH_PREFIXES | a comma separated list of conventional commit prefixes |
+| | for triggering a patch semantic version increment |
+| NSV_PRETTY | pretty-print the output of the next semantic version |
+| | in a given format. The format can be one of either |
+| | full or compact. Must be used in conjunction with |
+| | NSV_SHOW (default: full) |
+| NSV_SHOW | show how the next semantic version was generated |
```
## Usage
@@ -32,18 +44,30 @@ nsv next [...] [flags]
## Flags
```{ .text .no-select .no-copy }
--f, --format string provide a go template for changing the default version
- format
--h, --help help for next
--p, --pretty string pretty-print the output of the next semantic version in
- a given format. The format can be one of either full or
- compact. Must be used in conjunction with --show
- (default "full")
--s, --show show how the next semantic version was generated
+-f, --format string provide a go template for changing the default
+ version format
+-h, --help help for next
+ --major-prefixes strings a comma separated list of conventional commit
+ prefixes for triggering a major semantic version
+ increment
+ --minor-prefixes strings a comma separated list of conventional commit
+ prefixes for triggering a minor semantic version
+ increment
+ --patch-prefixes strings a comma separated list of conventional commit
+ prefixes for triggering a patch semantic version
+ increment
+-p, --pretty string pretty-print the output of the next semantic
+ version in a given format. The format can be one
+ of either full or compact. Must be used in
+ conjunction with --show (default "full")
+-s, --show show how the next semantic version was generated
```
## Global Flags
```{ .text .no-select .no-copy }
---no-color switch to using an ASCII color profile within the terminal
+--log-level string the level of logging when printing to stderr
+ (default "info")
+--no-color switch to using an ASCII color profile within the terminal
+--no-log disable all log output
```
diff --git a/docs/reference/cli/nsv-tag.md b/docs/reference/cli/nsv-tag.md
index 99643e2..f7f03ea 100644
--- a/docs/reference/cli/nsv-tag.md
+++ b/docs/reference/cli/nsv-tag.md
@@ -13,19 +13,29 @@ commit history of your repository.
Environment Variables:
-| Name | Description |
-|-----------------|-----------------------------------------------------------|
-| NO_COLOR | switch to using an ASCII color profile within the |
-| | terminal |
-| NSV_FORMAT | provide a go template for changing the default version |
-| | format |
-| NSV_PRETTY | pretty-print the output of the next semantic version in |
-| | a given format. The format can be one of either full or |
-| | compact. full is the default. Must be used in conjunction |
-| | with NSV_SHOW |
-| NSV_SHOW | show how the next semantic version was generated |
-| NSV_TAG_MESSAGE | a custom message for the tag, supports go text templates. |
-| | The default is: "chore: tagged release {{.Tag}}" |
+| Name | Description |
+|--------------------|--------------------------------------------------------|
+| LOG_LEVEL | the level of logging when printing to stderr |
+| | (default: info) |
+| NO_COLOR | switch to using an ASCII color profile within the |
+| | terminal |
+| NO_LOG | disable all log output |
+| NSV_FORMAT | provide a go template for changing the default version |
+| | format |
+| NSV_MAJOR_PREFIXES | a comma separated list of conventional commit prefixes |
+| | or triggering a major semantic version increment |
+| NSV_MINOR_PREFIXES | a comma separated list of conventional commit prefixes |
+| | for triggering a minor semantic version increment |
+| NSV_PATCH_PREFIXES | a comma separated list of conventional commit prefixes |
+| | for triggering a patch semantic version increment |
+| NSV_PRETTY | pretty-print the output of the next semantic version |
+| | in a given format. The format can be one of either |
+| | full or compact. Must be used in conjunction with |
+| | NSV_SHOW (default: full) |
+| NSV_SHOW | show how the next semantic version was generated |
+| NSV_TAG_MESSAGE | a custom message for the tag, supports go text |
+| | templates. The default is: "chore: tagged release |
+| | {{.Tag}}" |
```
## Usage
@@ -37,20 +47,33 @@ nsv tag [...] [flags]
## Flags
```{ .text .no-select .no-copy }
--f, --format string provide a go template for changing the default version
- format
--h, --help help for tag
--m, --message string a custom message for the tag, supports go text templates
- (default "chore: tagged release {{.Tag}}")
--p, --pretty string pretty-print the output of the next semantic version in
- a given format. The format can be one of either full or
- compact. Must be used in conjunction with --show
- (default "full")
--s, --show show how the next semantic version was generated
+-f, --format string provide a go template for changing the default
+ version format
+-h, --help help for tag
+ --major-prefixes strings a comma separated list of conventional commit
+ prefixes for triggering a major semantic version
+ increment
+-m, --message string a custom message for the tag, supports go text
+ templates (default "chore: tagged release
+ {{.Tag}}")
+ --minor-prefixes strings a comma separated list of conventional commit
+ prefixes for triggering a minor semantic version
+ increment
+ --patch-prefixes strings a comma separated list of conventional commit
+ prefixes for triggering a patch semantic version
+ increment
+-p, --pretty string pretty-print the output of the next semantic
+ version in a given format. The format can be one
+ of either full or compact. Must be used in
+ conjunction with --show (default "full")
+-s, --show show how the next semantic version was generated
```
## Global Flags
```{ .text .no-select .no-copy }
---no-color switch to using an ASCII color profile within the terminal
+--log-level string the level of logging when printing to stderr
+ (default "info")
+--no-color switch to using an ASCII color profile within the terminal
+--no-log disable all log output
```
diff --git a/docs/reference/cli/nsv.md b/docs/reference/cli/nsv.md
index d9b3fc7..e593f17 100644
--- a/docs/reference/cli/nsv.md
+++ b/docs/reference/cli/nsv.md
@@ -26,9 +26,11 @@ The power is at your fingertips.
Global Environment Variables:
-| Name | Description |
-|----------|---------------------------------------------------------------|
-| NO_COLOR | switch to using an ASCII color profile within the terminal |
+| Name | Description |
+|-----------|--------------------------------------------------------------|
+| LOG_LEVEL | the level of logging when printing to stderr (default: info) |
+| NO_COLOR | switch to using an ASCII color profile within the terminal |
+| NO_LOG | disable all log output |
```
## Usage
@@ -51,6 +53,10 @@ version Print build time version information
## Flags
```{ .text .no-select .no-copy }
--h, --help help for nsv
- --no-color switch to using an ASCII color profile within the terminal
+-h, --help help for nsv
+ --log-level string the level of logging when printing to stderr
+ (default "info")
+ --no-color switch to using an ASCII color profile within the
+ terminal
+ --no-log disable all log output
```
diff --git a/docs/reference/env-vars.md b/docs/reference/env-vars.md
index c6bffa9..3af47f8 100644
--- a/docs/reference/env-vars.md
+++ b/docs/reference/env-vars.md
@@ -11,10 +11,15 @@ If you need to customize the behavior of `nsv` you can use the supported environ
## Variables
-| Variable Name | Description |
-| ----------------- | -------------------------------------------------------------------------------------- |
-| `NO_COLOR` | switch to using an ASCII color profile within the terminal |
-| `NSV_FORMAT` | set a go template for formatting the provided tag |
-| `NSV_PRETTY` | pretty-print the output of the next semantic version in a given format |
-| `NSV_SHOW` | show how the next semantic version was generated |
-| `NSV_TAG_MESSAGE` | a custom message for the tag, overrides the default: `chore: tagged release ` |
+| Variable Name | Description |
+| -------------------- | ------------------------------------------------------------------------------------------------------------- |
+| `LOG_LEVEL` | the level of logging when printing to stderr
(`debug`, `info`, `warn`, `error`, `fatal`) |
+| `NO_COLOR` | switch to using an ASCII color profile within the terminal |
+| `NO_LOG` | disable all log output |
+| `NSV_FORMAT` | set a go template for formatting the provided tag |
+| `NSV_MAJOR_PREFIXES` | a comma separated list of conventional commit prefixes for triggering
a major semantic version increment |
+| `NSV_MINOR_PREFIXES` | a comma separated list of conventional commit prefixes for triggering
a minor semantic version increment |
+| `NSV_PATCH_PREFIXES` | a comma separated list of conventional commit prefixes for triggering
a patch semantic version increment |
+| `NSV_PRETTY` | pretty-print the output of the next semantic version in a given format |
+| `NSV_SHOW` | show how the next semantic version was generated |
+| `NSV_TAG_MESSAGE` | a custom message for the tag, overrides the default:
`chore: tagged release ` |
diff --git a/docs/reference/templating.md b/docs/reference/templating.md
index 5666234..3331d18 100644
--- a/docs/reference/templating.md
+++ b/docs/reference/templating.md
@@ -1,6 +1,5 @@
---
icon: material/application-cog-outline
-status: new
title: Flexibility through Templating
description: Customize behavior with go templates
---
diff --git a/docs/stylesheets/extra.css b/docs/stylesheets/extra.css
index f423a70..23fe6a1 100644
--- a/docs/stylesheets/extra.css
+++ b/docs/stylesheets/extra.css
@@ -11,18 +11,18 @@
}
.md-typeset .twitter {
- color: #00acee;
+ color: #fff;
}
-.md-typeset a:hover>span * {
+.md-typeset a:hover > span * {
filter: brightness(85%);
}
.new-feature {
- color: #006C39;
+ color: #006c39;
}
-.rounded-pill{
+.rounded-pill {
background-color: var(--md-primary-fg-color);
color: var(--md-primary-bg-color);
border-radius: 2em;
diff --git a/mkdocs.yml b/mkdocs.yml
index 66731aa..f1c003d 100644
--- a/mkdocs.yml
+++ b/mkdocs.yml
@@ -44,17 +44,21 @@ nav:
- Getting Started:
- Next Version: next-version.md
- Semantic Commands: commands.md
+ - Conventional Prefixes: configurable-prefixes.md
- Playground: playground.md
- Tag Version: tag-version.md
- Monorepos: monorepos.md
- Pretty Print: pretty.md
- - Github Action: github-action.md
- - GitLab Template: gitlab-template.md
- Installation:
- Binary: install/binary.md
- From Source: install/source.md
- Docker:
- Run with Docker: docker/running.md
+ - Run with Dagger: docker/dagger.md
+ - CI:
+ - Github Action: ci/github-action.md
+ - GitLab Template: ci/gitlab-template.md
+ - Dagger: ci/dagger.md
- Other Bits:
- License: license.md
- Reference:
@@ -71,9 +75,9 @@ extra:
- icon: fontawesome/brands/github
link: https://github.com/purpleclay
name: Purple Clay on GitHub
- - icon: fontawesome/brands/twitter
- link: https://twitter.com/purpleclaydev
- name: Purple Clay on Twitter
+ - icon: fontawesome/brands/x-twitter
+ link: https://x.com/purpleclaydev
+ name: Purple Clay on X
- icon: fontawesome/brands/mastodon
link: https://fosstodon.org/@purpleclaydev
name: Purple Clay on Fosstodon
@@ -81,7 +85,7 @@ extra:
link: https://hub.docker.com/u/purpleclay
name: Purple Clay on Docker Hub
status:
- new: New Features Added
+ new: New
deprecated: No Longer Supported
plugins: