On this page

Raw Markdown View this page on GitHub

Upgrading

Read the sections of the changelog between your release and the new one. A change that needs edits to application or project files states them. Then run these steps in the module root.

  1. Install the new CLI and check its version:

    go install github.com/romshark/datapages/cmd/datapages@latest
    datapages version
    
  2. Update the module. go get also raises the requirements that Datapages depends on, such as github.com/a-h/templ. Without this step, the first datapages gen can fail with go: updates to go.mod needed:

    go get github.com/romshark/datapages@latest
    go mod tidy
    
  3. Install the templ CLI of the templ version that go.mod now requires:

    go install github.com/a-h/templ/cmd/templ@$(go list -m -f '{{.Version}}' github.com/a-h/templ)
    
  4. Regenerate the code. Code generated by an older release may not compile with the new runtime until datapages gen replaces it:

    templ generate
    datapages gen
    
  5. Update the instructions for coding agents, as AI agents describes:

    datapages init -n
    
  6. In .github/workflows/ci.yml, change the versions in the go install github.com/romshark/datapages/cmd/datapages@ and go install github.com/a-h/templ/cmd/templ@ steps to the versions in go.mod. init does not rewrite the workflow. With the old versions, CI fails with go.mod requires github.com/romshark/datapages ... but you are running ... or templ generate produced uncommitted changes.

  7. If the app uses the offline module, increment offline.Config.WorkerVersion, as Keep snapshots safe and current describes.

  8. Check the application:

    datapages lint
    go build ./...
    go test ./...
    

Then deploy the new build.

Version policy

Datapages is in beta and ready for production use. Its APIs can still change in a release. The public API includes the root datapages package, packages under modules/ and generated packages such as href and action. The changelog lists each incompatible change under Changed or Removed and gives the required steps.

Packages under runtime/ serve generated code and may change in any release. datapages gen updates their callers. The CLI rejects imports of these packages from application code.

SECURITY.md states which releases receive security fixes.

See also

  • Changelog: every change of each release and the steps it needs
  • CLI: the version checks and the update check
  • AI agents: what datapages init -n rewrites and keeps
  • SECURITY.md: supported releases and how to report a vulnerability
  • Installation: the tools and their versions