Skip to content

Commit e9a7614

Browse files
committed
Release 0.1.0 (#3)
* ci: changeset integration * chore: add changeset
1 parent 742d9d5 commit e9a7614

File tree

8 files changed

+525
-35
lines changed

8 files changed

+525
-35
lines changed

.changeset/config.json

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
{
2+
"$schema": "https://unpkg.com/@changesets/[email protected]/schema.json",
3+
"changelog": "@changesets/cli/changelog",
4+
"commit": false,
5+
"fixed": [],
6+
"linked": [],
7+
"access": "public",
8+
"baseBranch": "main",
9+
"updateInternalDependencies": "patch",
10+
"privatePackages": false,
11+
"ignore": []
12+
}

.changeset/thick-tips-sort.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
---
2+
'@contentauth/c2pa-wasm': minor
3+
'@contentauth/c2pa-web': minor
4+
---
5+
6+
Add minimal reader API
Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
name: 'Install dependencies'
2+
runs:
3+
using: 'composite'
4+
steps:
5+
- uses: dtolnay/rust-toolchain@stable
6+
with:
7+
target: wasm32-unknown-unknown
8+
9+
- uses: Swatinem/rust-cache@v2
10+
11+
# Install cargo-binstall
12+
- run: curl -L --proto '=https' --tlsv1.2 -sSf https://raw.githubusercontent.com/cargo-bins/cargo-binstall/main/install-from-binstall-release.sh | bash
13+
shell: bash
14+
15+
- run: cargo binstall [email protected] --no-confirm
16+
shell: bash
17+
- run: cargo binstall [email protected] --no-confirm
18+
shell: bash
19+
- run: cargo binstall [email protected] --no-confirm
20+
shell: bash
21+
22+
- uses: pnpm/action-setup@v4
23+
name: Install pnpm
24+
with:
25+
run_install: false
26+
27+
# Cache node_modules
28+
- uses: actions/setup-node@v4
29+
with:
30+
node-version: 24
31+
cache: 'pnpm'
32+
33+
- run: pnpm install --frozen-lockfile
34+
shell: bash

.github/workflows/ci.yml

Lines changed: 3 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -19,38 +19,10 @@ jobs:
1919
filter: tree:0
2020
fetch-depth: 0
2121

22-
- uses: dtolnay/rust-toolchain@stable
23-
with:
24-
target: wasm32-unknown-unknown
25-
26-
# Install cargo-binstall
27-
- run: curl -L --proto '=https' --tlsv1.2 -sSf https://raw.githubusercontent.com/cargo-bins/cargo-binstall/main/install-from-binstall-release.sh | bash
28-
29-
- run: cargo binstall [email protected] --no-confirm
30-
- run: cargo binstall [email protected] --no-confirm
31-
- run: cargo binstall [email protected] --no-confirm
32-
33-
- uses: pnpm/action-setup@v4
34-
name: Install pnpm
35-
with:
36-
run_install: false
37-
38-
# This enables task distribution via Nx Cloud
39-
# Run this command as early as possible, before dependencies are installed
40-
# Learn more at https://nx.dev/ci/reference/nx-cloud-cli#npx-nxcloud-startcirun
41-
# Uncomment this line to enable task distribution
42-
# - run: pnpm dlx nx start-ci-run --distribute-on="3 linux-medium-js" --stop-agents-after="build"
43-
44-
# Cache node_modules
45-
- uses: actions/setup-node@v4
46-
with:
47-
node-version: 20
48-
cache: 'pnpm'
49-
50-
- run: pnpm install --frozen-lockfile
22+
- uses: ./.github/actions/install-dependencies
23+
name: Install dependencies
5124

25+
# Install chrome + chromedriver for vitest + wasm-pack test
5226
- run: pnpx playwright install --with-deps
5327

54-
# Prepend any command with "nx-cloud record --" to record its logs to Nx Cloud
55-
# - run: pnpm exec nx-cloud record -- echo Hello World
5628
- run: pnpm exec nx run-many -t lint test build --projects=tag:lib

.github/workflows/release.yml

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
name: Release
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
8+
concurrency: ${{ github.workflow }}-${{ github.ref }}
9+
10+
jobs:
11+
release:
12+
name: Release
13+
runs-on: ubuntu-24.04
14+
steps:
15+
- uses: actions/checkout@v4
16+
with:
17+
filter: tree:0
18+
fetch-depth: 0
19+
20+
- uses: ./.github/actions/install-dependencies
21+
name: Install dependencies
22+
23+
- name: Create release PR or publish to npm
24+
id: changesets
25+
uses: changesets/action@v1
26+
with:
27+
publish: pnpm release
28+
env:
29+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
30+
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}

package.json

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,11 +2,17 @@
22
"name": "@contentauth/source",
33
"version": "0.0.0",
44
"license": "MIT",
5-
"scripts": {},
5+
"scripts": {
6+
"release": "pnpm prepublish && pnpm changeset:publish",
7+
"prepublish": "pnpm exec nx run-many -t build --projects=tag:lib",
8+
"changeset:publish": "changeset publish"
9+
},
610
"private": true,
711
"devDependencies": {
12+
"@changesets/cli": "^2.29.6",
813
"@eslint/js": "^9.8.0",
914
"@monodon/rust": "^2.3.0",
15+
"@nx/devkit": "21.3.5",
1016
"@nx/eslint": "21.3.5",
1117
"@nx/eslint-plugin": "21.3.5",
1218
"@nx/js": "21.3.5",
@@ -33,8 +39,7 @@
3339
"typescript-eslint": "^8.29.0",
3440
"vite": "^6.0.0",
3541
"vite-plugin-dts": "~4.5.0",
36-
"vitest": "^3.0.0",
37-
"@nx/devkit": "21.3.5"
42+
"vitest": "^3.0.0"
3843
},
3944
"packageManager": "[email protected]"
4045
}

packages/c2pa-wasm/package.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
{
22
"name": "@contentauth/c2pa-wasm",
33
"version": "0.0.1",
4-
"private": true,
54
"type": "module",
65
"module": "./pkg/c2pa.js",
76
"types": "./pkg/c2pa.d.ts",

0 commit comments

Comments
 (0)