@sablier/devkit 1.12.1 → 1.13.1

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.
package/README.md CHANGED
@@ -26,7 +26,7 @@ Extend the base Biome configuration in your `biome.jsonc`:
26
26
 
27
27
  ```jsonc
28
28
  {
29
- "$schema": "https://biomejs.dev/schemas/2.0.6/schema.json",
29
+ "$schema": "https://biomejs.dev/schemas/latest/schema.json",
30
30
  "extends": ["@sablier/devkit/biome"],
31
31
  }
32
32
  ```
@@ -116,25 +116,31 @@ Available modules:
116
116
  | Module | Description |
117
117
  | --------------- | ------------------------------- |
118
118
  | `base.just` | Common development recipes |
119
- | `npm.just` | NPM package management |
119
+ | `csv.just` | CSV/TSV validation with qsv |
120
120
  | `evm.just` | EVM/Foundry tooling |
121
- | `tsv.just` | TypeScript validation |
121
+ | `npm.just` | NPM package management |
122
122
  | `settings.just` | Just settings and configuration |
123
+ | `vercel.just` | Vercel build and deploy |
123
124
 
124
125
  ## ⚙️ Available Configs
125
126
 
126
- | Tool | Config File/Directory |
127
- | --------------- | ---------------------------------------- |
128
- | 🔍 Biome | [`biome/`](./biome/) |
129
- | 📝 EditorConfig | [`.editorconfig`](./.editorconfig) |
130
- | 🛠 Just | [`just/`](./just/) |
131
- | Prettier | [`.prettierrc.json`](./.prettierrc.json) |
132
- | 📦 TSConfig | [`tsconfig/`](./tsconfig/) |
133
- | 🧪 Vitest | [`vitest/`](./vitest/) |
127
+ | Tool | Config File/Directory |
128
+ | ----------- | ---------------------------------------- |
129
+ | 🔍 Biome | [`biome/`](./biome/) |
130
+ | 🛠 Just | [`just/`](./just/) |
131
+ | Prettier | [`.prettierrc.json`](./.prettierrc.json) |
132
+ | 📦 TSConfig | [`tsconfig/`](./tsconfig/) |
133
+ | 🧪 Vitest | [`vitest/`](./vitest/) |
134
+ | 💻 VSCode | [`vscode/`](./vscode/) |
134
135
 
135
136
  ## 🐈‍⬛ GitHub Actions
136
137
 
137
- The [setup](./actions/setup/) action installs requisite dependencies in GitHub CI workflows.
138
+ Reusable composite actions for GitHub CI workflows.
139
+
140
+ | Action | Description |
141
+ | --------------------------------------------- | ------------------------------------------ |
142
+ | [`actions/setup`](./actions/setup/) | Install dependencies (Node.js, Just, etc.) |
143
+ | [`actions/node-cache`](./actions/node-cache/) | Cache Node.js dependencies |
138
144
 
