diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml new file mode 100644 index 0000000..1c6e0a4 --- /dev/null +++ b/.github/workflows/publish.yml @@ -0,0 +1,33 @@ +name: Publish to npm + +on: + push: + tags: + - "v*.*.*" + workflow_dispatch: + +permissions: + id-token: write + +jobs: + publish: + runs-on: ubuntu-latest + environment: Publish + steps: + - name: Checkout + uses: actions/checkout@v4 + + - name: Set up Node + uses: actions/setup-node@v4 + with: + node-version: 24 + registry-url: https://registry.npmjs.org + + - name: Install dependencies + run: npm ci + + - name: Build + run: npm run build + + - name: Publish + run: npm publish --access public diff --git a/CHANGELOG.md b/CHANGELOG.md index d1b6ae9..e750e40 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,16 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/). +## [1.0.0] - 2026-08-08 + +### Added + +- Publish workflow: builds package and publishes to npm when vX.X.X tag is pushed. + +### Changed + +- First stable release - no functional changes from `0.1.0`. + ## [0.1.0] - 2026-08-08 ### Added diff --git a/README.md b/README.md index 6f34894..1baf451 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,10 @@ # zod-transformers +[![CI](https://github.com/figulusproject/zod-transformers/actions/workflows/ci.yml/badge.svg)](https://github.com/figulusproject/zod-transformers/actions/workflows/ci.yml) +[![NPM version](https://badge.fury.io/js/zod-transformers.svg)](http://badge.fury.io/js/zod-transformers) + +> _Everyone has the right to resist occupation._ + A collection of reusable Zod transform/superRefine schema factories for common patterns: empty-string coercion, stringified JSON/JSONC/TOML/YAML, prefix stripping, numeric strings, and filesystem-path validation. ## Installation diff --git a/package-lock.json b/package-lock.json index e98ba68..728da51 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "zod-transformers", - "version": "0.1.0", + "version": "1.0.0", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "zod-transformers", - "version": "0.1.0", + "version": "1.0.0", "license": "MIT", "devDependencies": { "@types/node": "^22", diff --git a/package.json b/package.json index 7793efc..c1da2ed 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "zod-transformers", - "version": "0.1.0", + "version": "1.0.0", "description": "A collection of reusable Zod transform/superRefine schema factories", "keywords": [ "zod",