-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathjustfile
More file actions
68 lines (55 loc) · 1.84 KB
/
Copy pathjustfile
File metadata and controls
68 lines (55 loc) · 1.84 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
# gitlab-warden task runner. Run `just` to list recipes.
set quiet
default:
@just --list
# Type-check (no emit)
tsc:
npx tsc --noEmit
# Run the test suite (optionally: just test <pattern>)
test *args:
npx vitest run {{args}}
# Build the CLI bundle (dist/cli.js)
build:
npm run build
# Dogfood: audit our own config with chant (CI's `dogfood-audit` job)
audit:
npx chant audit . --fail-on merge-worthy
# Install dependencies (clean, lockfile-faithful)
install:
npm ci
# Everything CI runs
check: tsc test
# Start the hermetic e2e stack (compose up + mint token); GitLab CE is slow.
# The exports land on stdout, so: eval "$(just e2e-up)"
e2e-up:
bash e2e/bootstrap.sh
# Stop the e2e stack and discard its state (compose down -v)
e2e-down:
docker compose -f e2e/docker-compose.yml down -v
# Build the docs site locally (requires `pip install mkdocs-material`)
docs:
npm run lint:prose
./mkdocs-stage.sh && mkdocs build --strict
# Preview the docs site locally
docs-serve:
./mkdocs-stage.sh && mkdocs serve
# Bump version, tag, and push to trigger the npm publish workflow
release bump="patch":
#!/usr/bin/env bash
set -euo pipefail
current=$(node -e "process.stdout.write(require('./package.json').version)")
IFS='.' read -r major minor patch <<< "$current"
case "{{bump}}" in
major) major=$((major + 1)); minor=0; patch=0 ;;
minor) minor=$((minor + 1)); patch=0 ;;
patch) patch=$((patch + 1)) ;;
*) echo "Usage: just release [major|minor|patch]"; exit 1 ;;
esac
next="$major.$minor.$patch"
echo "Bumping $current → $next"
npm version "$next" --no-git-tag-version
git add package.json package-lock.json
git commit -m "v$next"
git tag "v$next"
git push origin main "v$next"
echo "Released v$next — publish workflow triggered (tag pattern v*)"