Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 19 additions & 0 deletions .github/workflows/bump.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
name: Bump Version

on:
workflow_dispatch:
inputs:
version:
description: 'New version (e.g. 0.1.0)'
required: true
type: string

jobs:
bump:
uses: tidywf/.github/.github/workflows/bump.yaml@main
permissions:
contents: write
with:
pkg_name: nemo
pkg_version: ${{ inputs.version }}
secrets: inherit
12 changes: 11 additions & 1 deletion CLAUDE.md
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,17 @@ R code is formatted with [air](https://github.com/posit-dev/air) (100-char line

## Version Bumping and Release Workflow

Use `make bump VERSION=x.y.z` to bump the version. This runs `bump-my-version` (configured in `.bumpversion.toml`), which updates all version references across the repo in a single commit with the message `Bump version: OLD => NEW`. The CI workflow (`deploy.yaml`) triggers on that commit message pattern to build and publish the conda package and docs.
Bumping is done via the `.github/workflows/bump.yaml` GitHub Actions workflow, which installs the package, bumps all version references, renders `README.qmd`, and pushes a single `Bump version: OLD => NEW` commit directly to the branch (using the bot token to bypass branch protection). The `deploy.yaml` workflow triggers on that commit message pattern.

Trigger it from the CLI:

```bash
make bump VERSION=x.y.z BRANCH=dev
# or on main:
make bump VERSION=x.y.z BRANCH=main
```

This calls `gh workflow run bump.yaml --ref BRANCH --field version=VERSION` under the hood. Can also be triggered via the GitHub Actions UI: Actions → Bump Version → Run workflow.

## CI/CD: `.github/workflows/deploy.yaml`

Expand Down
10 changes: 5 additions & 5 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,9 @@ build-readme: build readme

bump:
ifndef VERSION
$(error VERSION is not set. Usage: make bump VERSION=x.y.z)
$(error VERSION is not set. Usage: make bump VERSION=x.y.z BRANCH=dev)
endif
@bump-my-version bump --new-version $(VERSION)
@$(MAKE) --no-print-directory build-readme
@git add README.md
@git commit --amend --no-edit
ifndef BRANCH
$(error BRANCH is not set. Usage: make bump VERSION=x.y.z BRANCH=dev)
endif
@gh workflow run bump.yaml --ref $(BRANCH) --field version=$(VERSION)
Loading