Skip to content

Commit 6c64439

Browse files
committed
updates for caching architecture and docs
1 parent cf19e6e commit 6c64439

28 files changed

Lines changed: 1413 additions & 4726 deletions

.github/workflows/ci.yml

Lines changed: 16 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -23,17 +23,27 @@ jobs:
2323
with:
2424
node-version: "20"
2525

26+
- name: Install pnpm
27+
uses: pnpm/action-setup@v4
28+
with:
29+
version: 10
30+
2631
- name: Install rustfmt and clippy
2732
run: |
2833
rustup component add rustfmt clippy
2934
30-
- name: Cache npm dependencies
35+
- name: Get pnpm store directory
36+
id: pnpm-cache
37+
run: |
38+
echo "STORE_PATH=$(pnpm store path)" >> "$GITHUB_OUTPUT"
39+
40+
- name: Cache pnpm dependencies
3141
uses: actions/cache@v4
3242
with:
33-
path: ~/.npm
34-
key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }}
43+
path: ${{ steps.pnpm-cache.outputs.STORE_PATH }}
44+
key: ${{ runner.os }}-pnpm-${{ hashFiles('**/pnpm-lock.yaml') }}
3545
restore-keys: |
36-
${{ runner.os }}-node-
46+
${{ runner.os }}-pnpm-
3747
3848
- name: Cache Nx
3949
uses: actions/cache@v4
@@ -53,8 +63,8 @@ jobs:
5363
restore-keys: |
5464
${{ runner.os }}-cargo-
5565
56-
- name: Install npm dependencies
57-
run: npm ci
66+
- name: Install pnpm dependencies
67+
run: pnpm install --frozen-lockfile
5868

5969
- name: Add node_modules/.bin to PATH
6070
run: echo "$PWD/node_modules/.bin" >> "$GITHUB_PATH"

docs/astro.config.mjs

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -53,13 +53,12 @@ export default defineConfig({
5353
items: [
5454
{ label: 'Overview', slug: 'configuration/overview' },
5555
{ label: 'Cache System', slug: 'configuration/cache' },
56+
{ label: 'Package Management', slug: 'configuration/packages' },
5657
],
5758
},
5859
{
5960
label: 'Providers',
60-
items: [
61-
{ label: 'CircleCI', slug: 'providers/circleci' },
62-
],
61+
items: [{ label: 'CircleCI', slug: 'providers/circleci' }],
6362
},
6463
{
6564
label: 'Advanced Features',
@@ -74,9 +73,7 @@ export default defineConfig({
7473
},
7574
{
7675
label: 'Reference',
77-
items: [
78-
{ label: 'Requirements', slug: 'reference/requirements' },
79-
],
76+
items: [{ label: 'Requirements', slug: 'reference/requirements' }],
8077
},
8178
],
8279
}),

docs/biome.jsonc

Lines changed: 4 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,31 +1,21 @@
11
{
22
"root": false,
3-
"$schema": "https://biomejs.dev/schemas/2.0.6/schema.json",
4-
"formatter": {
5-
"enabled": true,
6-
"formatWithErrors": true,
7-
"indentStyle": "space",
8-
"indentWidth": 2,
9-
"lineEnding": "lf",
10-
"lineWidth": 120
11-
},
3+
"$schema": "https://biomejs.dev/schemas/2.2.2/schema.json",
4+
"extends": ["ultracite"],
125
"linter": {
13-
"enabled": true,
146
"rules": {
157
"style": {
168
"useFilenamingConvention": "off",
179
"noParameterAssign": "error",
1810
"useAsConstAssertion": "error",
1911
"useDefaultParameterLast": "error",
12+
"useEnumInitializers": "error",
2013
"useSelfClosingElements": "error",
2114
"useSingleVarDeclarator": "error",
2215
"noUnusedTemplateLiteral": "error",
16+
"useNumberNamespace": "error",
2317
"noInferrableTypes": "error",
2418
"noUselessElse": "error"
25-
},
26-
"correctness": {
27-
"noUnusedVariables": "error",
28-
"noUnusedImports": "error"
2919
}
3020
}
3121
},

docs/package.json

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -8,11 +8,11 @@
88
"build": "astro build",
99
"preview": "astro preview",
1010
"astro": "astro",
11-
"lint": "biome lint .",
12-
"lint:fix": "biome check --write .",
13-
"format": "prettier --write '**/*.{md,mdx,astro}'",
14-
"format:check": "prettier --check '**/*.{md,mdx,astro}'",
15-
"check": "biome check . && pnpm format:check"
11+
"lint": "pnpm exec biome lint .",
12+
"lint:fix": "pnpm exec biome check --write .",
13+
"format": "pnpm exec prettier --write '**/*.{md,mdx,astro}'",
14+
"format:check": "pnpm exec prettier --check '**/*.{md,mdx,astro}'",
15+
"check": "pnpm exec biome check . && pnpm format:check"
1616
},
1717
"dependencies": {
1818
"@astrojs/starlight": "^0.35.2",

docs/src/content.config.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
import { defineCollection } from "astro:content";
2-
import { docsLoader } from "@astrojs/starlight/loaders";
3-
import { docsSchema } from "@astrojs/starlight/schema";
1+
import { defineCollection } from 'astro:content';
2+
import { docsLoader } from '@astrojs/starlight/loaders';
3+
import { docsSchema } from '@astrojs/starlight/schema';
44

55
export const collections = {
66
docs: defineCollection({ loader: docsLoader(), schema: docsSchema() }),

0 commit comments

Comments
 (0)