@getvitops/create 0.5.0 → 0.7.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.
- package/CHANGELOG.md +44 -5
- package/README.md +7 -0
- package/package.json +18 -2
- package/templates/emdash/.agents/skills/setup/SKILL.md +61 -0
- package/templates/emdash/.env +1 -0
- package/templates/emdash/.github/workflows/ci.yml +12 -0
- package/templates/emdash/.github/workflows/deploy-dev.yml +17 -19
- package/templates/emdash/.github/workflows/deploy-prod.yml +17 -21
- package/templates/emdash/.github/workflows/promote.yml +8 -36
- package/templates/emdash/.mcp.json +4 -0
- package/templates/emdash/.nvmrc +1 -0
- package/templates/emdash/AGENTS.md +23 -11
- package/templates/emdash/README.md +44 -42
- package/templates/emdash/SETUP.html +526 -0
- package/templates/emdash/_gitignore +3 -0
- package/templates/emdash/astro.config.mjs +7 -1
- package/templates/emdash/package.json +6 -4
- package/templates/emdash/seed/seed.json +1 -1
- package/templates/emdash/site.json +228 -0
- package/templates/emdash/src/assets/placeholder/wireframe-400x400.png +0 -0
- package/templates/emdash/src/assets/placeholder/wireframe-400x400.svg +1 -0
- package/templates/emdash/src/assets/placeholder/wireframe-400x600.png +0 -0
- package/templates/emdash/src/assets/placeholder/wireframe-400x600.svg +1 -0
- package/templates/emdash/src/assets/placeholder/wireframe-600x400.png +0 -0
- package/templates/emdash/src/assets/placeholder/wireframe-600x400.svg +1 -0
- package/templates/emdash/vite.config.ts +1 -1
- package/templates/emdash/wrangler.jsonc +8 -3
- package/templates/static/.agents/skills/setup/SKILL.md +61 -0
- package/templates/static/.env +1 -0
- package/templates/static/.github/workflows/ci.yml +12 -0
- package/templates/static/.github/workflows/deploy-dev.yml +33 -0
- package/templates/static/.github/workflows/deploy-prod.yml +29 -0
- package/templates/static/.github/workflows/promote.yml +16 -0
- package/templates/static/.nvmrc +1 -0
- package/templates/static/AGENTS.md +64 -0
- package/templates/static/README.md +80 -0
- package/templates/static/SETUP.html +526 -0
- package/templates/static/_gitignore +27 -0
- package/templates/static/astro.config.mjs +23 -0
- package/templates/{emdash → static}/design-system.json +1 -1
- package/templates/static/package.json +41 -0
- package/templates/static/scripts/dev-wrangler-config.mjs +28 -0
- package/templates/static/site.json +228 -0
- package/templates/static/src/assets/placeholder/wireframe-400x400.png +0 -0
- package/templates/static/src/assets/placeholder/wireframe-400x400.svg +1 -0
- package/templates/static/src/assets/placeholder/wireframe-400x600.png +0 -0
- package/templates/static/src/assets/placeholder/wireframe-400x600.svg +1 -0
- package/templates/static/src/assets/placeholder/wireframe-600x400.png +0 -0
- package/templates/static/src/assets/placeholder/wireframe-600x400.svg +1 -0
- package/templates/static/src/layouts/Layout.astro +26 -0
- package/templates/static/src/pages/404.astro +11 -0
- package/templates/static/src/pages/index.astro +13 -0
- package/templates/static/tsconfig.json +5 -0
- package/templates/static/wrangler.jsonc +22 -0
- package/templates/emdash/scripts/init-github.mjs +0 -102
- package/templates/emdash/scripts/init-hosting.mjs +0 -150
|
@@ -0,0 +1,228 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "./node_modules/@getvitops/generator/config.schema.json",
|
|
3
|
+
"designSystem": {
|
|
4
|
+
"themes": {
|
|
5
|
+
"default": {
|
|
6
|
+
"$schema": "./node_modules/@getvitops/generator/schema.json",
|
|
7
|
+
"colors": {
|
|
8
|
+
"palette": {
|
|
9
|
+
"brand": {
|
|
10
|
+
"seed": "#2e9b73"
|
|
11
|
+
},
|
|
12
|
+
"ink": {
|
|
13
|
+
"seed": "#3f4a5c"
|
|
14
|
+
},
|
|
15
|
+
"sky": {
|
|
16
|
+
"seed": "#2f7bc0"
|
|
17
|
+
},
|
|
18
|
+
"sun": {
|
|
19
|
+
"seed": "#d08a1f"
|
|
20
|
+
},
|
|
21
|
+
"rose": {
|
|
22
|
+
"seed": "#c74a42"
|
|
23
|
+
}
|
|
24
|
+
},
|
|
25
|
+
"roles": {
|
|
26
|
+
"neutral": "ink",
|
|
27
|
+
"surface": "ink",
|
|
28
|
+
"ui-primary": "brand",
|
|
29
|
+
"brand-primary": "brand",
|
|
30
|
+
"info": "sky",
|
|
31
|
+
"success": "brand",
|
|
32
|
+
"warning": "sun",
|
|
33
|
+
"danger": "rose"
|
|
34
|
+
},
|
|
35
|
+
"utilities": ["bg", "text", "icon", "border"]
|
|
36
|
+
},
|
|
37
|
+
"shadows": {
|
|
38
|
+
"sm": "0 1px 2px rgb(0 0 0 / 0.08)",
|
|
39
|
+
"md": "0 4px 6px rgb(0 0 0 / 0.12)",
|
|
40
|
+
"lg": "0 10px 15px rgb(0 0 0 / 0.18)"
|
|
41
|
+
},
|
|
42
|
+
"fonts": {
|
|
43
|
+
"display": "system-ui, -apple-system, \"Segoe UI\", sans-serif",
|
|
44
|
+
"sans": "system-ui, -apple-system, \"Segoe UI\", Roboto, sans-serif",
|
|
45
|
+
"mono": "ui-monospace, \"SF Mono\", Menlo, monospace"
|
|
46
|
+
},
|
|
47
|
+
"typeScale": {
|
|
48
|
+
"base": "1rem",
|
|
49
|
+
"names": ["2xs", "xs", "s", "m", "l", "xl", "2xl", "3xl"],
|
|
50
|
+
"baseStep": 4,
|
|
51
|
+
"baseline": "m",
|
|
52
|
+
"ratio": 1.2,
|
|
53
|
+
"fluid": {
|
|
54
|
+
"minVw": "22.5rem",
|
|
55
|
+
"maxVw": "80rem",
|
|
56
|
+
"minRatio": 1.12
|
|
57
|
+
}
|
|
58
|
+
},
|
|
59
|
+
"spaceScale": {
|
|
60
|
+
"base": "1rem",
|
|
61
|
+
"names": ["2xs", "xs", "s", "m", "l", "xl", "2xl", "3xl"],
|
|
62
|
+
"baseStep": 4,
|
|
63
|
+
"baseline": "m",
|
|
64
|
+
"ratio": 1.25,
|
|
65
|
+
"fluid": {
|
|
66
|
+
"minVw": "22.5rem",
|
|
67
|
+
"maxVw": "80rem",
|
|
68
|
+
"minRatio": 1.2
|
|
69
|
+
}
|
|
70
|
+
},
|
|
71
|
+
"patterns": {
|
|
72
|
+
"defaults": {
|
|
73
|
+
"ds": "none",
|
|
74
|
+
"b": "1px solid var(--color-bg-surface-x-muted)",
|
|
75
|
+
"br": "0.375rem",
|
|
76
|
+
"p": "1rem",
|
|
77
|
+
"fs": "1rem"
|
|
78
|
+
},
|
|
79
|
+
"radii": {
|
|
80
|
+
"circle": "50%"
|
|
81
|
+
},
|
|
82
|
+
"groups": {
|
|
83
|
+
"control": {
|
|
84
|
+
"ds": "var(--ds-default)",
|
|
85
|
+
"b": "var(--b-default)",
|
|
86
|
+
"br": "var(--br-default)",
|
|
87
|
+
"p": "0.5em 1em",
|
|
88
|
+
"fs": "var(--fs-default)"
|
|
89
|
+
},
|
|
90
|
+
"panel": {
|
|
91
|
+
"ds": "var(--shadow-md)",
|
|
92
|
+
"b": "var(--b-default)",
|
|
93
|
+
"br": "0.5rem",
|
|
94
|
+
"p": "1rem",
|
|
95
|
+
"fs": "var(--fs-default)"
|
|
96
|
+
}
|
|
97
|
+
},
|
|
98
|
+
"z": {
|
|
99
|
+
"raised": 1,
|
|
100
|
+
"sticky": 100,
|
|
101
|
+
"overlay": 200,
|
|
102
|
+
"top": 1000
|
|
103
|
+
},
|
|
104
|
+
"items": {
|
|
105
|
+
"button": {
|
|
106
|
+
"group": "control",
|
|
107
|
+
"element": "button",
|
|
108
|
+
"default_role": "brand-primary",
|
|
109
|
+
"base": {
|
|
110
|
+
"padding": "0.6em 1.2em",
|
|
111
|
+
"border-radius": "var(--br-control, 0.25rem)",
|
|
112
|
+
"border": "none",
|
|
113
|
+
"font-weight": "600",
|
|
114
|
+
"color": "#fff",
|
|
115
|
+
"cursor": "pointer",
|
|
116
|
+
"box-shadow": "var(--shadow-sm)"
|
|
117
|
+
},
|
|
118
|
+
"states": {
|
|
119
|
+
"hover": {
|
|
120
|
+
"step": 1
|
|
121
|
+
},
|
|
122
|
+
"active": {
|
|
123
|
+
"scale": 0.97
|
|
124
|
+
},
|
|
125
|
+
"focus-visible": {
|
|
126
|
+
"ring": true
|
|
127
|
+
}
|
|
128
|
+
},
|
|
129
|
+
"roles": []
|
|
130
|
+
},
|
|
131
|
+
"card": {
|
|
132
|
+
"group": "panel",
|
|
133
|
+
"class": "card",
|
|
134
|
+
"base": {
|
|
135
|
+
"border-radius": "var(--br-card-group)",
|
|
136
|
+
"padding": "1.5rem",
|
|
137
|
+
"background": "var(--color-bg-surface-muted)",
|
|
138
|
+
"border": "var(--b-card-group)",
|
|
139
|
+
"box-shadow": "var(--ds-card-group)"
|
|
140
|
+
},
|
|
141
|
+
"states": {},
|
|
142
|
+
"roles": []
|
|
143
|
+
}
|
|
144
|
+
}
|
|
145
|
+
},
|
|
146
|
+
"typography": {
|
|
147
|
+
"families": {
|
|
148
|
+
"display": "var(--font-display)",
|
|
149
|
+
"sans": "var(--font-sans)",
|
|
150
|
+
"code": "var(--font-mono, ui-monospace, monospace)"
|
|
151
|
+
},
|
|
152
|
+
"roles": {
|
|
153
|
+
"display": {
|
|
154
|
+
"family": "display",
|
|
155
|
+
"size": "var(--text-3xl)",
|
|
156
|
+
"weight": 700,
|
|
157
|
+
"line-height": "1.05",
|
|
158
|
+
"tracking": "-0.03em"
|
|
159
|
+
},
|
|
160
|
+
"heading": {
|
|
161
|
+
"family": "display",
|
|
162
|
+
"size": "var(--text-xl)",
|
|
163
|
+
"weight": 600,
|
|
164
|
+
"line-height": "1.3"
|
|
165
|
+
},
|
|
166
|
+
"body": {
|
|
167
|
+
"family": "sans",
|
|
168
|
+
"size": "var(--text-m)",
|
|
169
|
+
"weight": 400,
|
|
170
|
+
"line-height": "1.55"
|
|
171
|
+
}
|
|
172
|
+
},
|
|
173
|
+
"headings": {
|
|
174
|
+
"h1": "display",
|
|
175
|
+
"h2": "heading",
|
|
176
|
+
"h3": "heading"
|
|
177
|
+
}
|
|
178
|
+
},
|
|
179
|
+
"animations": {
|
|
180
|
+
"effects": {
|
|
181
|
+
"fade-in": {
|
|
182
|
+
"kf": "composite",
|
|
183
|
+
"vars": {
|
|
184
|
+
"opacity-from": 0
|
|
185
|
+
}
|
|
186
|
+
},
|
|
187
|
+
"slide-up": {
|
|
188
|
+
"kf": "composite",
|
|
189
|
+
"vars": {
|
|
190
|
+
"translate-y-from": "var(--slide-distance, 2rem)"
|
|
191
|
+
}
|
|
192
|
+
}
|
|
193
|
+
},
|
|
194
|
+
"journeys": {
|
|
195
|
+
"base": {
|
|
196
|
+
"fade": {
|
|
197
|
+
"opacity-from": 0
|
|
198
|
+
},
|
|
199
|
+
"slide": {}
|
|
200
|
+
},
|
|
201
|
+
"compose": [["fade"], ["slide"], ["fade", "slide"]]
|
|
202
|
+
}
|
|
203
|
+
}
|
|
204
|
+
}
|
|
205
|
+
},
|
|
206
|
+
"defaultColorScheme": "light"
|
|
207
|
+
},
|
|
208
|
+
"organization": {
|
|
209
|
+
"name": "My Static Site"
|
|
210
|
+
},
|
|
211
|
+
"site": {
|
|
212
|
+
"defaultLocale": "en",
|
|
213
|
+
"locales": {
|
|
214
|
+
"en": {
|
|
215
|
+
"name": "English"
|
|
216
|
+
}
|
|
217
|
+
},
|
|
218
|
+
"environments": {
|
|
219
|
+
"production": {
|
|
220
|
+
"url": "https://my-static-site.example.com"
|
|
221
|
+
},
|
|
222
|
+
"dev": {
|
|
223
|
+
"url": "https://dev.my-static-site.example.com",
|
|
224
|
+
"robots": "noindex,nofollow"
|
|
225
|
+
}
|
|
226
|
+
}
|
|
227
|
+
}
|
|
228
|
+
}
|
|
Binary file
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
<svg xmlns="http://www.w3.org/2000/svg" width="400" height="400" viewBox="0 0 400 400"><rect width="100%" height="100%" fill="#DDDDDD"/><path fill="#999999" d="M87.3 204.72h11.66v-12.54q0-1.77.24-3.92zm17.36 0h4.82v3.79q0 .53-.35.91-.34.39-.98.39h-3.49v9.35h-5.7v-9.35H82.79q-.66 0-1.16-.42-.51-.41-.64-1.02l-.69-3.31 18.16-24.25h6.2zm35.59-4.72q0 5.01-1.08 8.71-1.07 3.69-2.97 6.1-1.89 2.42-4.47 3.59-2.59 1.18-5.58 1.18-3 0-5.55-1.18-2.56-1.17-4.44-3.59-1.88-2.41-2.94-6.1-1.06-3.7-1.06-8.71 0-5.03 1.06-8.72 1.06-3.68 2.94-6.09t4.44-3.59q2.55-1.18 5.55-1.18 2.99 0 5.58 1.18 2.58 1.18 4.47 3.59 1.9 2.41 2.97 6.09 1.08 3.69 1.08 8.72m-6.76 0q0-4.16-.61-6.89t-1.63-4.35q-1.02-1.61-2.35-2.26-1.32-.65-2.75-.65-1.41 0-2.72.65t-2.32 2.26q-1 1.62-1.6 4.35t-.6 6.89.6 6.89 1.6 4.35q1.01 1.61 2.32 2.26t2.72.65q1.43 0 2.75-.65 1.33-.65 2.35-2.26 1.02-1.62 1.63-4.35t.61-6.89m37.5 0q0 5.01-1.08 8.71-1.07 3.69-2.97 6.1-1.89 2.42-4.47 3.59-2.59 1.18-5.58 1.18-3 0-5.55-1.18-2.56-1.17-4.44-3.59-1.88-2.41-2.94-6.1-1.06-3.7-1.06-8.71 0-5.03 1.06-8.72 1.06-3.68 2.94-6.09t4.44-3.59q2.55-1.18 5.55-1.18 2.99 0 5.58 1.18 2.58 1.18 4.47 3.59 1.9 2.41 2.97 6.09 1.08 3.69 1.08 8.72m-6.76 0q0-4.16-.61-6.89t-1.63-4.35q-1.02-1.61-2.35-2.26-1.32-.65-2.75-.65-1.41 0-2.72.65t-2.32 2.26q-1 1.62-1.6 4.35t-.6 6.89.6 6.89 1.6 4.35q1.01 1.61 2.32 2.26t2.72.65q1.43 0 2.75-.65 1.33-.65 2.35-2.26 1.02-1.62 1.63-4.35t.61-6.89m48.84 10.39-3.47 3.42-8.99-8.99-9.06 9.04-3.47-3.42 9.06-9.09-8.64-8.64 3.45-3.44 8.64 8.64 8.58-8.59 3.5 3.45-8.61 8.61zm22.95-5.67h11.66v-12.54q0-1.77.24-3.92zm17.35 0h4.83v3.79q0 .53-.35.91-.34.39-.98.39h-3.5v9.35h-5.69v-9.35h-16.17q-.66 0-1.16-.42-.51-.41-.64-1.02l-.69-3.31 18.15-24.25h6.2zm35.59-4.72q0 5.01-1.07 8.71-1.07 3.69-2.97 6.1-1.89 2.42-4.48 3.59-2.58 1.18-5.57 1.18-3 0-5.56-1.18-2.55-1.17-4.43-3.59-1.89-2.41-2.95-6.1-1.06-3.7-1.06-8.71 0-5.03 1.06-8.72 1.06-3.68 2.95-6.09 1.88-2.41 4.43-3.59 2.56-1.18 5.56-1.18 2.99 0 5.57 1.18 2.59 1.18 4.48 3.59 1.9 2.41 2.97 6.09 1.07 3.69 1.07 8.72m-6.75 0q0-4.16-.61-6.89t-1.63-4.35q-1.02-1.61-2.35-2.26-1.32-.65-2.75-.65-1.41 0-2.72.65t-2.32 2.26q-1.01 1.62-1.6 4.35-.6 2.73-.6 6.89t.6 6.89q.59 2.73 1.6 4.35 1.01 1.61 2.32 2.26t2.72.65q1.43 0 2.75-.65 1.33-.65 2.35-2.26 1.02-1.62 1.63-4.35t.61-6.89m37.49 0q0 5.01-1.07 8.71-1.07 3.69-2.97 6.1-1.89 2.42-4.48 3.59-2.58 1.18-5.57 1.18-3 0-5.56-1.18-2.55-1.17-4.43-3.59-1.89-2.41-2.95-6.1-1.06-3.7-1.06-8.71 0-5.03 1.06-8.72 1.06-3.68 2.95-6.09 1.88-2.41 4.43-3.59 2.56-1.18 5.56-1.18 2.99 0 5.57 1.18 2.59 1.18 4.48 3.59 1.9 2.41 2.97 6.09 1.07 3.69 1.07 8.72m-6.75 0q0-4.16-.61-6.89t-1.63-4.35q-1.02-1.61-2.35-2.26-1.32-.65-2.75-.65-1.41 0-2.72.65t-2.32 2.26q-1.01 1.62-1.6 4.35-.6 2.73-.6 6.89t.6 6.89q.59 2.73 1.6 4.35 1.01 1.61 2.32 2.26t2.72.65q1.43 0 2.75-.65 1.33-.65 2.35-2.26 1.02-1.62 1.63-4.35t.61-6.89"/></svg>
|
|
Binary file
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
<svg xmlns="http://www.w3.org/2000/svg" width="400" height="600" viewBox="0 0 400 600"><rect width="100%" height="100%" fill="#DDDDDD"/><path fill="#999999" d="M87.3 304.72h11.66v-12.54q0-1.77.24-3.92zm17.36 0h4.82v3.79q0 .53-.35.91-.34.39-.98.39h-3.49v9.35h-5.7v-9.35H82.79q-.66 0-1.16-.42-.51-.41-.64-1.02l-.69-3.31 18.16-24.25h6.2zm35.59-4.72q0 5.01-1.08 8.71-1.07 3.69-2.97 6.1-1.89 2.42-4.47 3.59-2.59 1.18-5.58 1.18-3 0-5.55-1.18-2.56-1.17-4.44-3.59-1.88-2.41-2.94-6.1-1.06-3.7-1.06-8.71 0-5.03 1.06-8.72 1.06-3.68 2.94-6.09t4.44-3.59q2.55-1.18 5.55-1.18 2.99 0 5.58 1.18 2.58 1.18 4.47 3.59 1.9 2.41 2.97 6.09 1.08 3.69 1.08 8.72m-6.76 0q0-4.16-.61-6.89t-1.63-4.35q-1.02-1.61-2.35-2.26-1.32-.65-2.75-.65-1.41 0-2.72.65t-2.32 2.26q-1 1.62-1.6 4.35t-.6 6.89.6 6.89 1.6 4.35q1.01 1.61 2.32 2.26t2.72.65q1.43 0 2.75-.65 1.33-.65 2.35-2.26 1.02-1.62 1.63-4.35t.61-6.89m37.5 0q0 5.01-1.08 8.71-1.07 3.69-2.97 6.1-1.89 2.42-4.47 3.59-2.59 1.18-5.58 1.18-3 0-5.55-1.18-2.56-1.17-4.44-3.59-1.88-2.41-2.94-6.1-1.06-3.7-1.06-8.71 0-5.03 1.06-8.72 1.06-3.68 2.94-6.09t4.44-3.59q2.55-1.18 5.55-1.18 2.99 0 5.58 1.18 2.58 1.18 4.47 3.59 1.9 2.41 2.97 6.09 1.08 3.69 1.08 8.72m-6.76 0q0-4.16-.61-6.89t-1.63-4.35q-1.02-1.61-2.35-2.26-1.32-.65-2.75-.65-1.41 0-2.72.65t-2.32 2.26q-1 1.62-1.6 4.35t-.6 6.89.6 6.89 1.6 4.35q1.01 1.61 2.32 2.26t2.72.65q1.43 0 2.75-.65 1.33-.65 2.35-2.26 1.02-1.62 1.63-4.35t.61-6.89m48.84 10.39-3.47 3.42-8.99-8.99-9.06 9.04-3.47-3.42 9.06-9.09-8.64-8.64 3.45-3.44 8.64 8.64 8.58-8.59 3.5 3.45-8.61 8.61zm40.94-29.55-11.37 13.91-1.32 1.65q1.11-.56 2.4-.86 1.28-.31 2.76-.31 2.18 0 4.23.72 2.05.71 3.62 2.16 1.56 1.44 2.52 3.59.95 2.14.95 5 0 2.68-.98 5.03-.98 2.34-2.76 4.09-1.77 1.75-4.28 2.76-2.5 1-5.52 1-3.08 0-5.51-.98-2.44-.98-4.16-2.74-1.73-1.76-2.64-4.24-.92-2.48-.92-5.5 0-2.7 1.1-5.55t3.41-5.92l9.14-12.27q.48-.64 1.39-1.09.92-.45 2.11-.45zm-9.88 33.39q1.56 0 2.87-.53t2.25-1.48q.94-.96 1.47-2.24.53-1.29.53-2.8 0-1.64-.5-2.95t-1.43-2.23q-.93-.91-2.23-1.39-1.29-.48-2.86-.48-1.56 0-2.83.53-1.28.53-2.18 1.47t-1.4 2.23-.5 2.77q0 1.59.43 2.9.44 1.31 1.3 2.24t2.13 1.44q1.28.52 2.95.52M288.96 300q0 5.01-1.07 8.71-1.07 3.69-2.97 6.1-1.89 2.42-4.48 3.59-2.58 1.18-5.57 1.18-3 0-5.56-1.18-2.55-1.17-4.43-3.59-1.89-2.41-2.95-6.1-1.06-3.7-1.06-8.71 0-5.03 1.06-8.72 1.06-3.68 2.95-6.09 1.88-2.41 4.43-3.59 2.56-1.18 5.56-1.18 2.99 0 5.57 1.18 2.59 1.18 4.48 3.59 1.9 2.41 2.97 6.09 1.07 3.69 1.07 8.72m-6.75 0q0-4.16-.61-6.89t-1.63-4.35q-1.02-1.61-2.35-2.26-1.32-.65-2.75-.65-1.41 0-2.72.65t-2.32 2.26q-1.01 1.62-1.6 4.35-.6 2.73-.6 6.89t.6 6.89q.59 2.73 1.6 4.35 1.01 1.61 2.32 2.26t2.72.65q1.43 0 2.75-.65 1.33-.65 2.35-2.26 1.02-1.62 1.63-4.35t.61-6.89m37.49 0q0 5.01-1.07 8.71-1.07 3.69-2.97 6.1-1.89 2.42-4.48 3.59-2.58 1.18-5.57 1.18-3 0-5.56-1.18-2.55-1.17-4.43-3.59-1.89-2.41-2.95-6.1-1.06-3.7-1.06-8.71 0-5.03 1.06-8.72 1.06-3.68 2.95-6.09 1.88-2.41 4.43-3.59 2.56-1.18 5.56-1.18 2.99 0 5.57 1.18 2.59 1.18 4.48 3.59 1.9 2.41 2.97 6.09 1.07 3.69 1.07 8.72m-6.75 0q0-4.16-.61-6.89t-1.63-4.35q-1.02-1.61-2.35-2.26-1.32-.65-2.75-.65-1.41 0-2.72.65t-2.32 2.26q-1.01 1.62-1.6 4.35-.6 2.73-.6 6.89t.6 6.89q.59 2.73 1.6 4.35 1.01 1.61 2.32 2.26t2.72.65q1.43 0 2.75-.65 1.33-.65 2.35-2.26 1.02-1.62 1.63-4.35t.61-6.89"/></svg>
|
|
Binary file
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
<svg xmlns="http://www.w3.org/2000/svg" width="600" height="400" viewBox="0 0 600 400"><rect width="100%" height="100%" fill="#DDDDDD"/><path fill="#999999" d="m155.52 171.08-17.16 21-2 2.48q1.68-.84 3.62-1.3t4.18-.46q3.28 0 6.38 1.08t5.46 3.26 3.8 5.42 1.44 7.56q0 4.04-1.48 7.58t-4.16 6.18-6.46 4.16-8.34 1.52q-4.64 0-8.32-1.48t-6.28-4.14-3.98-6.4-1.38-8.3q0-4.08 1.66-8.38t5.14-8.94l13.8-18.52q.72-.96 2.1-1.64t3.18-.68zm-14.92 50.4q2.36 0 4.34-.8t3.4-2.24 2.22-3.38.8-4.22q0-2.48-.76-4.46t-2.16-3.36-3.36-2.1-4.32-.72-4.28.8-3.28 2.22-2.12 3.36-.76 4.18q0 2.4.66 4.38t1.96 3.38 3.22 2.18 4.44.78M208.28 200q0 7.56-1.62 13.14t-4.48 9.22-6.76 5.42-8.42 1.78-8.38-1.78-6.7-5.42-4.44-9.22-1.6-13.14q0-7.6 1.6-13.16t4.44-9.2 6.7-5.42 8.38-1.78 8.42 1.78 6.76 5.42 4.48 9.2 1.62 13.16m-10.2 0q0-6.28-.92-10.4t-2.46-6.56-3.54-3.42-4.16-.98q-2.12 0-4.1.98t-3.5 3.42-2.42 6.56-.9 10.4.9 10.4 2.42 6.56 3.5 3.42 4.1.98q2.16 0 4.16-.98t3.54-3.42 2.46-6.56.92-10.4m56.6 0q0 7.56-1.62 13.14t-4.48 9.22-6.76 5.42-8.42 1.78-8.38-1.78-6.7-5.42-4.44-9.22-1.6-13.14q0-7.6 1.6-13.16t4.44-9.2 6.7-5.42 8.38-1.78 8.42 1.78 6.76 5.42 4.48 9.2 1.62 13.16m-10.2 0q0-6.28-.92-10.4t-2.46-6.56-3.54-3.42-4.16-.98q-2.12 0-4.1.98t-3.5 3.42-2.42 6.56-.9 10.4.9 10.4 2.42 6.56 3.5 3.42 4.1.98q2.16 0 4.16-.98t3.54-3.42 2.46-6.56.92-10.4m73.72 15.68-5.24 5.16-13.56-13.56-13.68 13.64-5.24-5.16 13.68-13.72L281.12 189l5.2-5.2 13.04 13.04 12.96-12.96 5.28 5.2-13 13zm34.64-8.56h17.6V188.2q0-2.68.36-5.92zm26.2 0h7.28v5.72q0 .8-.52 1.38t-1.48.58h-5.28v14.12h-8.6V214.8h-24.4q-1 0-1.76-.62t-.96-1.54l-1.04-5 27.4-36.6h9.36zm53.72-7.12q0 7.56-1.62 13.14t-4.48 9.22-6.76 5.42-8.42 1.78-8.38-1.78-6.7-5.42-4.44-9.22-1.6-13.14q0-7.6 1.6-13.16t4.44-9.2 6.7-5.42 8.38-1.78 8.42 1.78 6.76 5.42 4.48 9.2 1.62 13.16m-10.2 0q0-6.28-.92-10.4t-2.46-6.56-3.54-3.42-4.16-.98q-2.12 0-4.1.98t-3.5 3.42-2.42 6.56-.9 10.4.9 10.4 2.42 6.56 3.5 3.42 4.1.98q2.16 0 4.16-.98t3.54-3.42 2.46-6.56.92-10.4m56.6 0q0 7.56-1.62 13.14t-4.48 9.22-6.76 5.42-8.42 1.78-8.38-1.78-6.7-5.42-4.44-9.22-1.6-13.14q0-7.6 1.6-13.16t4.44-9.2 6.7-5.42 8.38-1.78 8.42 1.78 6.76 5.42 4.48 9.2 1.62 13.16m-10.2 0q0-6.28-.92-10.4t-2.46-6.56-3.54-3.42-4.16-.98q-2.12 0-4.1.98t-3.5 3.42-2.42 6.56-.9 10.4.9 10.4 2.42 6.56 3.5 3.42 4.1.98q2.16 0 4.16-.98t3.54-3.42 2.46-6.56.92-10.4"/></svg>
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
---
|
|
2
|
+
import VitopsHead from '@getvitops/astro/Head.astro';
|
|
3
|
+
import Seo from '@getvitops/astro/Seo.astro';
|
|
4
|
+
import '../styles/styles.css';
|
|
5
|
+
|
|
6
|
+
interface Props {
|
|
7
|
+
title?: string;
|
|
8
|
+
description?: string;
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
const { title, description } = Astro.props;
|
|
12
|
+
---
|
|
13
|
+
|
|
14
|
+
<html lang="en">
|
|
15
|
+
<head>
|
|
16
|
+
<meta charset="utf-8" />
|
|
17
|
+
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
|
18
|
+
<VitopsHead />
|
|
19
|
+
<Seo title={title} description={description} />
|
|
20
|
+
</head>
|
|
21
|
+
<body>
|
|
22
|
+
<main class="centered rhythm">
|
|
23
|
+
<slot />
|
|
24
|
+
</main>
|
|
25
|
+
</body>
|
|
26
|
+
</html>
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
---
|
|
2
|
+
import Layout from '../layouts/Layout.astro';
|
|
3
|
+
---
|
|
4
|
+
|
|
5
|
+
<Layout title="Page not found">
|
|
6
|
+
<section class="rhythm">
|
|
7
|
+
<h1>Page not found</h1>
|
|
8
|
+
<p>The page you're looking for doesn't exist.</p>
|
|
9
|
+
<p><a href="/">Back to the home page</a></p>
|
|
10
|
+
</section>
|
|
11
|
+
</Layout>
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
---
|
|
2
|
+
import Layout from '../layouts/Layout.astro';
|
|
3
|
+
---
|
|
4
|
+
|
|
5
|
+
<Layout description="Scaffolded with @getvitops/create — a static Astro site with the Vitops design system pre-wired.">
|
|
6
|
+
<section class="rhythm">
|
|
7
|
+
<h1>Welcome</h1>
|
|
8
|
+
<p>
|
|
9
|
+
Edit <code>site.json</code> (under <code>designSystem.themes.default</code>) and run
|
|
10
|
+
<code>pnpm run build:css</code> to regenerate the framework CSS, or edit this page directly.
|
|
11
|
+
</p>
|
|
12
|
+
</section>
|
|
13
|
+
</Layout>
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "node_modules/wrangler/config-schema.json",
|
|
3
|
+
"name": "my-static-site",
|
|
4
|
+
"compatibility_date": "2026-02-24",
|
|
5
|
+
// Pure static Astro output — Workers Static Assets, no adapter and no
|
|
6
|
+
// Worker script. This is the whole config: nothing else to provision.
|
|
7
|
+
"assets": {
|
|
8
|
+
"directory": "./dist",
|
|
9
|
+
},
|
|
10
|
+
// Explicit rather than relying on wrangler's default: this is the fact that
|
|
11
|
+
// lets a first deploy go live at <name>.<account>.workers.dev without
|
|
12
|
+
// touching any existing site's DNS — see SETUP.html's "Domain strategy"
|
|
13
|
+
// stage and site.json's environments.production.url.
|
|
14
|
+
"workers_dev": true,
|
|
15
|
+
// Custom domain: uncomment and set your apex. Cloudflare provisions the DNS
|
|
16
|
+
// record + TLS cert on deploy (the zone must already exist in the account) —
|
|
17
|
+
// and OVERWRITES it, the moment an existing live site at that domain goes
|
|
18
|
+
// dark. `pnpm run deploy:dev` rewrites this to `dev.<domain>` automatically
|
|
19
|
+
// (see scripts/dev-wrangler-config.mjs) — nothing to change for the dev
|
|
20
|
+
// deploy.
|
|
21
|
+
// "routes": [{ "pattern": "example.com", "custom_domain": true }],
|
|
22
|
+
}
|
|
@@ -1,102 +0,0 @@
|
|
|
1
|
-
// One-time GitHub bootstrap: creates a GitHub repo named after this project
|
|
2
|
-
// (package.json name), pushes `main` + `dev`, and makes `dev` the default
|
|
3
|
-
// branch — the shape the deploy workflows expect (deploy-dev on push to dev,
|
|
4
|
-
// deploy-prod on push to main, promote.yml between them).
|
|
5
|
-
//
|
|
6
|
-
// pnpm run init:github # private repo (default)
|
|
7
|
-
// pnpm run init:github -- --public
|
|
8
|
-
// pnpm run init:github -- --dry-run
|
|
9
|
-
//
|
|
10
|
-
// Idempotent: safe to re-run — existing git repo, commits, dev branch, and
|
|
11
|
-
// origin remote are all left alone. Requires the GitHub CLI (`gh`), logged in
|
|
12
|
-
// (`gh auth login`).
|
|
13
|
-
|
|
14
|
-
import { execSync, spawnSync } from 'node:child_process';
|
|
15
|
-
import { readFileSync } from 'node:fs';
|
|
16
|
-
|
|
17
|
-
const args = new Set(process.argv.slice(2));
|
|
18
|
-
const dryRun = args.has('--dry-run');
|
|
19
|
-
const visibility = args.has('--public') ? '--public' : '--private';
|
|
20
|
-
|
|
21
|
-
const repoName = JSON.parse(readFileSync('package.json', 'utf8')).name.replace(/^@[^/]+\//, '');
|
|
22
|
-
|
|
23
|
-
function check(cmd) {
|
|
24
|
-
return spawnSync(cmd[0], cmd.slice(1), { encoding: 'utf8' });
|
|
25
|
-
}
|
|
26
|
-
|
|
27
|
-
function quiet(cmd) {
|
|
28
|
-
try {
|
|
29
|
-
return execSync(cmd, { encoding: 'utf8', stdio: ['ignore', 'pipe', 'ignore'] }).trim();
|
|
30
|
-
} catch {
|
|
31
|
-
return null;
|
|
32
|
-
}
|
|
33
|
-
}
|
|
34
|
-
|
|
35
|
-
function run(cmd) {
|
|
36
|
-
if (dryRun) {
|
|
37
|
-
console.log(`[dry-run] ${cmd}`);
|
|
38
|
-
return;
|
|
39
|
-
}
|
|
40
|
-
console.log(`$ ${cmd}`);
|
|
41
|
-
try {
|
|
42
|
-
execSync(cmd, { stdio: 'inherit' });
|
|
43
|
-
} catch {
|
|
44
|
-
console.error(
|
|
45
|
-
`\nERROR: \`${cmd}\` failed (see output above). Fix and re-run — the script is idempotent.`,
|
|
46
|
-
);
|
|
47
|
-
process.exit(1);
|
|
48
|
-
}
|
|
49
|
-
}
|
|
50
|
-
|
|
51
|
-
// --- Preflight: gh installed and authenticated -------------------------------
|
|
52
|
-
if (check(['gh', '--version']).status !== 0) {
|
|
53
|
-
console.error('ERROR: the GitHub CLI (`gh`) is required. Install it from https://cli.github.com');
|
|
54
|
-
process.exit(1);
|
|
55
|
-
}
|
|
56
|
-
if (check(['gh', 'auth', 'status']).status !== 0) {
|
|
57
|
-
console.error('ERROR: `gh` is not logged in. Run `gh auth login` first.');
|
|
58
|
-
process.exit(1);
|
|
59
|
-
}
|
|
60
|
-
|
|
61
|
-
// --- Local git: repo, initial commit, main + dev branches --------------------
|
|
62
|
-
if (quiet('git rev-parse --is-inside-work-tree') === null) {
|
|
63
|
-
run('git init -b main');
|
|
64
|
-
}
|
|
65
|
-
if (quiet('git rev-parse HEAD') === null) {
|
|
66
|
-
run('git add -A');
|
|
67
|
-
run('git commit -m "Initial commit (scaffolded from @getvitops/create emdash template)"');
|
|
68
|
-
}
|
|
69
|
-
|
|
70
|
-
// The workflows key off `main`; normalize whatever the initial branch is.
|
|
71
|
-
const branch = quiet('git branch --show-current');
|
|
72
|
-
if (branch && branch !== 'main' && branch !== 'dev') {
|
|
73
|
-
run(`git branch -m ${branch} main`);
|
|
74
|
-
}
|
|
75
|
-
if (quiet('git show-ref --verify refs/heads/dev') === null) {
|
|
76
|
-
run('git branch dev main');
|
|
77
|
-
}
|
|
78
|
-
|
|
79
|
-
// --- GitHub: create repo (same name), push, default to dev -------------------
|
|
80
|
-
if (quiet('git remote get-url origin') === null) {
|
|
81
|
-
run(`gh repo create ${repoName} ${visibility} --source=. --remote=origin`);
|
|
82
|
-
} else {
|
|
83
|
-
console.log('origin remote already set — skipping `gh repo create`.');
|
|
84
|
-
}
|
|
85
|
-
run('git push -u origin main dev');
|
|
86
|
-
run('gh repo edit --default-branch dev');
|
|
87
|
-
run('git checkout dev');
|
|
88
|
-
|
|
89
|
-
// --- What's left (manual, needs your Cloudflare account) ---------------------
|
|
90
|
-
console.log(`
|
|
91
|
-
Repo ready: main (production) + dev (integration, default branch).
|
|
92
|
-
NOTE: the first workflow runs will fail until the secrets below exist.
|
|
93
|
-
|
|
94
|
-
Next steps:
|
|
95
|
-
1. Dev resources: wrangler d1 create ${repoName}-dev (note the printed id)
|
|
96
|
-
wrangler r2 bucket create ${repoName}-media-dev
|
|
97
|
-
2. Secrets: gh secret set CLOUDFLARE_API_TOKEN
|
|
98
|
-
gh secret set CLOUDFLARE_ACCOUNT_ID
|
|
99
|
-
gh secret set DEV_D1_ID
|
|
100
|
-
3. Protect main: Settings → Branches → protect 'main' (require the
|
|
101
|
-
promotion PR + review), so prod only ships via promote.yml.
|
|
102
|
-
`);
|
|
@@ -1,150 +0,0 @@
|
|
|
1
|
-
// One-time hosting-platform setup for the target configured in
|
|
2
|
-
// astro.config.mjs (vitopsHosting from @getvitops/emdash).
|
|
3
|
-
//
|
|
4
|
-
// pnpm run init:hosting # cloudflare (the default target)
|
|
5
|
-
// pnpm run init:hosting -- --dry-run
|
|
6
|
-
// pnpm run init:hosting -- --target node
|
|
7
|
-
//
|
|
8
|
-
// cloudflare: creates the isolated DEV resources (D1 database + R2 bucket —
|
|
9
|
-
// prod ones are auto-provisioned by wrangler on the first deploy) and, when a
|
|
10
|
-
// GitHub repo is wired up (see init-github.mjs), sets the repo secrets the
|
|
11
|
-
// deploy workflows need. The Cloudflare API token cannot be created via CLI,
|
|
12
|
-
// so that one secret stays manual.
|
|
13
|
-
//
|
|
14
|
-
// Idempotent: safe to re-run — existing resources and secrets are just
|
|
15
|
-
// updated/skipped. Requires wrangler auth (`npx wrangler login`).
|
|
16
|
-
|
|
17
|
-
import { execSync, spawnSync } from 'node:child_process';
|
|
18
|
-
import { readFileSync } from 'node:fs';
|
|
19
|
-
|
|
20
|
-
const args = process.argv.slice(2);
|
|
21
|
-
const dryRun = args.includes('--dry-run');
|
|
22
|
-
const targetFlag = args[args.indexOf('--target') + 1];
|
|
23
|
-
const target = (args.includes('--target') && targetFlag) || process.env.HOSTING || 'cloudflare';
|
|
24
|
-
|
|
25
|
-
const name = JSON.parse(readFileSync('package.json', 'utf8')).name.replace(/^@[^/]+\//, '');
|
|
26
|
-
|
|
27
|
-
function quiet(cmd) {
|
|
28
|
-
try {
|
|
29
|
-
return execSync(cmd, { encoding: 'utf8', stdio: ['ignore', 'pipe', 'ignore'] }).trim();
|
|
30
|
-
} catch {
|
|
31
|
-
return null;
|
|
32
|
-
}
|
|
33
|
-
}
|
|
34
|
-
|
|
35
|
-
function run(cmd, { capture = false } = {}) {
|
|
36
|
-
if (dryRun) {
|
|
37
|
-
console.log(`[dry-run] ${cmd}`);
|
|
38
|
-
return '';
|
|
39
|
-
}
|
|
40
|
-
console.log(`$ ${cmd}`);
|
|
41
|
-
try {
|
|
42
|
-
if (capture) {
|
|
43
|
-
const out = execSync(cmd, { encoding: 'utf8', stdio: ['ignore', 'pipe', 'inherit'] });
|
|
44
|
-
process.stdout.write(out);
|
|
45
|
-
return out;
|
|
46
|
-
}
|
|
47
|
-
execSync(cmd, { stdio: 'inherit' });
|
|
48
|
-
return '';
|
|
49
|
-
} catch {
|
|
50
|
-
console.error(
|
|
51
|
-
`\nERROR: \`${cmd}\` failed (see output above). Fix and re-run — the script is idempotent.`,
|
|
52
|
-
);
|
|
53
|
-
process.exit(1);
|
|
54
|
-
}
|
|
55
|
-
}
|
|
56
|
-
|
|
57
|
-
if (target === 'node') {
|
|
58
|
-
console.log(`Hosting target 'node' has no cloud resources to provision. To switch this
|
|
59
|
-
project to a Node host (VPS / docker-compose / k8s):
|
|
60
|
-
|
|
61
|
-
1. pnpm add @astrojs/node better-sqlite3
|
|
62
|
-
2. In astro.config.mjs: vitopsHosting({ target: 'node' }) (or set HOSTING=node)
|
|
63
|
-
3. Build and run: pnpm build && node ./dist/server/entry.mjs
|
|
64
|
-
Data lives in ./data/ (SQLite db + uploads) — persist it as a volume.
|
|
65
|
-
4. CI deploy for VPS/docker/k8s is not scaffolded yet — the deploy-*.yml
|
|
66
|
-
workflows are Cloudflare-specific; replace or disable them.
|
|
67
|
-
|
|
68
|
-
For production on Node, move storage to S3-compatible and/or the database to
|
|
69
|
-
Postgres via vitopsHosting({ node: { database, storage } }) — see the
|
|
70
|
-
@getvitops/emdash README.`);
|
|
71
|
-
process.exit(0);
|
|
72
|
-
}
|
|
73
|
-
|
|
74
|
-
if (target !== 'cloudflare') {
|
|
75
|
-
console.error(`ERROR: unknown hosting target '${target}'. Valid targets: cloudflare, node.`);
|
|
76
|
-
process.exit(1);
|
|
77
|
-
}
|
|
78
|
-
|
|
79
|
-
// --- Preflight: wrangler auth ------------------------------------------------
|
|
80
|
-
const whoami = spawnSync('npx', ['wrangler', 'whoami'], { encoding: 'utf8' });
|
|
81
|
-
if (whoami.status !== 0) {
|
|
82
|
-
console.error('ERROR: wrangler is not logged in. Run `npx wrangler login` first.');
|
|
83
|
-
process.exit(1);
|
|
84
|
-
}
|
|
85
|
-
// "Account Name | <32-hex account id>" table row in `wrangler whoami` output.
|
|
86
|
-
const accountId = (whoami.stdout.match(/\b([0-9a-f]{32})\b/) ?? [])[1] ?? null;
|
|
87
|
-
|
|
88
|
-
// --- Dev D1 database ---------------------------------------------------------
|
|
89
|
-
const devDb = `${name}-dev`;
|
|
90
|
-
let devDbId = null;
|
|
91
|
-
const d1List = quiet('npx wrangler d1 list --json');
|
|
92
|
-
if (d1List) {
|
|
93
|
-
devDbId = JSON.parse(d1List).find((d) => d.name === devDb)?.uuid ?? null;
|
|
94
|
-
}
|
|
95
|
-
if (devDbId) {
|
|
96
|
-
console.log(`D1 database ${devDb} already exists (${devDbId}).`);
|
|
97
|
-
} else {
|
|
98
|
-
const out = run(`npx wrangler d1 create ${devDb}`, { capture: true });
|
|
99
|
-
devDbId = (out.match(/"database_id":\s*"([0-9a-f-]{36})"/) ?? [])[1] ?? null;
|
|
100
|
-
if (!dryRun && !devDbId) {
|
|
101
|
-
// Output format drifts across wrangler versions — the list is authoritative.
|
|
102
|
-
const relist = quiet('npx wrangler d1 list --json');
|
|
103
|
-
devDbId = relist ? (JSON.parse(relist).find((d) => d.name === devDb)?.uuid ?? null) : null;
|
|
104
|
-
}
|
|
105
|
-
if (!dryRun && !devDbId) {
|
|
106
|
-
console.error('ERROR: could not determine the database_id of the created dev database.');
|
|
107
|
-
process.exit(1);
|
|
108
|
-
}
|
|
109
|
-
}
|
|
110
|
-
|
|
111
|
-
// --- Dev R2 bucket -----------------------------------------------------------
|
|
112
|
-
const devBucket = `${name}-media-dev`;
|
|
113
|
-
const bucketList = quiet('npx wrangler r2 bucket list');
|
|
114
|
-
if (bucketList && new RegExp(`name:\\s+${devBucket}\\s*$`, 'm').test(bucketList)) {
|
|
115
|
-
console.log(`R2 bucket ${devBucket} already exists.`);
|
|
116
|
-
} else {
|
|
117
|
-
run(`npx wrangler r2 bucket create ${devBucket}`);
|
|
118
|
-
}
|
|
119
|
-
|
|
120
|
-
// --- GitHub repo secrets (when the repo is wired up) -------------------------
|
|
121
|
-
const hasGh = spawnSync('gh', ['auth', 'status'], { encoding: 'utf8' }).status === 0;
|
|
122
|
-
const hasOrigin = quiet('git remote get-url origin') !== null;
|
|
123
|
-
if (hasGh && hasOrigin) {
|
|
124
|
-
if (devDbId) run(`gh secret set DEV_D1_ID --body ${devDbId}`);
|
|
125
|
-
if (accountId) run(`gh secret set CLOUDFLARE_ACCOUNT_ID --body ${accountId}`);
|
|
126
|
-
} else {
|
|
127
|
-
console.log(
|
|
128
|
-
'\nSkipping GitHub secrets (no gh auth or no origin remote — run init:github first).',
|
|
129
|
-
);
|
|
130
|
-
}
|
|
131
|
-
|
|
132
|
-
console.log(`
|
|
133
|
-
Cloudflare dev environment ready:
|
|
134
|
-
D1: ${devDb}${devDbId ? ` (${devDbId})` : ''}
|
|
135
|
-
R2: ${devBucket}
|
|
136
|
-
${
|
|
137
|
-
hasGh && hasOrigin
|
|
138
|
-
? ''
|
|
139
|
-
: ` Set repo secrets once GitHub is wired up:
|
|
140
|
-
gh secret set DEV_D1_ID --body ${devDbId ?? '<id>'}
|
|
141
|
-
gh secret set CLOUDFLARE_ACCOUNT_ID --body ${accountId ?? '<account id>'}
|
|
142
|
-
`
|
|
143
|
-
}
|
|
144
|
-
Still manual (CLI can't create API tokens):
|
|
145
|
-
1. Create a token with Workers + D1 + R2 edit permissions:
|
|
146
|
-
https://dash.cloudflare.com/profile/api-tokens
|
|
147
|
-
2. gh secret set CLOUDFLARE_API_TOKEN
|
|
148
|
-
|
|
149
|
-
Prod D1/R2 are provisioned automatically by wrangler on the first \`pnpm deploy\`.
|
|
150
|
-
Local \`pnpm deploy:dev\` runs need: export DEV_D1_ID=${devDbId ?? '<id>'}`);
|