139
145
  ```yaml
140
146
  - uses: sablier-labs/devkit/actions/setup@main
@@ -150,4 +156,4 @@ Contributions are welcome! Please feel free to submit a Pull Request.
150
156
 
151
157
  ## 📄 License
152
158
 
153
- This project is licensed under MIT.
159
+ This project is licensed under MIT — see the [LICENSE](LICENSE.md) file for details.
package/biome/ui.jsonc CHANGED
@@ -37,6 +37,9 @@
37
37
  "noSvgWithoutTitle": "off",
38
38
  "useKeyWithClickEvents": "off"
39
39
  },
40
+ "correctness": {
41
+ "useExhaustiveDependencies": "off" // doesn't work with React Compiler: https://github.com/biomejs/biome/issues/5293
42
+ },
40
43
  "nursery": {
41
44
  // Sort Tailwind CSS classes alphabetically
42
45
  // See https://github.com/biomejs/biome/issues/1274#issuecomment-3490774696
package/just/base.just CHANGED
@@ -42,7 +42,7 @@ _clean +globs:
42
42
  # Install mdformat with plugins
43
43
  [no-cd]
44
44
  @install-mdformat:
45
- uv tool install mdformat \
45
+ uv tool install mdformat --python 3.14 \
46
46
  --with mdformat-frontmatter \
47
47
  --with mdformat-gfm
48
48
  alias im := install-mdformat
@@ -0,0 +1,109 @@
1
+ import "./settings.just"
2
+
3
+ # ---------------------------------------------------------------------------- #
4
+ # DEPENDENCIES #
5
+ # ---------------------------------------------------------------------------- #
6
+
7
+ # Ni: https://github.com/antfu-collective/ni
8
+ na := require("na")
9
+
10
+ # ---------------------------------------------------------------------------- #
11
+ # CONSTANTS #
12
+ # ---------------------------------------------------------------------------- #
13
+
14
+ # Consumer MUST override with a JSON map of app name → Vercel project ID.
15
+ # Example: '{"portal": "prj_xxx", "landing": "prj_yyy"}'
16
+ VERCEL_PROJECT_IDS := '{}'
17
+
18
+ # ---------------------------------------------------------------------------- #
19
+ # RECIPES #
20
+ # ---------------------------------------------------------------------------- #
21
+
22
+ # Build website for Vercel deployment
23
+ [arg("app", long)]
24
+ [arg("env", long)]
25
+ [group("vercel")]
26
+ build app env="staging":
27
+ @just _vercel-build "{{ app }}" "{{ env }}"
28
+ alias vb := build
29
+
30
+ # Deploy website to Vercel
31
+ [arg("app", long)]
32
+ [arg("env", long)]
33
+ [arg("skip_build", long="skip-build", value="true")]
34
+ [confirm("Are you sure you want to deploy? [y/N]")]
35
+ [group("vercel")]
36
+ deploy app env="staging" skip_build="false":
37
+ @just _vercel-deploy "{{ app }}" "{{ env }}" "{{ skip_build }}"
38
+ alias vd := deploy
39
+
40
+ # ---------------------------------------------------------------------------- #
41
+ # PRIVATE HELPERS #
42
+ # ---------------------------------------------------------------------------- #
43
+
44
+ # Core build: vercel pull + vercel build
45
+ [private, script("python3")]
46
+ _vercel-build app env:
47
+ import json, os, subprocess, sys
48
+
49
+ def run(*cmd):
50
+ result = subprocess.run(cmd)
51
+ if result.returncode != 0:
52
+ sys.exit(result.returncode)
53
+
54
+ # Workaround for https://github.com/vercel/vercel/issues/14666
55
+ os.environ["VERCEL_TARGET_ENV"] = "{{ env }}"
56
+ os.environ["NEXT_PUBLIC_VERCEL_TARGET_ENV"] = "{{ env }}"
57
+
58
+ # Resolve project ID from app name
59
+ project_ids = json.loads('{{ VERCEL_PROJECT_IDS }}')
60
+ app = "{{ app }}"
61
+ if app not in project_ids:
62
+ print(f"Error: unknown app '{app}'. Known apps: {', '.join(project_ids) or '(none)'}", file=sys.stderr)
63
+ sys.exit(1)
64
+ os.environ["VERCEL_PROJECT_ID"] = project_ids[app]
65
+
66
+ token = os.environ.get("VERCEL_TOKEN", "")
67
+ if not token:
68
+ print("Error: VERCEL_TOKEN is not set.", file=sys.stderr)
69
+ sys.exit(1)
70
+
71
+ # Pull the environment from the Vercel project
72
+ run("na", "vercel", "pull", "--environment={{ env }}", f"--token={token}", "--yes")
73
+
74
+ # Build the project
75
+ run("na", "vercel", "build", "--target={{ env }}", f"--token={token}")
76
+
77
+ # Core deploy: optionally build, then deploy prebuilt artifacts
78
+ [private, script("python3")]
79
+ _vercel-deploy app env skip_build="false":
80
+ import json, os, subprocess, sys
81
+
82
+ def run(*cmd):
83
+ result = subprocess.run(cmd)
84
+ if result.returncode != 0:
85
+ sys.exit(result.returncode)
86
+
87
+ # Build the project if not skipped (calls the PUBLIC recipe so consumer overrides apply)
88
+ if "{{ skip_build }}" != "true":
89
+ run("just", "build", "--app={{ app }}", "--env={{ env }}")
90
+
91
+ # Workaround for https://github.com/vercel/vercel/issues/14666
92
+ os.environ["VERCEL_TARGET_ENV"] = "{{ env }}"
93
+ os.environ["NEXT_PUBLIC_VERCEL_TARGET_ENV"] = "{{ env }}"
94
+
95
+ # Resolve project ID from app name
96
+ project_ids = json.loads('{{ VERCEL_PROJECT_IDS }}')
97
+ app = "{{ app }}"
98
+ if app not in project_ids:
99
+ print(f"Error: unknown app '{app}'. Known apps: {', '.join(project_ids) or '(none)'}", file=sys.stderr)
100
+ sys.exit(1)
101
+ os.environ["VERCEL_PROJECT_ID"] = project_ids[app]
102
+
103
+ token = os.environ.get("VERCEL_TOKEN", "")
104
+ if not token:
105
+ print("Error: VERCEL_TOKEN is not set.", file=sys.stderr)
106
+ sys.exit(1)
107
+
108
+ # Deploy the project to Vercel
109
+ run("na", "vercel", "deploy", "--prebuilt", "--target={{ env }}", f"--token={token}")
package/package.json CHANGED
@@ -3,7 +3,7 @@
3
3
  "description": "Configuration files and reusable scripts for Sablier repositories",
4
4
  "license": "MIT",
5
5
  "type": "module",
6
- "version": "1.12.1",
6
+ "version": "1.13.1",
7
7
  "author": {
8
8
  "name": "Sablier Labs Ltd",
9
9
  "url": "https://sablier.com"