@zebradil/docs-kit 0.11.1 → 0.12.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/README.md +4 -3
  2. package/package.json +2 -2
package/README.md CHANGED
@@ -44,7 +44,7 @@ The repository root is the npm package [`@zebradil/docs-kit`](https://www.npmjs.
44
44
  <!-- x-release-please-start-version -->
45
45
  ```jsonc
46
46
  // package.json
47
- { "private": true, "type": "module", "dependencies": { "@zebradil/docs-kit": "0.11.1" } }
47
+ { "private": true, "type": "module", "dependencies": { "@zebradil/docs-kit": "0.12.0" } }
48
48
  ```
49
49
  <!-- x-release-please-end -->
50
50
 
@@ -97,7 +97,7 @@ on:
97
97
  permissions: { contents: read, pages: write, id-token: write }
98
98
  jobs:
99
99
  docs:
100
- uses: Zebradil/docs-kit/.github/workflows/docs.yml@v0.11.1
100
+ uses: Zebradil/docs-kit/.github/workflows/docs.yml@v0.12.0
101
101
  ```
102
102
  <!-- x-release-please-end -->
103
103
 
@@ -105,7 +105,7 @@ Keep `uses:` on its own indented line: Renovate's github-actions manager finds r
105
105
 
106
106
  The caller must grant `pages: write` and `id-token: write`: a called workflow can only narrow the caller's token permissions, never widen them, and the deploy job needs both.
107
107
 
108
- On every run it installs `docs/` with `npm ci`, builds the CLI with `reference.cli.build` (run from the repository root) when set, regenerates the CLI reference with `help2md` into `docs/src/content/docs/reference/cli`, and builds the site with `npx astro build` (which validates `site.yaml`). On a pull request it fails if the regenerated reference differs from the committed one and prints the diff. On a push to the default branch it builds the release versions when `versions:` is set and deploys `docs/dist` to GitHub Pages. A tag pushed with a workflow's `GITHUB_TOKEN` triggers no other workflow, so a new release shows up with the next deploy; to publish it at once, run the docs workflow on the default branch after the tag exists, for example from the release job.
108
+ On every run it installs `docs/` with `npm ci`, runs `prebuild` (from the repository root) when set, builds the CLI with `reference.cli.build` (run from the repository root) when set, regenerates the CLI reference with `help2md` into `docs/src/content/docs/reference/cli`, and builds the site with `npx astro build` (which validates `site.yaml`). On a pull request it fails if the regenerated reference differs from the committed one and prints the diff. On a push to the default branch it builds the release versions when `versions:` is set and deploys `docs/dist` to GitHub Pages. A tag pushed with a workflow's `GITHUB_TOKEN` triggers no other workflow, so a new release shows up with the next deploy; to publish it at once, run the docs workflow on the default branch after the tag exists, for example from the release job.
109
109
 
110
110
  Inputs, all optional:
111
111
 
@@ -114,6 +114,7 @@ Inputs, all optional:
114
114
  | `directory` | `docs` | Docs directory, relative to the repository root. |
115
115
  | `nix` | `false` | Install Nix first, for `build: nix build` and friends. |
116
116
  | `deploy` | `true` | Deploy on pushes to the default branch. |
117
+ | `prebuild` | | Shell command run from the repository root before the CLI build, for generated files the site serves, such as `docs/public/demo/`. Release versions keep the `public/` of their tag, so they do not get these files. |
117
118
 
118
119
  Runs on `ubuntu-latest`, which already has Rust (cargo, rustup) and Go (default version linked into `/usr/bin`; a newer `go` line in `go.mod` makes Go download that toolchain itself); see the [runner image tool list](https://github.com/actions/runner-images/blob/main/images/ubuntu/Ubuntu2404-Readme.md).
119
120
 
package/package.json CHANGED
@@ -29,7 +29,7 @@
29
29
  "validate": "node schema/validate.mjs"
30
30
  },
31
31
  "dependencies": {
32
- "@astrojs/starlight": "0.42.10",
32
+ "@astrojs/starlight": "0.42.11",
33
33
  "@fontsource-variable/fraunces": "5.3.0",
34
34
  "@fontsource-variable/instrument-sans": "5.3.0",
35
35
  "@fontsource-variable/jetbrains-mono": "5.3.0",
@@ -40,5 +40,5 @@
40
40
  "astro": "7.4.11",
41
41
  "yaml": "2.9.1"
42
42
  },
43
- "version": "0.11.1"
43
+ "version": "0.12.0"
44
44
  }