@quadnix/octo-build 0.0.17 → 0.2.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/LICENSE +661 -0
- package/README.md +117 -8
- package/dist/commands/apply/apply.command.d.ts +25 -0
- package/dist/commands/apply/apply.command.js +130 -0
- package/dist/commands/apply/apply.command.js.map +1 -0
- package/dist/commands/apply/index.d.ts +1 -0
- package/dist/commands/apply/index.js +2 -0
- package/dist/commands/apply/index.js.map +1 -0
- package/dist/commands/build/build.command.d.ts +1 -1
- package/dist/commands/build/build.command.js +4 -4
- package/dist/commands/build/build.command.js.map +1 -1
- package/dist/commands/build/main.d.ts +22 -0
- package/dist/commands/build/main.js +22 -0
- package/dist/commands/build/main.js.map +1 -1
- package/dist/commands/build/parsers/build-file.parser.d.ts +6 -0
- package/dist/commands/build/parsers/build-file.parser.js +6 -0
- package/dist/commands/build/parsers/build-file.parser.js.map +1 -1
- package/dist/commands/build/streams/stream-manager.d.ts +6 -0
- package/dist/commands/build/streams/stream-manager.js +7 -1
- package/dist/commands/build/streams/stream-manager.js.map +1 -1
- package/dist/commands/commit/commit.command.d.ts +23 -0
- package/dist/commands/commit/commit.command.js +81 -0
- package/dist/commands/commit/commit.command.js.map +1 -0
- package/dist/commands/commit/index.d.ts +1 -0
- package/dist/commands/commit/index.js +2 -0
- package/dist/commands/commit/index.js.map +1 -0
- package/dist/commands/create-anchor/create-anchor.command.js +1 -1
- package/dist/commands/create-anchor/create-anchor.command.js.map +1 -1
- package/dist/commands/create-anchor/generator-octo-anchor-template/generators/app/index.d.ts +18 -3
- package/dist/commands/create-anchor/generator-octo-anchor-template/generators/app/index.js +29 -11
- package/dist/commands/create-anchor/generator-octo-anchor-template/generators/app/index.js.map +1 -1
- package/dist/commands/create-anchor/generator-octo-anchor-template/generators/app/templates/anchors/anchor/anchor.schema.ts.ejs +9 -1
- package/dist/commands/create-app/create-app.command.d.ts +1 -1
- package/dist/commands/create-app/create-app.command.js +7 -3
- package/dist/commands/create-app/create-app.command.js.map +1 -1
- package/dist/commands/create-app/generator-octo-app-template/generators/app/index.d.ts +17 -1
- package/dist/commands/create-app/generator-octo-app-template/generators/app/index.js +72 -16
- package/dist/commands/create-app/generator-octo-app-template/generators/app/index.js.map +1 -1
- package/dist/commands/create-app/generator-octo-app-template/generators/app/templates/README.md.ejs +73 -14
- package/dist/commands/create-app/generator-octo-app-template/generators/app/templates/gitignore.ejs +14 -0
- package/dist/commands/create-app/generator-octo-app-template/generators/app/templates/index.ts.ejs +19 -0
- package/dist/commands/create-app/generator-octo-app-template/generators/app/templates/package.json.ejs +9 -1
- package/dist/commands/create-app/generator-octo-app-template/generators/app/templates/src/aws-dynamodb-service/octo.yaml.ejs +111 -0
- package/dist/commands/create-app/generator-octo-app-template/generators/app/templates/src/aws-ecs-server/octo.yaml.ejs +28 -16
- package/dist/commands/create-app/generator-octo-app-template/generators/app/templates/src/aws-s3-website/octo.yaml.ejs +25 -3
- package/dist/commands/create-app/generator-octo-app-template/generators/app/templates/tsconfig.json.ejs +0 -3
- package/dist/commands/{create-resource/create-resource.command.d.ts → create-external-resource/create-external-resource.command.d.ts} +1 -1
- package/dist/commands/create-external-resource/create-external-resource.command.js +64 -0
- package/dist/commands/create-external-resource/create-external-resource.command.js.map +1 -0
- package/dist/commands/{create-resource/generator-octo-resource-template → create-external-resource/generator-octo-external-resource-template}/generators/app/index.d.ts +17 -2
- package/dist/commands/{create-resource/generator-octo-resource-template → create-external-resource/generator-octo-external-resource-template}/generators/app/index.js +36 -35
- package/dist/commands/create-external-resource/generator-octo-external-resource-template/generators/app/index.js.map +1 -0
- package/dist/commands/{create-resource/generator-octo-resource-template → create-external-resource/generator-octo-external-resource-template}/generators/app/templates/resources/resource/actions/add.resource.action.ts.ejs +7 -16
- package/dist/commands/{create-resource/generator-octo-resource-template → create-external-resource/generator-octo-external-resource-template}/generators/app/templates/resources/resource/actions/delete.resource.action.ts.ejs +21 -3
- package/dist/commands/create-external-resource/generator-octo-external-resource-template/generators/app/templates/resources/resource/actions/update.resource.action.ts.ejs +63 -0
- package/dist/commands/{create-resource/generator-octo-resource-template → create-external-resource/generator-octo-external-resource-template}/generators/app/templates/resources/resource/index.ts.ejs +1 -2
- package/dist/commands/create-external-resource/generator-octo-external-resource-template/generators/app/templates/resources/resource/resource.ts.ejs +28 -0
- package/dist/commands/create-external-resource/index.d.ts +1 -0
- package/dist/commands/create-external-resource/index.js +2 -0
- package/dist/commands/create-external-resource/index.js.map +1 -0
- package/dist/commands/create-model/create-model.command.js +1 -1
- package/dist/commands/create-model/create-model.command.js.map +1 -1
- package/dist/commands/create-model/generator-octo-model-template/generators/app/index.d.ts +17 -2
- package/dist/commands/create-model/generator-octo-model-template/generators/app/index.js +26 -9
- package/dist/commands/create-model/generator-octo-model-template/generators/app/index.js.map +1 -1
- package/dist/commands/create-model/generator-octo-model-template/generators/app/templates/models/model/model.ts.ejs +41 -1
- package/dist/commands/create-model/generator-octo-model-template/generators/app/templates/models/model/schema.ts.ejs +6 -1
- package/dist/commands/create-module/create-module.command.js +1 -1
- package/dist/commands/create-module/create-module.command.js.map +1 -1
- package/dist/commands/create-module/generator-octo-module-template/generators/app/index.d.ts +17 -2
- package/dist/commands/create-module/generator-octo-module-template/generators/app/index.js +27 -10
- package/dist/commands/create-module/generator-octo-module-template/generators/app/index.js.map +1 -1
- package/dist/commands/create-overlay/create-overlay.command.js +4 -3
- package/dist/commands/create-overlay/create-overlay.command.js.map +1 -1
- package/dist/commands/create-overlay/generator-octo-overlay-template/generators/app/index.d.ts +17 -2
- package/dist/commands/create-overlay/generator-octo-overlay-template/generators/app/index.js +26 -9
- package/dist/commands/create-overlay/generator-octo-overlay-template/generators/app/index.js.map +1 -1
- package/dist/commands/{create-cdk/create-cdk.command.d.ts → create-terraform-resource/create-terraform-resource.command.d.ts} +3 -3
- package/dist/commands/{create-resource/create-resource.command.js → create-terraform-resource/create-terraform-resource.command.js} +17 -11
- package/dist/commands/create-terraform-resource/create-terraform-resource.command.js.map +1 -0
- package/dist/commands/create-terraform-resource/generator-octo-terraform-resource-template/generators/app/index.d.ts +25 -0
- package/dist/commands/create-terraform-resource/generator-octo-terraform-resource-template/generators/app/index.js +71 -0
- package/dist/commands/create-terraform-resource/generator-octo-terraform-resource-template/generators/app/index.js.map +1 -0
- package/dist/commands/create-terraform-resource/generator-octo-terraform-resource-template/generators/app/templates/resources/resource/index.schema.ts.ejs +43 -0
- package/dist/commands/create-terraform-resource/generator-octo-terraform-resource-template/generators/app/templates/resources/resource/index.ts.ejs +1 -0
- package/dist/commands/create-terraform-resource/generator-octo-terraform-resource-template/generators/app/templates/resources/resource/resource.ts.ejs +83 -0
- package/dist/commands/create-terraform-resource/index.d.ts +1 -0
- package/dist/commands/create-terraform-resource/index.js +2 -0
- package/dist/commands/create-terraform-resource/index.js.map +1 -0
- package/dist/commands/generate/generate.command.d.ts +16 -0
- package/dist/commands/generate/generate.command.js +35 -0
- package/dist/commands/generate/generate.command.js.map +1 -0
- package/dist/commands/generate/index.d.ts +1 -0
- package/dist/commands/generate/index.js +2 -0
- package/dist/commands/generate/index.js.map +1 -0
- package/dist/commands/get-response/get-response.command.d.ts +18 -0
- package/dist/commands/get-response/get-response.command.js +39 -0
- package/dist/commands/get-response/get-response.command.js.map +1 -0
- package/dist/commands/get-response/index.d.ts +1 -0
- package/dist/commands/get-response/index.js +2 -0
- package/dist/commands/get-response/index.js.map +1 -0
- package/dist/commands/lock/index.d.ts +1 -0
- package/dist/commands/lock/index.js +2 -0
- package/dist/commands/lock/index.js.map +1 -0
- package/dist/commands/lock/lock.command.d.ts +18 -0
- package/dist/commands/lock/lock.command.js +31 -0
- package/dist/commands/lock/lock.command.js.map +1 -0
- package/dist/commands/run-action/index.d.ts +1 -0
- package/dist/commands/run-action/index.js +2 -0
- package/dist/commands/run-action/index.js.map +1 -0
- package/dist/commands/run-action/run-action.command.d.ts +12 -0
- package/dist/commands/run-action/run-action.command.js +40 -0
- package/dist/commands/run-action/run-action.command.js.map +1 -0
- package/dist/commands/unlock/index.d.ts +1 -0
- package/dist/commands/unlock/index.js +2 -0
- package/dist/commands/unlock/index.js.map +1 -0
- package/dist/commands/unlock/unlock.command.d.ts +18 -0
- package/dist/commands/unlock/unlock.command.js +35 -0
- package/dist/commands/unlock/unlock.command.js.map +1 -0
- package/dist/commands/validate/index.d.ts +1 -0
- package/dist/commands/validate/index.js +2 -0
- package/dist/commands/validate/index.js.map +1 -0
- package/dist/commands/validate/validate.command.d.ts +17 -0
- package/dist/commands/validate/validate.command.js +62 -0
- package/dist/commands/validate/validate.command.js.map +1 -0
- package/dist/index.js +20 -8
- package/dist/index.js.map +1 -1
- package/dist/resources/octo-v1.schema.json +108 -27
- package/dist/utilities/definition/yaml/yaml-definition.utility.d.ts +103 -13
- package/dist/utilities/definition/yaml/yaml-definition.utility.js +215 -68
- package/dist/utilities/definition/yaml/yaml-definition.utility.js.map +1 -1
- package/dist/utilities/octo/octo.utility.d.ts +65 -0
- package/dist/utilities/octo/octo.utility.js +178 -0
- package/dist/utilities/octo/octo.utility.js.map +1 -0
- package/dist/utilities/process/process.utility.d.ts +8 -0
- package/dist/utilities/process/process.utility.js +8 -0
- package/dist/utilities/process/process.utility.js.map +1 -1
- package/dist/utilities/project-index/project-index.utility.d.ts +27 -0
- package/dist/utilities/project-index/project-index.utility.js +71 -0
- package/dist/utilities/project-index/project-index.utility.js.map +1 -0
- package/dist/utilities/string/string.utility.d.ts +22 -0
- package/dist/utilities/string/string.utility.js +27 -0
- package/dist/utilities/string/string.utility.js.map +1 -1
- package/package.json +11 -8
- package/dist/commands/create-cdk/create-cdk.command.js +0 -70
- package/dist/commands/create-cdk/create-cdk.command.js.map +0 -1
- package/dist/commands/create-cdk/generator-octo-cdk-template/generators/app/index.d.ts +0 -10
- package/dist/commands/create-cdk/generator-octo-cdk-template/generators/app/index.js +0 -107
- package/dist/commands/create-cdk/generator-octo-cdk-template/generators/app/index.js.map +0 -1
- package/dist/commands/create-cdk/generator-octo-cdk-template/generators/app/templates/README.md.ejs +0 -23
- package/dist/commands/create-cdk/generator-octo-cdk-template/generators/app/templates/eslint.config.js.ejs +0 -337
- package/dist/commands/create-cdk/generator-octo-cdk-template/generators/app/templates/gitignore.ejs +0 -82
- package/dist/commands/create-cdk/generator-octo-cdk-template/generators/app/templates/gitkeep.ejs +0 -0
- package/dist/commands/create-cdk/generator-octo-cdk-template/generators/app/templates/package.json.ejs +0 -57
- package/dist/commands/create-cdk/generator-octo-cdk-template/generators/app/templates/prettierrc.ejs +0 -5
- package/dist/commands/create-cdk/generator-octo-cdk-template/generators/app/templates/src/anchors/app/app.anchor.schema.ts.ejs +0 -19
- package/dist/commands/create-cdk/generator-octo-cdk-template/generators/app/templates/src/anchors/app/app.anchor.ts.ejs +0 -17
- package/dist/commands/create-cdk/generator-octo-cdk-template/generators/app/templates/src/factories/dummy-credentials.factory.ts.ejs +0 -28
- package/dist/commands/create-cdk/generator-octo-cdk-template/generators/app/templates/src/modules/app/dummy-app/dummy-app.module.spec.ts.ejs +0 -90
- package/dist/commands/create-cdk/generator-octo-cdk-template/generators/app/templates/src/modules/app/dummy-app/dummy-app.module.ts.ejs +0 -16
- package/dist/commands/create-cdk/generator-octo-cdk-template/generators/app/templates/src/modules/app/dummy-app/index.schema.ts.ejs +0 -10
- package/dist/commands/create-cdk/generator-octo-cdk-template/generators/app/templates/src/modules/app/dummy-app/index.ts.ejs +0 -3
- package/dist/commands/create-cdk/generator-octo-cdk-template/generators/app/templates/src/modules/app/dummy-app/models/app/actions/add-dummy-app.model.action.ts.ejs +0 -59
- package/dist/commands/create-cdk/generator-octo-cdk-template/generators/app/templates/src/modules/app/dummy-app/models/app/index.ts.ejs +0 -1
- package/dist/commands/create-cdk/generator-octo-cdk-template/generators/app/templates/src/resources/http-fetch/actions/add-http-fetch.resource.action.ts.ejs +0 -55
- package/dist/commands/create-cdk/generator-octo-cdk-template/generators/app/templates/src/resources/http-fetch/http-fetch.resource.ts.ejs +0 -12
- package/dist/commands/create-cdk/generator-octo-cdk-template/generators/app/templates/src/resources/http-fetch/index.schema.ts.ejs +0 -35
- package/dist/commands/create-cdk/generator-octo-cdk-template/generators/app/templates/src/resources/http-fetch/index.ts.ejs +0 -3
- package/dist/commands/create-cdk/generator-octo-cdk-template/generators/app/templates/src/utilities/dummy/dummy.utility.ts.ejs +0 -11
- package/dist/commands/create-cdk/generator-octo-cdk-template/generators/app/templates/tsconfig.build.json.ejs +0 -11
- package/dist/commands/create-cdk/generator-octo-cdk-template/generators/app/templates/tsconfig.json.ejs +0 -39
- package/dist/commands/create-cdk/index.d.ts +0 -1
- package/dist/commands/create-cdk/index.js +0 -2
- package/dist/commands/create-cdk/index.js.map +0 -1
- package/dist/commands/create-resource/create-resource.command.js.map +0 -1
- package/dist/commands/create-resource/generator-octo-resource-template/generators/app/index.js.map +0 -1
- package/dist/commands/create-resource/generator-octo-resource-template/generators/app/templates/resources/resource/actions/update-tags.resource.action.ts.ejs +0 -86
- package/dist/commands/create-resource/generator-octo-resource-template/generators/app/templates/resources/resource/actions/validate.resource.action.ts.ejs +0 -40
- package/dist/commands/create-resource/generator-octo-resource-template/generators/app/templates/resources/resource/resource.ts.ejs +0 -12
- package/dist/commands/create-resource/index.d.ts +0 -1
- package/dist/commands/create-resource/index.js +0 -2
- package/dist/commands/create-resource/index.js.map +0 -1
- package/dist/commands/run/index.d.ts +0 -1
- package/dist/commands/run/index.js +0 -2
- package/dist/commands/run/index.js.map +0 -1
- package/dist/commands/run/run.command.d.ts +0 -11
- package/dist/commands/run/run.command.js +0 -96
- package/dist/commands/run/run.command.js.map +0 -1
- package/dist/commands/state/index.d.ts +0 -1
- package/dist/commands/state/index.js +0 -2
- package/dist/commands/state/index.js.map +0 -1
- package/dist/commands/state/state.command.d.ts +0 -14
- package/dist/commands/state/state.command.js +0 -79
- package/dist/commands/state/state.command.js.map +0 -1
- /package/dist/commands/{create-resource/generator-octo-resource-template → create-external-resource/generator-octo-external-resource-template}/generators/app/templates/resources/resource/index.schema.ts.ejs +0 -0
|
@@ -1,107 +0,0 @@
|
|
|
1
|
-
import { readdir, stat } from 'fs/promises';
|
|
2
|
-
import { join, resolve } from 'path';
|
|
3
|
-
import Generator, {} from 'yeoman-generator';
|
|
4
|
-
export default class extends Generator {
|
|
5
|
-
constructor(args, opts) {
|
|
6
|
-
super(args, opts);
|
|
7
|
-
this.cdkName = args[0];
|
|
8
|
-
this.cdkPath = args[1];
|
|
9
|
-
this.cdkOptions = {
|
|
10
|
-
withExamples: args[2] === 'true',
|
|
11
|
-
};
|
|
12
|
-
}
|
|
13
|
-
async initializing() {
|
|
14
|
-
const targetPath = resolve(join(this.cdkPath, this.cdkName));
|
|
15
|
-
// Check if directory already exists and is not empty.
|
|
16
|
-
let targetPathStat;
|
|
17
|
-
try {
|
|
18
|
-
targetPathStat = await stat(targetPath);
|
|
19
|
-
}
|
|
20
|
-
catch (error) {
|
|
21
|
-
if (error.code !== 'ENOENT') {
|
|
22
|
-
throw error;
|
|
23
|
-
}
|
|
24
|
-
}
|
|
25
|
-
if (targetPathStat?.isDirectory()) {
|
|
26
|
-
const files = await readdir(targetPath);
|
|
27
|
-
if (files.length > 0) {
|
|
28
|
-
throw new Error(`Directory '${targetPath}' already exists and is not empty! Please choose a different name or path.`);
|
|
29
|
-
}
|
|
30
|
-
}
|
|
31
|
-
// Set the destination root to the cdk directory.
|
|
32
|
-
this.destinationRoot(targetPath);
|
|
33
|
-
}
|
|
34
|
-
async writing() {
|
|
35
|
-
// Create eslint.config.js (ESLint v9 flat config)
|
|
36
|
-
this.fs.copyTpl(this.templatePath('eslint.config.js.ejs'), this.destinationPath('eslint.config.js'));
|
|
37
|
-
// Create .gitignore
|
|
38
|
-
this.fs.copyTpl(this.templatePath('gitignore.ejs'), this.destinationPath('.gitignore'));
|
|
39
|
-
// Create package.json
|
|
40
|
-
this.fs.copyTpl(this.templatePath('package.json.ejs'), this.destinationPath('package.json'), {
|
|
41
|
-
description: `Infrastructure CDK using Octo for ${this.cdkName}`,
|
|
42
|
-
name: this.cdkName,
|
|
43
|
-
version: '0.0.1',
|
|
44
|
-
});
|
|
45
|
-
await this.addDependencies({
|
|
46
|
-
'@quadnix/octo': '0.0.x',
|
|
47
|
-
});
|
|
48
|
-
await this.addDevDependencies({
|
|
49
|
-
'@eslint/js': '^9.33.0',
|
|
50
|
-
'@types/jest': '^30.0.0',
|
|
51
|
-
'@types/node': '^24.3.0',
|
|
52
|
-
'@typescript-eslint/eslint-plugin': '^8.39.1',
|
|
53
|
-
'@typescript-eslint/parser': '^8.39.1',
|
|
54
|
-
dpdm: '^3.14.0',
|
|
55
|
-
eslint: '^9.33.0',
|
|
56
|
-
'eslint-config-prettier': '^10.1.8',
|
|
57
|
-
'eslint-import-resolver-typescript': '^4.4.4',
|
|
58
|
-
'eslint-plugin-boundaries': '^5.0.1',
|
|
59
|
-
'eslint-plugin-import': '^2.32.0',
|
|
60
|
-
'eslint-plugin-jsonc': '^2.20.1',
|
|
61
|
-
'eslint-plugin-prettier': '^5.5.4',
|
|
62
|
-
globals: '^16.3.0',
|
|
63
|
-
jest: '^30.0.5',
|
|
64
|
-
prettier: '^3.6.2',
|
|
65
|
-
rimraf: '^6.0.1',
|
|
66
|
-
'source-map-support': '^0.5.21',
|
|
67
|
-
'ts-jest': '^29.4.1',
|
|
68
|
-
'ts-loader': '^9.5.2',
|
|
69
|
-
'ts-node': '^10.9.2',
|
|
70
|
-
'tsconfig-paths': '^4.2.0',
|
|
71
|
-
typescript: '^5.9.2',
|
|
72
|
-
});
|
|
73
|
-
// Create .prettierrc
|
|
74
|
-
this.fs.copyTpl(this.templatePath('prettierrc.ejs'), this.destinationPath('.prettierrc'));
|
|
75
|
-
// Create README.md
|
|
76
|
-
this.fs.copyTpl(this.templatePath('README.md.ejs'), this.destinationPath('README.md'), {
|
|
77
|
-
description: `Infrastructure CDK using Octo for ${this.cdkName}`,
|
|
78
|
-
name: this.cdkName,
|
|
79
|
-
});
|
|
80
|
-
// Create tsconfig.json and tsconfig.build.json
|
|
81
|
-
this.fs.copyTpl(this.templatePath('tsconfig.json.ejs'), this.destinationPath('tsconfig.json'));
|
|
82
|
-
this.fs.copyTpl(this.templatePath('tsconfig.build.json.ejs'), this.destinationPath('tsconfig.build.json'));
|
|
83
|
-
// Create src directory and main files
|
|
84
|
-
if (this.cdkOptions.withExamples) {
|
|
85
|
-
this.fs.copyTpl(this.templatePath(`src/**/*`), this.destinationPath('src'), {
|
|
86
|
-
name: this.cdkName,
|
|
87
|
-
});
|
|
88
|
-
}
|
|
89
|
-
else {
|
|
90
|
-
this.fs.copyTpl(this.templatePath(`gitkeep.ejs`), this.destinationPath('src/anchors/.gitkeep'));
|
|
91
|
-
this.fs.copyTpl(this.templatePath(`gitkeep.ejs`), this.destinationPath('src/factories/.gitkeep'));
|
|
92
|
-
this.fs.copyTpl(this.templatePath(`gitkeep.ejs`), this.destinationPath('src/modules/.gitkeep'));
|
|
93
|
-
this.fs.copyTpl(this.templatePath(`gitkeep.ejs`), this.destinationPath('src/resources/.gitkeep'));
|
|
94
|
-
this.fs.copyTpl(this.templatePath(`gitkeep.ejs`), this.destinationPath('src/utilities/.gitkeep'));
|
|
95
|
-
}
|
|
96
|
-
}
|
|
97
|
-
end() {
|
|
98
|
-
const targetPath = resolve(join(this.cdkPath, this.cdkName));
|
|
99
|
-
this.log('✅ Your TypeScript CDK has been generated successfully!');
|
|
100
|
-
this.log(`📁 CDK created at: ${targetPath}`);
|
|
101
|
-
this.log('📦 Next steps:');
|
|
102
|
-
this.log(` cd ${targetPath}`);
|
|
103
|
-
this.log(' npm install');
|
|
104
|
-
this.log(' npm run build');
|
|
105
|
-
}
|
|
106
|
-
}
|
|
107
|
-
//# sourceMappingURL=index.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../../src/commands/create-cdk/generator-octo-cdk-template/generators/app/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,MA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AC,eAAe,CAAC,wBAAwB,CAAC,CAAC,CAAC;YAClG,IAAI,CAAC,EAAE,CAAC,OAAO,CAAC,IAAI,CAAC,YAAY,CAAC,aAAa,CAAC,EAAE,IAAI,CAAC,eAAe,CAAC,sBAAsB,CAAC,CAAC,CAAC;YAChG,IAAI,CAAC,EAAE,CAAC,OAAO,CAAC,IAAI,CAAC,YAAY,CAAC,aAAa,CAAC,EAAE,IAAI,CAAC,eAAe,CAAC,wBAAwB,CAAC,CAAC,CAAC;YAClG,IAAI,CAAC,EAAE,CAAC,OAAO,CAAC,IAAI,CAAC,YAAY,CAAC,aAAa,CAAC,EAAE,IAAI,CAAC,eAAe,CAAC,wBAAwB,CAAC,CAAC,CAAC;QACpG,CAAC;IACH,CAAC;IAED,GAAG;QACD,MAAM,UAAU,GAAG,OAAO,CAAC,IAAI,CAAC,IAAI,CAAC,OAAO,EAAE,IAAI,CAAC,OAAO,CAAC,CAAC,CAAC;QAE7D,IAAI,CAAC,GAAG,CAAC,wDAAwD,CAAC,CAAC;QACnE,IAAI,CAAC,GAAG,CAAC,sBAAsB,UAAU,EAAE,CAAC,CAAC;QAC7C,IAAI,CAAC,GAAG,CAAC,gBAAgB,CAAC,CAAC;QAC3B,IAAI,CAAC,GAAG,CAAC,SAAS,UAAU,EAAE,CAAC,CAAC;QAChC,IAAI,CAAC,GAAG,CAAC,gBAAgB,CAAC,CAAC;QAC3B,IAAI,CAAC,GAAG,CAAC,kBAAkB,CAAC,CAAC;IAC/B,CAAC;CACF"}
|
package/dist/commands/create-cdk/generator-octo-cdk-template/generators/app/templates/README.md.ejs
DELETED
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
# <%= name %>
|
|
2
|
-
<%= description %>
|
|
3
|
-
|
|
4
|
-
## Octo Documentation
|
|
5
|
-
[Official Docs](http://octo.quadnix.com/)
|
|
6
|
-
|
|
7
|
-
## Installation
|
|
8
|
-
```bash
|
|
9
|
-
npm install
|
|
10
|
-
```
|
|
11
|
-
|
|
12
|
-
## Development
|
|
13
|
-
We have provided a few dummy implementation examples in the `src` directory to help you get started with Octo.
|
|
14
|
-
Feel free to replace them with your own implementation.
|
|
15
|
-
|
|
16
|
-
Once you are happy with your implementation and tests,
|
|
17
|
-
```bash
|
|
18
|
-
# Build app. This will compile your TypeScript code.
|
|
19
|
-
npm run build
|
|
20
|
-
|
|
21
|
-
# Test app.
|
|
22
|
-
npm run test
|
|
23
|
-
```
|
|
@@ -1,337 +0,0 @@
|
|
|
1
|
-
import { dirname } from 'path';
|
|
2
|
-
import { fileURLToPath } from 'url';
|
|
3
|
-
|
|
4
|
-
import js from '@eslint/js';
|
|
5
|
-
import tseslint from '@typescript-eslint/eslint-plugin';
|
|
6
|
-
import tsparser from '@typescript-eslint/parser';
|
|
7
|
-
import prettierConfig from 'eslint-config-prettier';
|
|
8
|
-
import boundaries from 'eslint-plugin-boundaries';
|
|
9
|
-
import importPlugin from 'eslint-plugin-import';
|
|
10
|
-
import jsonc from 'eslint-plugin-jsonc';
|
|
11
|
-
import prettier from 'eslint-plugin-prettier';
|
|
12
|
-
import globals from 'globals';
|
|
13
|
-
|
|
14
|
-
const __dirname = dirname(fileURLToPath(import.meta.url));
|
|
15
|
-
|
|
16
|
-
export default [
|
|
17
|
-
// Base JavaScript config
|
|
18
|
-
js.configs.recommended,
|
|
19
|
-
|
|
20
|
-
// All files.
|
|
21
|
-
{
|
|
22
|
-
files: ['**/*.{js,cjs,ts,tsx}'],
|
|
23
|
-
languageOptions: {
|
|
24
|
-
globals: {
|
|
25
|
-
...globals.node,
|
|
26
|
-
...globals.jest,
|
|
27
|
-
NodeJS: true,
|
|
28
|
-
},
|
|
29
|
-
},
|
|
30
|
-
plugins: {
|
|
31
|
-
import: importPlugin,
|
|
32
|
-
},
|
|
33
|
-
rules: {
|
|
34
|
-
'import/no-duplicates': 'error',
|
|
35
|
-
'import/no-unresolved': 'error',
|
|
36
|
-
'import/order': [
|
|
37
|
-
'error',
|
|
38
|
-
{
|
|
39
|
-
alphabetize: { caseInsensitive: false, order: 'asc', orderImportKind: 'asc' },
|
|
40
|
-
named: { enabled: true, types: 'mixed' },
|
|
41
|
-
},
|
|
42
|
-
],
|
|
43
|
-
'max-len': ['error', { code: 120, ignoreStrings: true }],
|
|
44
|
-
'no-async-promise-executor': 'off',
|
|
45
|
-
'no-duplicate-imports': ['error', { includeExports: true }],
|
|
46
|
-
'no-unused-vars': 'off',
|
|
47
|
-
'sort-imports': [
|
|
48
|
-
'error',
|
|
49
|
-
{
|
|
50
|
-
allowSeparatedGroups: true,
|
|
51
|
-
ignoreCase: false,
|
|
52
|
-
ignoreDeclarationSort: true,
|
|
53
|
-
ignoreMemberSort: false,
|
|
54
|
-
memberSyntaxSortOrder: ['none', 'all', 'multiple', 'single'],
|
|
55
|
-
},
|
|
56
|
-
],
|
|
57
|
-
'sort-keys': ['error', 'asc', { caseSensitive: false, minKeys: 2, natural: false }],
|
|
58
|
-
},
|
|
59
|
-
settings: {
|
|
60
|
-
'import/resolver': {
|
|
61
|
-
node: {
|
|
62
|
-
extensions: ['.js', '.jsx', '.ts', '.tsx'],
|
|
63
|
-
},
|
|
64
|
-
typescript: {
|
|
65
|
-
alwaysTryTypes: true,
|
|
66
|
-
project: './tsconfig.json',
|
|
67
|
-
},
|
|
68
|
-
},
|
|
69
|
-
},
|
|
70
|
-
},
|
|
71
|
-
|
|
72
|
-
// TypeScript files.
|
|
73
|
-
{
|
|
74
|
-
files: ['**/*.{ts,tsx}'],
|
|
75
|
-
languageOptions: {
|
|
76
|
-
parser: tsparser,
|
|
77
|
-
parserOptions: {
|
|
78
|
-
ecmaVersion: 2022,
|
|
79
|
-
project: './tsconfig.json',
|
|
80
|
-
sourceType: 'module',
|
|
81
|
-
tsconfigRootDir: __dirname,
|
|
82
|
-
},
|
|
83
|
-
},
|
|
84
|
-
plugins: {
|
|
85
|
-
'@typescript-eslint': tseslint,
|
|
86
|
-
boundaries: boundaries,
|
|
87
|
-
import: importPlugin,
|
|
88
|
-
prettier,
|
|
89
|
-
},
|
|
90
|
-
rules: {
|
|
91
|
-
'@typescript-eslint/consistent-type-imports': ['error', { fixStyle: 'inline-type-imports' }],
|
|
92
|
-
'@typescript-eslint/explicit-function-return-type': 'error',
|
|
93
|
-
'@typescript-eslint/explicit-module-boundary-types': 'off',
|
|
94
|
-
'@typescript-eslint/interface-name-prefix': 'off',
|
|
95
|
-
'@typescript-eslint/no-explicit-any': 'off',
|
|
96
|
-
'@typescript-eslint/no-non-null-assertion': 'off',
|
|
97
|
-
'@typescript-eslint/no-this-alias': 'error',
|
|
98
|
-
'@typescript-eslint/no-unused-vars': 'off',
|
|
99
|
-
'@typescript-eslint/prefer-nullish-coalescing': 'off',
|
|
100
|
-
'@typescript-eslint/prefer-optional-chain': 'error',
|
|
101
|
-
'boundaries/element-types': [
|
|
102
|
-
'error',
|
|
103
|
-
{
|
|
104
|
-
default: 'disallow',
|
|
105
|
-
rules: [
|
|
106
|
-
// Anchor rules.
|
|
107
|
-
{
|
|
108
|
-
allow: [['anchor-schema', { family: '${from.family}' }], 'utilities'],
|
|
109
|
-
from: ['anchor-anchor'],
|
|
110
|
-
},
|
|
111
|
-
{
|
|
112
|
-
allow: [],
|
|
113
|
-
from: ['anchor-schema'],
|
|
114
|
-
},
|
|
115
|
-
|
|
116
|
-
// Module rules.
|
|
117
|
-
{
|
|
118
|
-
allow: [
|
|
119
|
-
['module-models', { family: '${from.family}' }],
|
|
120
|
-
['module-module', { family: '${from.family}' }],
|
|
121
|
-
'anchor-anchor',
|
|
122
|
-
'anchor-schema',
|
|
123
|
-
'resource-index',
|
|
124
|
-
'resource-schema-index',
|
|
125
|
-
'utilities',
|
|
126
|
-
],
|
|
127
|
-
from: ['module-model-actions'],
|
|
128
|
-
},
|
|
129
|
-
{
|
|
130
|
-
allow: [
|
|
131
|
-
['module-model-actions', { family: '${from.family}' }],
|
|
132
|
-
['module-models', { family: '${from.family}' }],
|
|
133
|
-
],
|
|
134
|
-
from: ['module-model-indexes'],
|
|
135
|
-
},
|
|
136
|
-
{
|
|
137
|
-
allow: ['resource-schema-index'],
|
|
138
|
-
from: ['module-model-schemas'],
|
|
139
|
-
},
|
|
140
|
-
{
|
|
141
|
-
allow: [
|
|
142
|
-
['module-model-schemas', { family: '${from.family}' }],
|
|
143
|
-
'anchor-anchor',
|
|
144
|
-
'anchor-schema',
|
|
145
|
-
'utilities',
|
|
146
|
-
],
|
|
147
|
-
from: ['module-models'],
|
|
148
|
-
},
|
|
149
|
-
{
|
|
150
|
-
allow: [
|
|
151
|
-
['module-model-actions', { family: '${from.family}' }],
|
|
152
|
-
['module-model-indexes', { family: '${from.family}' }],
|
|
153
|
-
['module-schema-index', { family: '${from.family}' }],
|
|
154
|
-
'anchor-anchor',
|
|
155
|
-
'anchor-schema',
|
|
156
|
-
'utilities',
|
|
157
|
-
],
|
|
158
|
-
from: ['module-module'],
|
|
159
|
-
},
|
|
160
|
-
{
|
|
161
|
-
allow: [
|
|
162
|
-
['module-index', { family: '${from.family}' }],
|
|
163
|
-
['module-schema-index', { family: '${from.family}' }],
|
|
164
|
-
'anchor-schema',
|
|
165
|
-
'resource-schema-index',
|
|
166
|
-
'module-schema-index',
|
|
167
|
-
'utilities',
|
|
168
|
-
],
|
|
169
|
-
from: ['module-spec'],
|
|
170
|
-
},
|
|
171
|
-
{
|
|
172
|
-
allow: [
|
|
173
|
-
['module-model-indexes', { family: '${from.family}' }],
|
|
174
|
-
['module-module', { family: '${from.family}' }],
|
|
175
|
-
],
|
|
176
|
-
from: ['module-index'],
|
|
177
|
-
},
|
|
178
|
-
{
|
|
179
|
-
allow: [
|
|
180
|
-
['module-model-indexes', { family: '${from.family}' }],
|
|
181
|
-
['module-model-schemas', { family: '${from.family}' }],
|
|
182
|
-
'anchor-schema',
|
|
183
|
-
'resource-schema-index',
|
|
184
|
-
],
|
|
185
|
-
from: ['module-schema-index'],
|
|
186
|
-
},
|
|
187
|
-
|
|
188
|
-
// Resource rules.
|
|
189
|
-
{
|
|
190
|
-
allow: [
|
|
191
|
-
['resource-resource', { family: '${from.family}' }],
|
|
192
|
-
['resource-schema-index', { family: '${from.family}' }],
|
|
193
|
-
'resource-schema-index',
|
|
194
|
-
'utilities',
|
|
195
|
-
],
|
|
196
|
-
from: ['resource-actions'],
|
|
197
|
-
},
|
|
198
|
-
{
|
|
199
|
-
allow: [['resource-schema-index', { family: '${from.family}' }], 'resource-schema-index', 'utilities'],
|
|
200
|
-
from: ['resource-resource'],
|
|
201
|
-
},
|
|
202
|
-
{
|
|
203
|
-
allow: [
|
|
204
|
-
['resource-actions', { family: '${from.family}' }],
|
|
205
|
-
['resource-resource', { family: '${from.family}' }],
|
|
206
|
-
],
|
|
207
|
-
from: ['resource-index'],
|
|
208
|
-
},
|
|
209
|
-
{
|
|
210
|
-
allow: [],
|
|
211
|
-
from: ['resource-schema-index'],
|
|
212
|
-
},
|
|
213
|
-
|
|
214
|
-
// Utility rules.
|
|
215
|
-
{
|
|
216
|
-
allow: ['resource-schema-index'],
|
|
217
|
-
from: ['utilities'],
|
|
218
|
-
},
|
|
219
|
-
],
|
|
220
|
-
},
|
|
221
|
-
],
|
|
222
|
-
'boundaries/external': ['off'],
|
|
223
|
-
},
|
|
224
|
-
settings: {
|
|
225
|
-
'boundaries/dependency-nodes': ['export', 'import'],
|
|
226
|
-
'boundaries/elements': [
|
|
227
|
-
// Anchor patterns.
|
|
228
|
-
{
|
|
229
|
-
capture: ['family'],
|
|
230
|
-
mode: 'file',
|
|
231
|
-
pattern: 'src/anchors/*/*.anchor.ts',
|
|
232
|
-
type: `anchor-anchor`,
|
|
233
|
-
},
|
|
234
|
-
{
|
|
235
|
-
capture: ['family'],
|
|
236
|
-
mode: 'file',
|
|
237
|
-
pattern: 'src/anchors/*/*.anchor.schema.ts',
|
|
238
|
-
type: `anchor-schema`,
|
|
239
|
-
},
|
|
240
|
-
|
|
241
|
-
// Module patterns.
|
|
242
|
-
{
|
|
243
|
-
capture: ['familyCategory', 'family'],
|
|
244
|
-
mode: 'file',
|
|
245
|
-
pattern: ['src/modules/*/*/**/*.action.ts'],
|
|
246
|
-
type: 'module-model-actions',
|
|
247
|
-
},
|
|
248
|
-
{
|
|
249
|
-
capture: ['familyCategory', 'family'],
|
|
250
|
-
mode: 'file',
|
|
251
|
-
pattern: ['src/modules/*/*/models/*/index.ts', 'src/modules/*/*/overlays/*/index.ts'],
|
|
252
|
-
type: 'module-model-indexes',
|
|
253
|
-
},
|
|
254
|
-
{
|
|
255
|
-
capture: ['familyCategory', 'family'],
|
|
256
|
-
mode: 'file',
|
|
257
|
-
pattern: ['src/modules/*/*/models/*/*.schema.ts', 'src/modules/*/*/overlays/*/*.schema.ts'],
|
|
258
|
-
type: 'module-model-schemas',
|
|
259
|
-
},
|
|
260
|
-
{
|
|
261
|
-
capture: ['familyCategory', 'family'],
|
|
262
|
-
mode: 'file',
|
|
263
|
-
pattern: ['src/modules/*/*/models/*/*.model.ts', 'src/modules/*/*/overlays/*/*.overlay.ts'],
|
|
264
|
-
type: 'module-models',
|
|
265
|
-
},
|
|
266
|
-
{
|
|
267
|
-
capture: ['familyCategory', 'family'],
|
|
268
|
-
mode: 'file',
|
|
269
|
-
pattern: 'src/modules/*/*/*.module.ts',
|
|
270
|
-
type: 'module-module',
|
|
271
|
-
},
|
|
272
|
-
{
|
|
273
|
-
capture: ['familyCategory', 'family'],
|
|
274
|
-
mode: 'file',
|
|
275
|
-
pattern: 'src/modules/*/*/*.module.spec.ts',
|
|
276
|
-
type: 'module-spec',
|
|
277
|
-
},
|
|
278
|
-
{
|
|
279
|
-
capture: ['familyCategory', 'family'],
|
|
280
|
-
mode: 'file',
|
|
281
|
-
pattern: 'src/modules/*/*/index.ts',
|
|
282
|
-
type: 'module-index',
|
|
283
|
-
},
|
|
284
|
-
{
|
|
285
|
-
capture: ['familyCategory', 'family'],
|
|
286
|
-
mode: 'file',
|
|
287
|
-
pattern: 'src/modules/*/*/index.schema.ts',
|
|
288
|
-
type: 'module-schema-index',
|
|
289
|
-
},
|
|
290
|
-
|
|
291
|
-
// Resource patterns.
|
|
292
|
-
{
|
|
293
|
-
capture: ['family'],
|
|
294
|
-
mode: 'folder',
|
|
295
|
-
pattern: 'src/resources/*/actions',
|
|
296
|
-
type: `resource-actions`,
|
|
297
|
-
},
|
|
298
|
-
{
|
|
299
|
-
capture: ['family'],
|
|
300
|
-
mode: 'file',
|
|
301
|
-
pattern: 'src/resources/*/*.resource.ts',
|
|
302
|
-
type: `resource-resource`,
|
|
303
|
-
},
|
|
304
|
-
{ capture: ['family'], mode: 'file', pattern: 'src/resources/*/index.ts', type: `resource-index` },
|
|
305
|
-
{
|
|
306
|
-
capture: ['family'],
|
|
307
|
-
mode: 'file',
|
|
308
|
-
pattern: 'src/resources/*/index.schema.ts',
|
|
309
|
-
type: `resource-schema-index`,
|
|
310
|
-
},
|
|
311
|
-
|
|
312
|
-
// Utility patterns.
|
|
313
|
-
{
|
|
314
|
-
pattern: 'src/utilities',
|
|
315
|
-
type: 'utilities',
|
|
316
|
-
},
|
|
317
|
-
],
|
|
318
|
-
},
|
|
319
|
-
},
|
|
320
|
-
|
|
321
|
-
// JSON files.
|
|
322
|
-
...jsonc.configs['flat/recommended-with-jsonc'],
|
|
323
|
-
{
|
|
324
|
-
files: ['**/*.json', '**/*.jsonc'],
|
|
325
|
-
rules: {
|
|
326
|
-
'jsonc/sort-keys': ['error', 'asc', { caseSensitive: false, minKeys: 2, natural: false }],
|
|
327
|
-
},
|
|
328
|
-
},
|
|
329
|
-
|
|
330
|
-
// Prettier integration.
|
|
331
|
-
prettierConfig,
|
|
332
|
-
|
|
333
|
-
// Global ignores.
|
|
334
|
-
{
|
|
335
|
-
ignores: ['package-lock.json', '.idea', 'coverage', 'dist', 'node_modules'],
|
|
336
|
-
},
|
|
337
|
-
];
|
package/dist/commands/create-cdk/generator-octo-cdk-template/generators/app/templates/gitignore.ejs
DELETED
|
@@ -1,82 +0,0 @@
|
|
|
1
|
-
# Dependencies
|
|
2
|
-
node_modules/
|
|
3
|
-
npm-debug.log*
|
|
4
|
-
yarn-debug.log*
|
|
5
|
-
yarn-error.log*
|
|
6
|
-
pnpm-debug.log*
|
|
7
|
-
|
|
8
|
-
# Build outputs
|
|
9
|
-
dist/
|
|
10
|
-
build/
|
|
11
|
-
*.tsbuildinfo
|
|
12
|
-
|
|
13
|
-
# Environment variables
|
|
14
|
-
.env
|
|
15
|
-
.env.local
|
|
16
|
-
.env.development.local
|
|
17
|
-
.env.test.local
|
|
18
|
-
.env.production.local
|
|
19
|
-
|
|
20
|
-
# IDE
|
|
21
|
-
.vscode/
|
|
22
|
-
.idea/
|
|
23
|
-
*.swp
|
|
24
|
-
*.swo
|
|
25
|
-
*~
|
|
26
|
-
|
|
27
|
-
# OS
|
|
28
|
-
.DS_Store
|
|
29
|
-
Thumbs.db
|
|
30
|
-
|
|
31
|
-
# Logs
|
|
32
|
-
logs
|
|
33
|
-
*.log
|
|
34
|
-
|
|
35
|
-
# Coverage
|
|
36
|
-
coverage/
|
|
37
|
-
.nyc_output/
|
|
38
|
-
|
|
39
|
-
# Runtime data
|
|
40
|
-
pids
|
|
41
|
-
*.pid
|
|
42
|
-
*.seed
|
|
43
|
-
*.pid.lock
|
|
44
|
-
|
|
45
|
-
# Optional npm cache directory
|
|
46
|
-
.npm
|
|
47
|
-
|
|
48
|
-
# Optional eslint cache
|
|
49
|
-
.eslintcache
|
|
50
|
-
|
|
51
|
-
# Microbundle cache
|
|
52
|
-
.rpt2_cache/
|
|
53
|
-
.rts2_cache_cjs/
|
|
54
|
-
.rts2_cache_es/
|
|
55
|
-
.rts2_cache_umd/
|
|
56
|
-
|
|
57
|
-
# Optional REPL history
|
|
58
|
-
.node_repl_history
|
|
59
|
-
|
|
60
|
-
# Output of 'npm pack'
|
|
61
|
-
*.tgz
|
|
62
|
-
|
|
63
|
-
# Yarn Integrity file
|
|
64
|
-
.yarn-integrity
|
|
65
|
-
|
|
66
|
-
# parcel-bundler cache (https://parceljs.org/)
|
|
67
|
-
.cache
|
|
68
|
-
.parcel-cache
|
|
69
|
-
|
|
70
|
-
# Next.js build output
|
|
71
|
-
.next
|
|
72
|
-
|
|
73
|
-
# Nuxt.js build / generate output
|
|
74
|
-
.nuxt
|
|
75
|
-
|
|
76
|
-
# Storybook build outputs
|
|
77
|
-
.out
|
|
78
|
-
.storybook-out
|
|
79
|
-
|
|
80
|
-
# Temporary folders
|
|
81
|
-
tmp/
|
|
82
|
-
temp/
|
package/dist/commands/create-cdk/generator-octo-cdk-template/generators/app/templates/gitkeep.ejs
DELETED
|
File without changes
|
|
@@ -1,57 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"dependencies": {},
|
|
3
|
-
"description": "<%= description %>",
|
|
4
|
-
"devDependencies": {},
|
|
5
|
-
"engines": {
|
|
6
|
-
"node": ">=20.0.0"
|
|
7
|
-
},
|
|
8
|
-
"jest": {
|
|
9
|
-
"coverageDirectory": "./coverage",
|
|
10
|
-
"extensionsToTreatAsEsm": [
|
|
11
|
-
".ts"
|
|
12
|
-
],
|
|
13
|
-
"moduleFileExtensions": [
|
|
14
|
-
"js",
|
|
15
|
-
"json",
|
|
16
|
-
"ts"
|
|
17
|
-
],
|
|
18
|
-
"moduleNameMapper": {
|
|
19
|
-
"(.+)\\.js": "$1"
|
|
20
|
-
},
|
|
21
|
-
"preset": "ts-jest/presets/default-esm",
|
|
22
|
-
"rootDir": ".",
|
|
23
|
-
"testEnvironment": "node",
|
|
24
|
-
"testRegex": ".*spec\\.ts$",
|
|
25
|
-
"transform": {
|
|
26
|
-
"^.+\\.ts$": [
|
|
27
|
-
"ts-jest",
|
|
28
|
-
{
|
|
29
|
-
"useESM": true
|
|
30
|
-
}
|
|
31
|
-
]
|
|
32
|
-
}
|
|
33
|
-
},
|
|
34
|
-
"keywords": [
|
|
35
|
-
"cdk",
|
|
36
|
-
"cicd",
|
|
37
|
-
"infrastructure",
|
|
38
|
-
"octo"
|
|
39
|
-
],
|
|
40
|
-
"main": "./dist/index.js",
|
|
41
|
-
"name": "<%= name %>",
|
|
42
|
-
"private": true,
|
|
43
|
-
"scripts": {
|
|
44
|
-
"build": "rimraf dist && tsc -p tsconfig.build.json",
|
|
45
|
-
"check:circular-dependency": "dpdm --no-tree --exit-code circular:1 --no-warning ./dist/**/*.js",
|
|
46
|
-
"format": "prettier --write \"src/**/*.ts\"",
|
|
47
|
-
"lint": "eslint .",
|
|
48
|
-
"lint:fix": "eslint . --fix",
|
|
49
|
-
"test": "NODE_OPTIONS=--experimental-vm-modules jest --testRegex=\"\\.spec.ts$\"",
|
|
50
|
-
"test:cov": "NODE_OPTIONS=--experimental-vm-modules jest --coverage --testRegex=\"\\.spec.ts$\"",
|
|
51
|
-
"test:e2e": "NODE_OPTIONS=--experimental-vm-modules jest --testRegex=\"\\.e2e-spec.ts$\"",
|
|
52
|
-
"test:integration": "NODE_OPTIONS=--experimental-vm-modules jest --testRegex=\"\\.ispec.ts$\""
|
|
53
|
-
},
|
|
54
|
-
"type": "module",
|
|
55
|
-
"types": "./dist/index.d.ts",
|
|
56
|
-
"version": "<%= version %>"
|
|
57
|
-
}
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
import { App, BaseAnchorSchema, Schema, Validate } from '@quadnix/octo';
|
|
2
|
-
|
|
3
|
-
/**
|
|
4
|
-
* This is an example anchor schema to demonstrate how to create a custom anchor schema.
|
|
5
|
-
* This anchor is for the `App` model, and exposes a `name` property.
|
|
6
|
-
* Validation for the property is also included using the `@Validate` decorator.
|
|
7
|
-
* In this case, the `name` property is required and must be at least 1 character long.
|
|
8
|
-
*/
|
|
9
|
-
export class AppAnchorSchema extends BaseAnchorSchema {
|
|
10
|
-
parentInstance: App;
|
|
11
|
-
|
|
12
|
-
@Validate({
|
|
13
|
-
destruct: (value: AppAnchorSchema['properties']): string[] => [value.name],
|
|
14
|
-
options: { minLength: 1 },
|
|
15
|
-
})
|
|
16
|
-
override properties = Schema<{
|
|
17
|
-
name: string;
|
|
18
|
-
}>();
|
|
19
|
-
}
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
import { AAnchor, Anchor } from '@quadnix/octo';
|
|
2
|
-
import type { AppAnchorSchema } from './app.anchor.schema.js';
|
|
3
|
-
|
|
4
|
-
/**
|
|
5
|
-
* This is an example anchor to demonstrate how to create a custom anchor.
|
|
6
|
-
* It uses the `@Anchor` decorator to create an anchor for the `App` model,
|
|
7
|
-
* and it must extend the `AAnchor` class.
|
|
8
|
-
* The `AppAnchorSchema` type is used to define the properties of the anchor.
|
|
9
|
-
*/
|
|
10
|
-
@Anchor('@<%= name %>')
|
|
11
|
-
export class AppAnchor extends AAnchor<AppAnchorSchema, AppAnchorSchema['parentInstance']> {
|
|
12
|
-
declare properties: AppAnchorSchema['properties'];
|
|
13
|
-
|
|
14
|
-
constructor(anchorId: string, properties: AppAnchorSchema['properties'], parent: AppAnchorSchema['parentInstance']) {
|
|
15
|
-
super(anchorId, properties, parent);
|
|
16
|
-
}
|
|
17
|
-
}
|