@dword-design/base 14.1.2 → 15.0.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/dist/commands/lint/index.js +0 -1
- package/dist/commands/test-docker/index.js +1 -1
- package/dist/get-generated-files/get-github-workflow/steps/get-test.js +1 -1
- package/dist/get-generated-files/github-codespaces-postcreate.d.ts +2 -0
- package/dist/get-generated-files/github-codespaces-postcreate.js +12 -0
- package/dist/get-generated-files/github-codespaces.js +1 -1
- package/dist/get-generated-files/index.d.ts +4 -1
- package/dist/get-generated-files/index.js +5 -1
- package/package.json +3 -3
|
@@ -14,7 +14,7 @@ export default async function (options) {
|
|
|
14
14
|
const envSchemaPath = findUpSync(".env.schema.json", {
|
|
15
15
|
cwd: this.cwd
|
|
16
16
|
});
|
|
17
|
-
const envVariableNames = Object.keys(envSchemaPath ? await fs.readJson(envSchemaPath) : {}).map(name =>
|
|
17
|
+
const envVariableNames = Object.keys(envSchemaPath ? await fs.readJson(envSchemaPath) : {}).map(name => constantCase(name));
|
|
18
18
|
const userInfo = getUserInfo();
|
|
19
19
|
try {
|
|
20
20
|
return await execa("docker", ["run", "--rm", ...envVariableNames.filter(name => process.env[name] !== void 0).flatMap(name => ["--env", `${name}=${process.env[name]}`]), "-v", `${this.cwd}:/app`, "-v", `${volumeName}:/app/node_modules`, "dworddesign/testing:latest", "bash", "-c", ["pnpm install --frozen-lockfile", "&&", "pnpm test:raw", ...(options.updateSnapshots ? [" --update-snapshots"] : []), ...options.patterns.map(pattern => `"${pattern}"`), ...(options.grep ? [`-g "${options.grep}"`] : [])].join(" ")], {
|
|
@@ -14,7 +14,7 @@ export default function () {
|
|
|
14
14
|
}, {
|
|
15
15
|
cwd: this.cwd
|
|
16
16
|
});
|
|
17
|
-
const envVariableNames = Object.keys(envSchemaPath ? fs.readJsonSync(envSchemaPath) : {}).map(name =>
|
|
17
|
+
const envVariableNames = Object.keys(envSchemaPath ? fs.readJsonSync(envSchemaPath) : {}).map(name => constantCase(name));
|
|
18
18
|
return [{
|
|
19
19
|
env: {
|
|
20
20
|
...Object.fromEntries(envVariableNames.map(name => [name, `\${{ secrets.${name} }}`])),
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import endent from "endent";
|
|
2
|
+
export default endent`
|
|
3
|
+
# Doppler ######################################################
|
|
4
|
+
# See https://docs.doppler.com/docs/install-cli#installation
|
|
5
|
+
sudo apt-get update && sudo apt-get install -y apt-transport-https ca-certificates curl gnupg
|
|
6
|
+
curl -sLf --retry 3 --tlsv1.2 --proto "=https" 'https://packages.doppler.com/public/cli/gpg.DE2A7741A397C129.key' | sudo gpg --dearmor -o /usr/share/keyrings/doppler-archive-keyring.gpg
|
|
7
|
+
echo "deb [signed-by=/usr/share/keyrings/doppler-archive-keyring.gpg] https://packages.doppler.com/public/cli/deb/debian any-version main" | sudo tee /etc/apt/sources.list.d/doppler-cli.list
|
|
8
|
+
sudo apt-get update && sudo apt-get install doppler
|
|
9
|
+
# ##############################################################
|
|
10
|
+
|
|
11
|
+
pnpm install --frozen-lockfile\n
|
|
12
|
+
`;
|
|
@@ -1,7 +1,10 @@
|
|
|
1
1
|
export default function (): {
|
|
2
2
|
'.commitlintrc.json': string;
|
|
3
3
|
'.cz.json': string;
|
|
4
|
-
'.devcontainer
|
|
4
|
+
'.devcontainer': {
|
|
5
|
+
'devcontainer.json': string;
|
|
6
|
+
'postcreate.sh': string;
|
|
7
|
+
};
|
|
5
8
|
'.editorconfig': string;
|
|
6
9
|
'.gitattributes': string;
|
|
7
10
|
'.github/DEPRECATED_DEPENDENCIES_ISSUE_TEMPLATE.md': string;
|
|
@@ -5,6 +5,7 @@ import commitizenConfig from "./commitizen.js";
|
|
|
5
5
|
import commitlintConfig from "./commitlint.js";
|
|
6
6
|
import editorconfigConfig from "./editorconfig.js";
|
|
7
7
|
import gitattributesConfig from "./gitattributes.js";
|
|
8
|
+
import githubCodespacesPostcreate from "./github-codespaces-postcreate.js";
|
|
8
9
|
import githubDeprecatedDependenciesConfig from "./github-deprecated-dependencies/index.js";
|
|
9
10
|
import deprecatedDependenciesIssueTemplate from "./github-deprecated-dependencies-issue-template.js";
|
|
10
11
|
import githubFunding from "./github-funding.js";
|
|
@@ -18,8 +19,11 @@ export default function () {
|
|
|
18
19
|
`,
|
|
19
20
|
".cz.json": `${JSON.stringify(commitizenConfig, void 0, 2)}
|
|
20
21
|
`,
|
|
21
|
-
".devcontainer
|
|
22
|
+
".devcontainer": {
|
|
23
|
+
"devcontainer.json": `${JSON.stringify(this.githubCodespacesConfig, void 0, 2)}
|
|
22
24
|
`,
|
|
25
|
+
"postcreate.sh": githubCodespacesPostcreate
|
|
26
|
+
},
|
|
23
27
|
".editorconfig": editorconfigConfig,
|
|
24
28
|
".gitattributes": gitattributesConfig,
|
|
25
29
|
".github/DEPRECATED_DEPENDENCIES_ISSUE_TEMPLATE.md": deprecatedDependenciesIssueTemplate,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dword-design/base",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "15.0.0",
|
|
4
4
|
"description": "Base package for projects.",
|
|
5
5
|
"repository": "dword-design/base",
|
|
6
6
|
"funding": "https://github.com/sponsors/dword-design",
|
|
@@ -38,7 +38,7 @@
|
|
|
38
38
|
"@dword-design/base-config-node": "^3.0.17",
|
|
39
39
|
"@dword-design/ci": "^4.0.6",
|
|
40
40
|
"@dword-design/defu": "^1.0.3",
|
|
41
|
-
"@dword-design/eslint-config": "^
|
|
41
|
+
"@dword-design/eslint-config": "^8.0.0",
|
|
42
42
|
"@dword-design/personal-data": "^2.0.3",
|
|
43
43
|
"@semantic-release/changelog": "^6.0.3",
|
|
44
44
|
"@semantic-release/git": "^10.0.1",
|
|
@@ -86,7 +86,7 @@
|
|
|
86
86
|
"yaml": "^2.8.0"
|
|
87
87
|
},
|
|
88
88
|
"devDependencies": {
|
|
89
|
-
"@dword-design/dotenv-json-extended": "^
|
|
89
|
+
"@dword-design/dotenv-json-extended": "^4.0.1",
|
|
90
90
|
"@playwright/test": "^1.54.1",
|
|
91
91
|
"@types/hosted-git-info": "^3.0.5",
|
|
92
92
|
"@types/parse-git-config": "^3.0.4",
|