@jakubmazanec/carson-templates 2.4.0 → 2.5.0-next.0f7a7a9
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/build/dependency-versions.js +2 -0
- package/build/dependency-versions.js.map +2 -2
- package/package.json +1 -1
- package/source/dependency-versions.ts +2 -0
- package/templates/projects/react-library/.storybook/preview.tsx.ensure.ejs +7 -0
- package/templates/projects/react-library/.storybook/{tailwind.css.ejs → tailwind.css.ensure.ejs} +2 -3
- package/templates/projects/react-library/.storybook/tailwindConfig.ts.ensure.ejs +8 -1
- package/templates/projects/react-library/.storybook/tsconfig.json.ejs +24 -0
- package/templates/projects/react-library/package.json.ejs +8 -4
- package/templates/projects/react-library/stories/tsconfig.json.ejs +24 -0
- package/templates/projects/react-library/tsconfig.typecheck.json.ejs +1 -1
- package/templates/projects/remix-app/app/tailwindConfig.ts.create.ejs +13 -0
- package/templates/projects/remix-app/tailwind.config.ts.ejs +1 -9
- package/templates/projects/remix-app/vite.config.ts.ejs +15 -7
- package/templates/workspace/.github/workflows/check-pull-request.yaml.ejs +1 -1
- package/templates/workspace/.github/workflows/release-pull-request.yaml.ejs +2 -2
- package/templates/workspace/.github/workflows/release.yaml.ejs +10 -0
- package/templates/workspace/.gitignore.ejs +3 -0
|
@@ -35,10 +35,12 @@ export const DEPENDENCY_VERSIONS = {
|
|
|
35
35
|
"@remix-run/node": "^2.0.0",
|
|
36
36
|
"@remix-run/react": "^2.0.0",
|
|
37
37
|
"@remix-run/serve": "^2.0.0",
|
|
38
|
+
"@storybook/addon-controls": "^8.0.0",
|
|
38
39
|
"@storybook/addon-essentials": "^8.0.0",
|
|
39
40
|
"@storybook/addon-interactions": "^8.0.0",
|
|
40
41
|
"@storybook/addon-links": "^8.0.0",
|
|
41
42
|
"@storybook/blocks": "^8.0.0",
|
|
43
|
+
"@storybook/preview-api": "^8.0.0",
|
|
42
44
|
"@storybook/react": "^8.0.0",
|
|
43
45
|
"@storybook/react-vite": "^8.0.0",
|
|
44
46
|
"@storybook/test": "^8.0.0",
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../source/dependency-versions.ts"],
|
|
4
|
-
"sourcesContent": ["import fs from 'node:fs';\nimport {createRequire} from 'node:module';\nimport semver from 'semver';\n\nimport {\n CARSON_PACKAGE_NAME,\n CHANGELOG_PACKAGE_NAME,\n LINTER_CONFIG_PACKAGE_NAME,\n TEMPLATE_PACKAGE_NAME,\n} from './constants.js';\n\nlet require = createRequire(import.meta.url);\nlet carsonPackageVersion =\n semver\n .minVersion(\n (\n JSON.parse(\n fs.readFileSync(require.resolve(`${TEMPLATE_PACKAGE_NAME}/package.json`), {\n encoding: 'utf8',\n }),\n ) as {peerDependencies: Record<string, string>}\n ).peerDependencies[CARSON_PACKAGE_NAME] ?? '^1.0.0',\n )\n ?.format() ?? '1.0.0';\nlet isCarsonPackageVersionPrerelease = !!semver.prerelease(carsonPackageVersion)?.length;\nlet templatesPackageVersion = (\n JSON.parse(\n fs.readFileSync(require.resolve(`${TEMPLATE_PACKAGE_NAME}/package.json`), {\n encoding: 'utf8',\n }),\n ) as {version: string}\n).version;\nlet isTemplatesPackageVersionPrerelease = !!semver.prerelease(templatesPackageVersion)?.length;\n\nexport const DEPENDENCY_VERSIONS: Record<string, string> = {\n [CARSON_PACKAGE_NAME]:\n isCarsonPackageVersionPrerelease ? carsonPackageVersion : `^${carsonPackageVersion}`,\n [TEMPLATE_PACKAGE_NAME]:\n isTemplatesPackageVersionPrerelease ? templatesPackageVersion : `^${templatesPackageVersion}`,\n [CHANGELOG_PACKAGE_NAME]: '^2.0.0',\n [LINTER_CONFIG_PACKAGE_NAME]: '^3.0.0',\n\n '@changesets/cli': '^2.0.0',\n '@chromatic-com/storybook': '^1.0.0',\n '@remix-run/dev': '^2.0.0',\n '@remix-run/express': '^2.0.0',\n '@remix-run/node': '^2.0.0',\n '@remix-run/react': '^2.0.0',\n '@remix-run/serve': '^2.0.0',\n '@storybook/addon-essentials': '^8.0.0',\n '@storybook/addon-interactions': '^8.0.0',\n '@storybook/addon-links': '^8.0.0',\n '@storybook/blocks': '^8.0.0',\n '@storybook/react': '^8.0.0',\n '@storybook/react-vite': '^8.0.0',\n '@storybook/test': '^8.0.0',\n '@testing-library/jest-dom': '^6.0.0',\n '@testing-library/react': '^14.0.0',\n '@types/lodash': '^4.0.0',\n '@types/node': '^20.0.0',\n '@types/react': '^18.0.0',\n '@types/react-dom': '^18.0.0',\n '@vitest/coverage-v8': '^1.0.0',\n autoprefixer: '^10.0.0',\n concurrently: '^8.0.0',\n 'cross-env': '^7.0.0',\n 'del-cli': '^5.0.0',\n esbuild: '^0.19.0',\n eslint: '^8.0.0',\n 'happy-dom': '^13.0.0',\n isbot: '^4.0.0',\n lodash: '^4.0.0',\n 'patch-package': '^6.0.0',\n prettier: '^3.0.0',\n 'prettier-plugin-packagejson': '^2.0.0',\n 'prettier-plugin-tailwindcss': '^0.5.0',\n react: '^18.0.0',\n 'react-dom': '^18.0.0',\n storybook: '^8.0.0',\n tailwindcss: '^3.0.0',\n turbo: '^1.0.0',\n typedoc: '^0.24.0',\n 'typedoc-plugin-markdown': '^3.0.0',\n typescript: '^5.0.0',\n vite: '^5.0.0',\n vitest: '^1.0.0',\n};\n"],
|
|
5
|
-
"mappings": ";AAAA,OAAO,QAAQ;AACf,SAAQ,qBAAoB;AAC5B,OAAO,YAAY;AAEnB;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OACK;AAEP,IAAI,UAAU,cAAc,YAAY,GAAG;AAC3C,IAAI,uBACF,OACG;AAAA,EAEG,KAAK;AAAA,IACH,GAAG,aAAa,QAAQ,QAAQ,GAAG,qBAAqB,eAAe,GAAG;AAAA,MACxE,UAAU;AAAA,IACZ,CAAC;AAAA,EACH,EACA,iBAAiB,mBAAmB,KAAK;AAC7C,GACE,OAAO,KAAK;AAClB,IAAI,mCAAmC,CAA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AAAA,EAC3B,YAAY;AAAA,EACZ,MAAM;AAAA,EACN,QAAQ;AACV;",
|
|
4
|
+
"sourcesContent": ["import fs from 'node:fs';\nimport {createRequire} from 'node:module';\nimport semver from 'semver';\n\nimport {\n CARSON_PACKAGE_NAME,\n CHANGELOG_PACKAGE_NAME,\n LINTER_CONFIG_PACKAGE_NAME,\n TEMPLATE_PACKAGE_NAME,\n} from './constants.js';\n\nlet require = createRequire(import.meta.url);\nlet carsonPackageVersion =\n semver\n .minVersion(\n (\n JSON.parse(\n fs.readFileSync(require.resolve(`${TEMPLATE_PACKAGE_NAME}/package.json`), {\n encoding: 'utf8',\n }),\n ) as {peerDependencies: Record<string, string>}\n ).peerDependencies[CARSON_PACKAGE_NAME] ?? '^1.0.0',\n )\n ?.format() ?? '1.0.0';\nlet isCarsonPackageVersionPrerelease = !!semver.prerelease(carsonPackageVersion)?.length;\nlet templatesPackageVersion = (\n JSON.parse(\n fs.readFileSync(require.resolve(`${TEMPLATE_PACKAGE_NAME}/package.json`), {\n encoding: 'utf8',\n }),\n ) as {version: string}\n).version;\nlet isTemplatesPackageVersionPrerelease = !!semver.prerelease(templatesPackageVersion)?.length;\n\nexport const DEPENDENCY_VERSIONS: Record<string, string> = {\n [CARSON_PACKAGE_NAME]:\n isCarsonPackageVersionPrerelease ? carsonPackageVersion : `^${carsonPackageVersion}`,\n [TEMPLATE_PACKAGE_NAME]:\n isTemplatesPackageVersionPrerelease ? templatesPackageVersion : `^${templatesPackageVersion}`,\n [CHANGELOG_PACKAGE_NAME]: '^2.0.0',\n [LINTER_CONFIG_PACKAGE_NAME]: '^3.0.0',\n\n '@changesets/cli': '^2.0.0',\n '@chromatic-com/storybook': '^1.0.0',\n '@remix-run/dev': '^2.0.0',\n '@remix-run/express': '^2.0.0',\n '@remix-run/node': '^2.0.0',\n '@remix-run/react': '^2.0.0',\n '@remix-run/serve': '^2.0.0',\n '@storybook/addon-controls': '^8.0.0',\n '@storybook/addon-essentials': '^8.0.0',\n '@storybook/addon-interactions': '^8.0.0',\n '@storybook/addon-links': '^8.0.0',\n '@storybook/blocks': '^8.0.0',\n '@storybook/preview-api': '^8.0.0',\n '@storybook/react': '^8.0.0',\n '@storybook/react-vite': '^8.0.0',\n '@storybook/test': '^8.0.0',\n '@testing-library/jest-dom': '^6.0.0',\n '@testing-library/react': '^14.0.0',\n '@types/lodash': '^4.0.0',\n '@types/node': '^20.0.0',\n '@types/react': '^18.0.0',\n '@types/react-dom': '^18.0.0',\n '@vitest/coverage-v8': '^1.0.0',\n autoprefixer: '^10.0.0',\n concurrently: '^8.0.0',\n 'cross-env': '^7.0.0',\n 'del-cli': '^5.0.0',\n esbuild: '^0.19.0',\n eslint: '^8.0.0',\n 'happy-dom': '^13.0.0',\n isbot: '^4.0.0',\n lodash: '^4.0.0',\n 'patch-package': '^6.0.0',\n prettier: '^3.0.0',\n 'prettier-plugin-packagejson': '^2.0.0',\n 'prettier-plugin-tailwindcss': '^0.5.0',\n react: '^18.0.0',\n 'react-dom': '^18.0.0',\n storybook: '^8.0.0',\n tailwindcss: '^3.0.0',\n turbo: '^1.0.0',\n typedoc: '^0.24.0',\n 'typedoc-plugin-markdown': '^3.0.0',\n typescript: '^5.0.0',\n vite: '^5.0.0',\n vitest: '^1.0.0',\n};\n"],
|
|
5
|
+
"mappings": ";AAAA,OAAO,QAAQ;AACf,SAAQ,qBAAoB;AAC5B,OAAO,YAAY;AAEnB;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,OACK;AAEP,IAAI,UAAU,cAAc,YAAY,GAAG;AAC3C,IAAI,uBACF,OACG;AAAA,EAEG,KAAK;AAAA,IACH,GAAG,aAAa,QAAQ,QAAQ,GAAG,qBAAqB,eAAe,GAAG;AAAA,MACxE,UAAU;AAAA,IACZ,CAAC;AAAA,EACH,EACA,iBAAiB,mBAAmB,KAAK;AAC7C,GACE,OAAO,KAAK;AAClB,IAAI,mCAAmC,CAAC,CAAC,OAAO,WAAW,oBAAoB,GAAG;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2BAA2B;AAAA,EAC3B,YAAY;AAAA,EACZ,MAAM;AAAA,EACN,QAAQ;AACV;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
package/package.json
CHANGED
|
@@ -47,10 +47,12 @@ export const DEPENDENCY_VERSIONS: Record<string, string> = {
|
|
|
47
47
|
'@remix-run/node': '^2.0.0',
|
|
48
48
|
'@remix-run/react': '^2.0.0',
|
|
49
49
|
'@remix-run/serve': '^2.0.0',
|
|
50
|
+
'@storybook/addon-controls': '^8.0.0',
|
|
50
51
|
'@storybook/addon-essentials': '^8.0.0',
|
|
51
52
|
'@storybook/addon-interactions': '^8.0.0',
|
|
52
53
|
'@storybook/addon-links': '^8.0.0',
|
|
53
54
|
'@storybook/blocks': '^8.0.0',
|
|
55
|
+
'@storybook/preview-api': '^8.0.0',
|
|
54
56
|
'@storybook/react': '^8.0.0',
|
|
55
57
|
'@storybook/react-vite': '^8.0.0',
|
|
56
58
|
'@storybook/test': '^8.0.0',
|
|
@@ -2,6 +2,13 @@
|
|
|
2
2
|
to: '.storybook/preview.tsx'
|
|
3
3
|
strategy: ensure
|
|
4
4
|
---
|
|
5
|
+
/**
|
|
6
|
+
* This file was autogenerated by Carson.
|
|
7
|
+
* If you edit it, your changes will be preserved. If you delete this file, it will be regenerated.
|
|
8
|
+
*
|
|
9
|
+
* Run `npx carson update workspace` to regenerate.
|
|
10
|
+
*/
|
|
11
|
+
|
|
5
12
|
import {type Preview} from '@storybook/react';
|
|
6
13
|
|
|
7
14
|
import './tailwind.css';
|
package/templates/projects/react-library/.storybook/{tailwind.css.ejs → tailwind.css.ensure.ejs}
RENAMED
|
@@ -1,11 +1,10 @@
|
|
|
1
1
|
---
|
|
2
2
|
to: '.storybook/tailwind.css'
|
|
3
|
-
strategy:
|
|
3
|
+
strategy: ensure
|
|
4
4
|
---
|
|
5
5
|
/**
|
|
6
|
-
* DO NOT EDIT!
|
|
7
6
|
* This file was autogenerated by Carson.
|
|
8
|
-
*
|
|
7
|
+
* If you edit it, your changes will be preserved. If you delete this file, it will be regenerated.
|
|
9
8
|
*
|
|
10
9
|
* Run `npx carson update workspace` to regenerate.
|
|
11
10
|
*/
|
|
@@ -2,10 +2,17 @@
|
|
|
2
2
|
to: '.storybook/tailwindConfig.ts'
|
|
3
3
|
strategy: ensure
|
|
4
4
|
---
|
|
5
|
+
/**
|
|
6
|
+
* This file was autogenerated by Carson.
|
|
7
|
+
* If you edit it, your changes will be preserved. If you delete this file, it will be regenerated.
|
|
8
|
+
*
|
|
9
|
+
* Run `npx carson update workspace` to regenerate.
|
|
10
|
+
*/
|
|
11
|
+
|
|
5
12
|
import {type Config} from 'tailwindcss';
|
|
6
13
|
|
|
7
14
|
export const tailwindConfig = {
|
|
8
|
-
content: ['./{.storybook,source,stories}/**/*.{js,jsx,ts,tsx}'],
|
|
15
|
+
content: ['./{.storybook,source,stories}/**/*.{js,jsx,ts,tsx,mdx}'],
|
|
9
16
|
theme: {
|
|
10
17
|
extend: {},
|
|
11
18
|
},
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
---
|
|
2
|
+
to: '.storybook/tsconfig.json'
|
|
3
|
+
strategy: overwrite
|
|
4
|
+
---
|
|
5
|
+
<%
|
|
6
|
+
let tsconfig = {
|
|
7
|
+
compilerOptions: {
|
|
8
|
+
...TSCONFIG_COMPILER_OPTIONS,
|
|
9
|
+
composite: false,
|
|
10
|
+
noEmit: true,
|
|
11
|
+
},
|
|
12
|
+
include: ['./**/*'],
|
|
13
|
+
references: [{path: '..'}],
|
|
14
|
+
};
|
|
15
|
+
-%>
|
|
16
|
+
//
|
|
17
|
+
// DO NOT EDIT!
|
|
18
|
+
// This file was autogenerated by Carson.
|
|
19
|
+
// Changes may cause incorrect behavior and will be lost when the file is regenerated.
|
|
20
|
+
//
|
|
21
|
+
// Run `npx carson update workspace` to regenerate.
|
|
22
|
+
//
|
|
23
|
+
|
|
24
|
+
<%- JSON.stringify(tsconfig, null, 2) %>
|
|
@@ -11,13 +11,15 @@ if (project.packageJson.bin) {
|
|
|
11
11
|
|
|
12
12
|
files.sort();
|
|
13
13
|
|
|
14
|
-
let
|
|
14
|
+
let developmentDependencies = [
|
|
15
15
|
LINTER_CONFIG_PACKAGE_NAME,
|
|
16
16
|
'@chromatic-com/storybook',
|
|
17
|
+
'@storybook/addon-control',
|
|
17
18
|
'@storybook/addon-essentials',
|
|
18
19
|
'@storybook/addon-interactions',
|
|
19
20
|
'@storybook/addon-links',
|
|
20
21
|
'@storybook/blocks',
|
|
22
|
+
'@storybook/preview-api',
|
|
21
23
|
'@storybook/react',
|
|
22
24
|
'@storybook/react-vite',
|
|
23
25
|
'@storybook/test',
|
|
@@ -49,7 +51,6 @@ let dependencies = [
|
|
|
49
51
|
].filter((dependency) => {
|
|
50
52
|
return !Object.keys(project.packageJson.dependencies ?? {}).some((key) => key === dependency); // if a project package.json already contains dependency, we don't need to add it
|
|
51
53
|
});
|
|
52
|
-
let developmentDependencies = getDependencies(dependencies, workspace);
|
|
53
54
|
let packageJson = lodash.merge(
|
|
54
55
|
{
|
|
55
56
|
repository: {
|
|
@@ -57,7 +58,10 @@ let packageJson = lodash.merge(
|
|
|
57
58
|
directory: project.relativePath,
|
|
58
59
|
},
|
|
59
60
|
type: 'module',
|
|
60
|
-
exports:
|
|
61
|
+
exports: {
|
|
62
|
+
'.': `./${BUILD_DIRECTORY}/main.js`,
|
|
63
|
+
'./package.json': './package.json',
|
|
64
|
+
},
|
|
61
65
|
files,
|
|
62
66
|
scripts: {
|
|
63
67
|
build: `del-cli ${BUILD_DIRECTORY} tsconfig.tsbuildinfo && ${BUILD_TO_ESM_COMMAND} && tsc && storybook build`,
|
|
@@ -69,7 +73,7 @@ let packageJson = lodash.merge(
|
|
|
69
73
|
test: `del-cli coverage && ${TEST_COMMAND}`,
|
|
70
74
|
typecheck: 'tsc --project tsconfig.typecheck.json',
|
|
71
75
|
},
|
|
72
|
-
devDependencies: developmentDependencies,
|
|
76
|
+
devDependencies: getDependencies(developmentDependencies, workspace),
|
|
73
77
|
peerDependencies: {
|
|
74
78
|
react: '18.x',
|
|
75
79
|
'react-dom': '18.x',
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
---
|
|
2
|
+
to: 'stories/tsconfig.json'
|
|
3
|
+
strategy: overwrite
|
|
4
|
+
---
|
|
5
|
+
<%
|
|
6
|
+
let tsconfig = {
|
|
7
|
+
compilerOptions: {
|
|
8
|
+
...TSCONFIG_COMPILER_OPTIONS,
|
|
9
|
+
composite: false,
|
|
10
|
+
noEmit: true,
|
|
11
|
+
},
|
|
12
|
+
include: ['./**/*'],
|
|
13
|
+
references: [{path: '..'}],
|
|
14
|
+
};
|
|
15
|
+
-%>
|
|
16
|
+
//
|
|
17
|
+
// DO NOT EDIT!
|
|
18
|
+
// This file was autogenerated by Carson.
|
|
19
|
+
// Changes may cause incorrect behavior and will be lost when the file is regenerated.
|
|
20
|
+
//
|
|
21
|
+
// Run `npx carson update workspace` to regenerate.
|
|
22
|
+
//
|
|
23
|
+
|
|
24
|
+
<%- JSON.stringify(tsconfig, null, 2) %>
|
|
@@ -11,7 +11,7 @@ let tsconfig = {
|
|
|
11
11
|
noEmit: true,
|
|
12
12
|
rootDir: '.',
|
|
13
13
|
},
|
|
14
|
-
include: ['./.storybook/**/*', `./${SOURCE_DIRECTORY}/**/*`, './stories/**/*', './tests/**/*', './*'],
|
|
14
|
+
include: ['./.storybook/**/*', `./${SOURCE_DIRECTORY}/**/*`, './stories/**/*', './tests/**/*', './tools/**/*', './*'],
|
|
15
15
|
};
|
|
16
16
|
-%>
|
|
17
17
|
//
|
|
@@ -10,12 +10,4 @@ strategy: overwrite
|
|
|
10
10
|
* Run `npx carson update workspace` to regenerate.
|
|
11
11
|
*/
|
|
12
12
|
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
export default {
|
|
16
|
-
content: ['./app/**/*.{js,jsx,ts,tsx}'],
|
|
17
|
-
theme: {
|
|
18
|
-
extend: {},
|
|
19
|
-
},
|
|
20
|
-
plugins: [],
|
|
21
|
-
} satisfies Config;
|
|
13
|
+
export {tailwindConfig as default} from './app/tailwindConfig.js';
|
|
@@ -24,13 +24,21 @@ export default defineConfig(
|
|
|
24
24
|
port: 5000,
|
|
25
25
|
strictPort: true,
|
|
26
26
|
},
|
|
27
|
-
plugins: [
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
27
|
+
plugins: [
|
|
28
|
+
!process.env.VITEST &&
|
|
29
|
+
remix(
|
|
30
|
+
_.merge(
|
|
31
|
+
{
|
|
32
|
+
future: {
|
|
33
|
+
v3_fetcherPersist: true,
|
|
34
|
+
v3_relativeSplatPath: true,
|
|
35
|
+
v3_throwAbortReason: true,
|
|
36
|
+
},
|
|
37
|
+
},
|
|
38
|
+
<%- JSON.stringify(project.config.overrides?.remixConfig ?? {}, null, 2) %>,
|
|
39
|
+
),
|
|
40
|
+
),
|
|
41
|
+
],
|
|
34
42
|
test: {
|
|
35
43
|
environment: 'happy-dom',
|
|
36
44
|
setupFiles: ['tests/setup.ts'],
|
|
@@ -101,7 +101,7 @@ for (let project of workspace.projects) {
|
|
|
101
101
|
npm run test -- --filter=<%- project.name %>
|
|
102
102
|
env:
|
|
103
103
|
EDGEDB_INSTANCE: <%- project.config.deployment.dbInstance %>
|
|
104
|
-
EDGEDB_BRANCH:
|
|
104
|
+
EDGEDB_BRANCH: <%- workspace.packageJson.name %>-${{ github.head_ref }}
|
|
105
105
|
EDGEDB_SECRET_KEY: ${{ secrets.<%- lodash.snakeCase(project.config.deployment.dbInstance).toUpperCase() %>_EDGEDB_TOKEN }}
|
|
106
106
|
<%
|
|
107
107
|
}
|
|
@@ -120,7 +120,7 @@ for (let project of workspace.projects) {
|
|
|
120
120
|
npm run test -- --filter=<%- project.name %>
|
|
121
121
|
env:
|
|
122
122
|
EDGEDB_INSTANCE: <%- project.config.deployment.dbInstance %>
|
|
123
|
-
EDGEDB_BRANCH:
|
|
123
|
+
EDGEDB_BRANCH: <%- workspace.packageJson.name %>-${{ github.head_ref }}
|
|
124
124
|
EDGEDB_SECRET_KEY: ${{ secrets.<%- lodash.snakeCase(project.config.deployment.dbInstance).toUpperCase() %>_EDGEDB_TOKEN }}
|
|
125
125
|
<%
|
|
126
126
|
}
|
|
@@ -175,7 +175,7 @@ for (let project of workspace.projects) {
|
|
|
175
175
|
env:
|
|
176
176
|
VITE_APP_URL: <%- getAppUrl(project, 'unstable') %>
|
|
177
177
|
EDGEDB_INSTANCE: <%- project.config.deployment.dbInstance %>
|
|
178
|
-
EDGEDB_BRANCH:
|
|
178
|
+
EDGEDB_BRANCH: <%- workspace.packageJson.name %>-${{ github.head_ref }}
|
|
179
179
|
EDGEDB_SECRET_KEY: ${{ secrets.<%- lodash.snakeCase(project.config.deployment.dbInstance).toUpperCase() %>_EDGEDB_TOKEN }}
|
|
180
180
|
FLY_ACCESS_TOKEN: ${{ secrets.FLY_TOKEN }}
|
|
181
181
|
FLY_API_TOKEN: ${{ secrets.FLY_TOKEN }}
|
|
@@ -233,6 +233,16 @@ for (let project of workspace.projects) {
|
|
|
233
233
|
VITE_APP_URL: <%- getAppUrl(project) %>
|
|
234
234
|
FLY_ACCESS_TOKEN: ${{ secrets.FLY_TOKEN }}
|
|
235
235
|
FLY_API_TOKEN: ${{ secrets.FLY_TOKEN }}
|
|
236
|
+
<%
|
|
237
|
+
} else if (project.config.template.includes('projects/react-library')) {
|
|
238
|
+
-%>
|
|
239
|
+
|
|
240
|
+
- name: Deploy "<%- project.name %>"
|
|
241
|
+
run: |
|
|
242
|
+
cd <%- project.relativePath %>
|
|
243
|
+
npx --yes chromatic --project-token="$CHROMATIC_TOKEN" --storybook-build-dir storybook-static --exit-zero-on-changes --no-interactive
|
|
244
|
+
env:
|
|
245
|
+
CHROMATIC_TOKEN: ${{ secrets.<%- lodash.snakeCase(project.name).toUpperCase() %>_CHROMATIC_TOKEN }}
|
|
236
246
|
<%
|
|
237
247
|
}
|
|
238
248
|
}
|