diff --git a/CHANGELOG.md b/CHANGELOG.md index 95a7c22..f93f53e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -11,7 +11,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ### Added -- Compose Multiplatform module (`dev.kolektiv.themes:themes`) with `DaisyColors`, +- Compose Multiplatform module (`computer.kolektiv.themes:themes`) with `DaisyColors`, `KolektivTheme`, and the seven palettes generated from `tokens.json`. - Gradle wrapper so Kalendee / Blawk can `includeBuild` this repo. diff --git a/README.md b/README.md index 787d5ff..58b38e1 100644 --- a/README.md +++ b/README.md @@ -9,7 +9,7 @@ targets from one source: | `@kolektiv/themes/theme.css` | daisyUI-compatible `[data-theme]` colour variables | | `@kolektiv/themes/shiki` | Shiki theme registrations (Kolektiv light/dark) | | `@kolektiv/themes/tokens.json` | raw tokens for Compose / other platforms | -| `dev.kolektiv.themes:themes` | Compose Multiplatform `DaisyColors` + `KolektivTheme` | +| `computer.kolektiv.themes:themes` | Compose Multiplatform `DaisyColors` + `KolektivTheme` | **Colour-only by design.** A theme declares `color-scheme` and the twenty daisyUI colour variables; each app owns its radii, sizes, borders and density. Palettes: `nord`, @@ -20,7 +20,7 @@ kolektiv → kolektiv). ## Publishing -See [docs/PUBLISHING.md](./docs/PUBLISHING.md). Maven coordinates: `dev.kolektiv.themes:themes` (Yuri Capital + GitHub Packages). npm: `` `@kolektiv/themes` `` (Yuri `brand-npm` + GitHub Packages). JSR: `` `@kolektiv/themes` `` when linked. +See [docs/PUBLISHING.md](./docs/PUBLISHING.md). Maven coordinates: `computer.kolektiv.themes:themes` (Yuri Capital + GitHub Packages). npm: `` `@kolektiv/themes` `` (Yuri `brand-npm` + GitHub Packages). JSR: `` `@kolektiv/themes` `` when linked. Until the first Maven publish lands, Compose consumers can still use `includeBuild` @@ -49,10 +49,10 @@ Set `` (etc.) and every daisyUI component fo ## Compose -Colour-only palettes as `dev.kolektiv.themes:themes` (version `0.0.1-SNAPSHOT.3`): +Colour-only palettes as `computer.kolektiv.themes:themes` (version `0.0.1-SNAPSHOT.3`): ```kotlin -implementation("dev.kolektiv.themes:themes:0.0.1-SNAPSHOT.3") +implementation("computer.kolektiv.themes:themes:0.0.1-SNAPSHOT.3") KolektivTheme(KolektivThemes.kolektivDark) { val colors = KolektivTheme.colors @@ -65,7 +65,7 @@ Until Maven is published to `repo.yuri.capital`, consume via `includeBuild`: // settings.gradle.kts includeBuild("../themes") { dependencySubstitution { - substitute(module("dev.kolektiv.themes:themes")) + substitute(module("computer.kolektiv.themes:themes")) .using(project(":themes")) } } diff --git a/build.gradle.kts b/build.gradle.kts index 4d53baa..14648c9 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -5,6 +5,6 @@ plugins { } allprojects { - group = "dev.kolektiv.themes" + group = "computer.kolektiv.themes" version = "0.0.1-SNAPSHOT.3" } diff --git a/docs/CI_DUAL_PUBLISH.md b/docs/CI_DUAL_PUBLISH.md index 7ef7a91..794ffb1 100644 --- a/docs/CI_DUAL_PUBLISH.md +++ b/docs/CI_DUAL_PUBLISH.md @@ -1,6 +1,25 @@ -# CI dual-publish (GH Packages npm + JSR) +# Dual-publish (GH Packages + Yuri + JSR) -Token used to open this PR cannot edit `.github/workflows/*` (missing `workflows` scope). Apply manually: +Org epic: [KolektivComputer/.github#2](https://github.com/KolektivComputer/.github/issues/2) +Spine: [gradle-conventions#1](https://github.com/KolektivComputer/gradle-conventions/pull/1) → plugin `computer.kolektiv.publishing` + +## Maven +- GroupId: `computer.kolektiv.themes` (org family `computer.kolektiv.*`) +- Dual repositories: GitHub Packages `https://maven.pkg.github.com/KolektivComputer/themes` **and** Yuri Capital (`maven-releases` / `maven-snapshots`) when credentials are present +- Prefer `id("computer.kolektiv.publishing")` once the conventions plugin is published; until then repos are inlined to match that plugin + +## npm +- Scope **`@kolektiv/...` only** — do not invent a second JS scope +- Dual: existing Yuri Capital npm (where used) + `https://npm.pkg.github.com` with `@kolektiv:registry=…` +- Auth: `NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }}` with `permissions.packages: write` + +## JSR +- Scope `@kolektiv` (owned) +- Actions: OIDC only — `permissions.id-token: write` — **no org `JSR_TOKEN`** +- Mey: link each package on jsr.io for GitHub Actions trusted publishing +- Not a substitute for npm publish + +## Workflow paste (token may lack `workflows` scope) ```yaml permissions: @@ -9,13 +28,25 @@ permissions: id-token: write # JSR OIDC ``` -npm → GitHub Packages: -- `registry-url: https://npm.pkg.github.com` -- `scope: "@kolektiv"` -- `NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }}` - -Keep existing Yuri Capital npm publish as dual. +Maven job env: +```yaml +GITHUB_ACTOR: ${{ github.actor }} +GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} +# optional Yuri dual: +# YURI_CAPITAL_REPO_USERNAME / YURI_CAPITAL_REPO_PASSWORD (org secrets) +``` -JSR: claim `@kolektiv` on jsr.io, link package for OIDC, then `npx jsr publish`. +npm → GitHub Packages: +```yaml +- uses: actions/setup-node@v4 + with: + registry-url: https://npm.pkg.github.com + scope: "@kolektiv" +env: + NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }} +``` -Epic: https://github.com/KolektivComputer/.github/issues/2 +JSR: +```yaml +- run: npx jsr publish +``` diff --git a/docs/PUBLISHING.md b/docs/PUBLISHING.md index f04a5ef..1dd12d8 100644 --- a/docs/PUBLISHING.md +++ b/docs/PUBLISHING.md @@ -1,13 +1,15 @@ # Publishing (themes) +Org spine: [gradle-conventions](https://github.com/KolektivComputer/gradle-conventions) (`computer.kolektiv.publishing`). + ## Targets | Ecosystem | Yuri Capital | GitHub Packages | JSR | | --- | --- | --- | --- | -| Maven (`dev.kolektiv.themes:themes`) | `maven-releases` / `maven-snapshots` | `maven.pkg.github.com/KolektivComputer/themes` | — | +| Maven (`computer.kolektiv.themes:themes`) | `maven-releases` / `maven-snapshots` | `maven.pkg.github.com/KolektivComputer/themes` | — | | TypeScript / npm (`` `@kolektiv/themes` ``) | `brand-npm` | `npm.pkg.github.com` | `` `@kolektiv/themes` `` via OIDC | -GroupId note: Compose module uses `dev.kolektiv.themes` to match current PR coordinates; org epic prefers `computer.kolektiv.*` — migrate in a follow-up. +GroupId: Compose / Maven use `computer.kolektiv.themes` (org family `computer.kolektiv.*`). npm/JSR stay `@kolektiv/themes`. ## Workflows