├── .eslintignore ├── .eslintrc.js ├── .gitattributes ├── .github ├── FUNDING.yml ├── ISSUE_TEMPLATE │ ├── bug-report.md │ └── feature-request.md └── workflows │ └── greetings.yml ├── .gitignore ├── .husky └── pre-commit ├── .npmignore ├── .prettierignore ├── .prettierrc.json ├── CHANGELOG.md ├── CODE_OF_CONDUCT.md ├── CONTRIBUTING.md ├── LICENSE ├── README.md ├── SECURITY.md ├── babel.config.js ├── condition.ts ├── docusaurus └── kodyfire-docs │ ├── .gitignore │ ├── README.md │ ├── babel.config.js │ ├── blog │ ├── 2019-05-28-first-blog-post.md │ ├── 2019-05-29-long-blog-post.md │ ├── 2021-08-01-mdx-blog-post.mdx │ ├── 2021-08-26-welcome │ │ ├── docusaurus-plushie-banner.jpeg │ │ └── index.md │ └── authors.yml │ ├── docs │ ├── intro.md │ ├── tutorial-basics │ │ ├── _category_.json │ │ ├── congratulations.md │ │ ├── create-a-blog-post.md │ │ ├── create-a-document.md │ │ ├── create-a-page.md │ │ ├── deploy-your-site.md │ │ └── markdown-features.mdx │ └── tutorial-extras │ │ ├── _category_.json │ │ ├── manage-docs-versions.md │ │ └── translate-your-site.md │ ├── docusaurus.config.js │ ├── package.json │ ├── ramdan-mubarak.png │ ├── sidebars.js │ ├── src │ ├── components │ │ ├── HomepageFeatures.js │ │ └── HomepageFeatures.module.css │ ├── css │ │ └── custom.css │ └── pages │ │ ├── index.js │ │ ├── index.module.css │ │ └── markdown-page.md │ └── static │ ├── .nojekyll │ └── img │ ├── docusaurus.png │ ├── favicon.ico │ ├── logo.svg │ ├── tutorial │ ├── docsVersionDropdown.png │ └── localeDropdown.png │ ├── undraw_docusaurus_mountain.svg │ ├── undraw_docusaurus_react.svg │ └── undraw_docusaurus_tree.svg ├── lerna.json ├── package-lock.json ├── package.json ├── packages ├── basic-kodyfire │ ├── .gitignore │ ├── .npmignore │ ├── LICENSE │ ├── build │ │ ├── assets.json │ │ ├── concepts │ │ │ ├── concept.d.ts │ │ │ ├── concept.js │ │ │ ├── concept.js.map │ │ │ ├── engine.d.ts │ │ │ ├── engine.js │ │ │ ├── engine.js.map │ │ │ └── templates │ │ │ │ └── sample.html.template │ │ ├── generator │ │ │ ├── generator.d.ts │ │ │ ├── generator.js │ │ │ ├── generator.js.map │ │ │ ├── index.d.ts │ │ │ ├── index.js │ │ │ └── index.js.map │ │ ├── index.d.ts │ │ ├── index.js │ │ ├── index.js.map │ │ ├── kody.d.ts │ │ ├── kody.js │ │ ├── kody.js.map │ │ ├── parser │ │ │ ├── extractor.d.ts │ │ │ ├── extractor.js │ │ │ ├── extractor.js.map │ │ │ ├── index.d.ts │ │ │ ├── index.js │ │ │ ├── index.js.map │ │ │ ├── loader.d.ts │ │ │ ├── loader.js │ │ │ ├── loader.js.map │ │ │ ├── parser.d.ts │ │ │ ├── parser.js │ │ │ ├── parser.js.map │ │ │ ├── transformer.d.ts │ │ │ ├── transformer.js │ │ │ ├── transformer.js.map │ │ │ └── validator │ │ │ │ ├── index.d.ts │ │ │ │ ├── index.js │ │ │ │ ├── index.js.map │ │ │ │ ├── schema.d.ts │ │ │ │ ├── schema.js │ │ │ │ ├── schema.js.map │ │ │ │ ├── validator.d.ts │ │ │ │ ├── validator.js │ │ │ │ └── validator.js.map │ │ ├── technology.d.ts │ │ ├── technology.js │ │ └── technology.js.map │ ├── package-lock.json │ ├── package.json │ ├── src │ │ ├── assets.json │ │ ├── concepts │ │ │ ├── concept.ts │ │ │ ├── engine.ts │ │ │ └── templates │ │ │ │ └── sample.html.template │ │ ├── generator │ │ │ ├── generator.ts │ │ │ └── index.ts │ │ ├── index.ts │ │ ├── kody.ts │ │ ├── parser │ │ │ ├── extractor.ts │ │ │ ├── index.ts │ │ │ ├── loader.ts │ │ │ ├── parser.ts │ │ │ ├── transformer.ts │ │ │ └── validator │ │ │ │ ├── index.ts │ │ │ │ ├── schema.ts │ │ │ │ └── validator.ts │ │ └── technology.ts │ └── tsconfig.json ├── kodyfire-cli │ ├── .gitattributes │ ├── .gitignore │ ├── .npmignore │ ├── LICENSE │ ├── README.md │ ├── commands │ │ ├── batch │ │ │ ├── index.d.ts │ │ │ ├── index.d.ts.map │ │ │ ├── index.js │ │ │ ├── index.js.map │ │ │ └── index.ts │ │ ├── create │ │ │ ├── data.json │ │ │ ├── index.d.ts │ │ │ ├── index.d.ts.map │ │ │ ├── index.js │ │ │ ├── index.js.map │ │ │ ├── index.ts │ │ │ └── kody │ │ │ │ ├── index.d.ts │ │ │ │ ├── index.d.ts.map │ │ │ │ ├── index.js │ │ │ │ ├── index.js.map │ │ │ │ ├── kody.d.ts │ │ │ │ ├── kody.d.ts.map │ │ │ │ ├── kody.js │ │ │ │ ├── kody.js.map │ │ │ │ └── src │ │ │ │ ├── assets.json │ │ │ │ ├── concepts │ │ │ │ ├── concept.d.ts │ │ │ │ ├── concept.d.ts.map │ │ │ │ ├── concept.js │ │ │ │ ├── concept.js.map │ │ │ │ ├── concept.ts │ │ │ │ ├── engine.d.ts │ │ │ │ ├── engine.d.ts.map │ │ │ │ ├── engine.js │ │ │ │ ├── engine.js.map │ │ │ │ ├── engine.ts │ │ │ │ ├── scaffold.d.ts │ │ │ │ ├── scaffold.d.ts.map │ │ │ │ ├── scaffold.js │ │ │ │ ├── scaffold.js.map │ │ │ │ ├── scaffold.ts │ │ │ │ └── templates │ │ │ │ │ ├── .npmignore │ │ │ │ │ ├── basic │ │ │ │ │ ├── .gitignore.template │ │ │ │ │ ├── .npmignore.template │ │ │ │ │ ├── package.json.template │ │ │ │ │ ├── src │ │ │ │ │ │ ├── assets.json.template │ │ │ │ │ │ ├── concepts │ │ │ │ │ │ │ ├── concept.ts │ │ │ │ │ │ │ ├── engine.ts │ │ │ │ │ │ │ └── templates │ │ │ │ │ │ │ │ └── sample.html.template.template │ │ │ │ │ │ ├── generator │ │ │ │ │ │ │ ├── generator.ts.template │ │ │ │ │ │ │ └── index.ts.template │ │ │ │ │ │ ├── index.ts.template │ │ │ │ │ │ ├── kody.ts.template │ │ │ │ │ │ ├── parser │ │ │ │ │ │ │ ├── extractor.ts │ │ │ │ │ │ │ ├── index.ts │ │ │ │ │ │ │ ├── loader.ts │ │ │ │ │ │ │ ├── parser.ts │ │ │ │ │ │ │ ├── transformer.ts │ │ │ │ │ │ │ └── validator │ │ │ │ │ │ │ │ ├── index.ts │ │ │ │ │ │ │ │ ├── schema.ts │ │ │ │ │ │ │ │ └── validator.ts │ │ │ │ │ │ └── technology.ts.template │ │ │ │ │ └── tsconfig.json │ │ │ │ │ └── simple │ │ │ │ │ ├── .gitignore.template │ │ │ │ │ ├── .npmignore.template │ │ │ │ │ ├── package.json.template │ │ │ │ │ ├── src │ │ │ │ │ ├── assets.json │ │ │ │ │ ├── concept.ts │ │ │ │ │ ├── engine.ts │ │ │ │ │ ├── index.ts │ │ │ │ │ ├── kody.ts │ │ │ │ │ ├── schema.ts │ │ │ │ │ ├── technology.ts │ │ │ │ │ └── templates │ │ │ │ │ │ └── sample.html.template.template │ │ │ │ │ └── tsconfig.json │ │ │ │ ├── generator │ │ │ │ ├── generator.d.ts │ │ │ │ ├── generator.d.ts.map │ │ │ │ ├── generator.js │ │ │ │ ├── generator.js.map │ │ │ │ ├── generator.ts │ │ │ │ ├── index.d.ts │ │ │ │ ├── index.d.ts.map │ │ │ │ ├── index.js │ │ │ │ ├── index.js.map │ │ │ │ └── index.ts │ │ │ │ ├── index.d.ts │ │ │ │ ├── index.d.ts.map │ │ │ │ ├── index.js │ │ │ │ ├── index.js.map │ │ │ │ ├── index.ts │ │ │ │ ├── kody.d.ts │ │ │ │ ├── kody.d.ts.map │ │ │ │ ├── kody.js │ │ │ │ ├── kody.js.map │ │ │ │ ├── kody.ts │ │ │ │ ├── parser │ │ │ │ ├── extractor.d.ts │ │ │ │ ├── extractor.d.ts.map │ │ │ │ ├── extractor.js │ │ │ │ ├── extractor.js.map │ │ │ │ ├── extractor.ts │ │ │ │ ├── index.d.ts │ │ │ │ ├── index.d.ts.map │ │ │ │ ├── index.js │ │ │ │ ├── index.js.map │ │ │ │ ├── index.ts │ │ │ │ ├── loader.d.ts │ │ │ │ ├── loader.d.ts.map │ │ │ │ ├── loader.js │ │ │ │ ├── loader.js.map │ │ │ │ ├── loader.ts │ │ │ │ ├── parser.d.ts │ │ │ │ ├── parser.d.ts.map │ │ │ │ ├── parser.js │ │ │ │ ├── parser.js.map │ │ │ │ ├── parser.ts │ │ │ │ ├── transformer.d.ts │ │ │ │ ├── transformer.d.ts.map │ │ │ │ ├── transformer.js │ │ │ │ ├── transformer.js.map │ │ │ │ ├── transformer.ts │ │ │ │ ├── validator.d.ts │ │ │ │ └── validator │ │ │ │ │ ├── index.d.ts │ │ │ │ │ ├── index.d.ts.map │ │ │ │ │ ├── index.js │ │ │ │ │ ├── index.js.map │ │ │ │ │ ├── index.ts │ │ │ │ │ ├── schema.d.ts │ │ │ │ │ ├── schema.d.ts.map │ │ │ │ │ ├── schema.js │ │ │ │ │ ├── schema.js.map │ │ │ │ │ ├── schema.ts │ │ │ │ │ ├── validator.d.ts │ │ │ │ │ ├── validator.d.ts.map │ │ │ │ │ ├── validator.js │ │ │ │ │ ├── validator.js.map │ │ │ │ │ └── validator.ts │ │ │ │ ├── technology.d.ts │ │ │ │ ├── technology.d.ts.map │ │ │ │ ├── technology.js │ │ │ │ ├── technology.js.map │ │ │ │ └── technology.ts │ │ ├── generate │ │ │ ├── action.d.ts │ │ │ ├── action.d.ts.map │ │ │ ├── action.js │ │ │ ├── action.js.map │ │ │ ├── action.ts │ │ │ ├── helper.d.ts │ │ │ ├── helper.d.ts.map │ │ │ ├── helper.js.map │ │ │ ├── index.d.ts │ │ │ ├── index.d.ts.map │ │ │ ├── index.js │ │ │ ├── index.js.map │ │ │ └── index.ts │ │ ├── import │ │ │ ├── action.d.ts │ │ │ ├── action.d.ts.map │ │ │ ├── action.js │ │ │ ├── action.js.map │ │ │ ├── action.ts │ │ │ ├── index.d.ts │ │ │ ├── index.d.ts.map │ │ │ ├── index.js │ │ │ ├── index.js.map │ │ │ └── index.ts │ │ ├── init │ │ │ ├── action.d.ts │ │ │ ├── action.d.ts.map │ │ │ ├── action.js │ │ │ ├── action.js.map │ │ │ ├── action.ts │ │ │ ├── helper.d.ts │ │ │ ├── helper.d.ts.map │ │ │ ├── helper.js.map │ │ │ ├── index.d.ts │ │ │ ├── index.d.ts.map │ │ │ ├── index.js │ │ │ ├── index.js.map │ │ │ └── index.ts │ │ ├── install │ │ │ ├── action.d.ts │ │ │ ├── action.d.ts.map │ │ │ ├── action.js │ │ │ ├── action.js.map │ │ │ ├── action.ts │ │ │ ├── helper.d.ts │ │ │ ├── helper.d.ts.map │ │ │ ├── helper.js.map │ │ │ ├── index.d.ts │ │ │ ├── index.d.ts.map │ │ │ ├── index.js │ │ │ ├── index.js.map │ │ │ └── index.ts │ │ ├── list │ │ │ ├── action.d.ts │ │ │ ├── action.d.ts.map │ │ │ ├── action.js │ │ │ ├── action.js.map │ │ │ ├── action.ts │ │ │ ├── index.d.ts │ │ │ ├── index.d.ts.map │ │ │ ├── index.js │ │ │ ├── index.js.map │ │ │ └── index.ts │ │ ├── prompt │ │ │ ├── action.d.ts │ │ │ ├── action.d.ts.map │ │ │ ├── action.js │ │ │ ├── action.js.map │ │ │ ├── action.ts │ │ │ ├── helper.d.ts │ │ │ ├── helper.d.ts.map │ │ │ ├── helper.js.map │ │ │ ├── index.d.ts │ │ │ ├── index.d.ts.map │ │ │ ├── index.js │ │ │ ├── index.js.map │ │ │ └── index.ts │ │ ├── publish │ │ │ ├── index.d.ts │ │ │ ├── index.d.ts.map │ │ │ ├── index.js │ │ │ ├── index.js.map │ │ │ └── index.ts │ │ ├── ride │ │ │ ├── action.d.ts │ │ │ ├── action.d.ts.map │ │ │ ├── action.js │ │ │ ├── action.js.map │ │ │ ├── action.ts │ │ │ ├── helper.d.ts │ │ │ ├── helper.d.ts.map │ │ │ ├── helper.js.map │ │ │ ├── index.d.ts │ │ │ ├── index.d.ts.map │ │ │ ├── index.js │ │ │ ├── index.js.map │ │ │ └── index.ts │ │ ├── run-script │ │ │ ├── helper.d.ts │ │ │ ├── helper.d.ts.map │ │ │ ├── helper.js │ │ │ ├── helper.js.map │ │ │ ├── helper.ts │ │ │ ├── index.d.ts │ │ │ ├── index.d.ts.map │ │ │ ├── index.js │ │ │ ├── index.js.map │ │ │ └── index.ts │ │ ├── run │ │ │ ├── index.d.ts │ │ │ ├── index.d.ts.map │ │ │ ├── index.js │ │ │ ├── index.js.map │ │ │ └── index.ts │ │ ├── search │ │ │ ├── action.d.ts │ │ │ ├── action.d.ts.map │ │ │ ├── action.js │ │ │ ├── action.js.map │ │ │ ├── action.ts │ │ │ ├── helper.d.ts │ │ │ ├── helper.d.ts.map │ │ │ ├── helper.js.map │ │ │ ├── index.d.ts │ │ │ ├── index.d.ts.map │ │ │ ├── index.js │ │ │ ├── index.js.map │ │ │ └── index.ts │ │ └── watch │ │ │ ├── index.d.ts │ │ │ ├── index.d.ts.map │ │ │ ├── index.js │ │ │ ├── index.js.map │ │ │ └── index.ts │ ├── kodyfire.d.ts │ ├── package-lock.json │ ├── package.json │ ├── src │ │ ├── bin │ │ │ ├── kody.d.ts.map │ │ │ ├── kody.ts │ │ │ └── watch.mjs │ │ ├── design │ │ │ ├── generator.wsd │ │ │ └── kodyfire.wsd │ │ ├── helpers │ │ │ └── commands │ │ │ │ ├── action.d.ts.map │ │ │ │ └── action.ts │ │ └── lib │ │ │ └── cli │ │ │ ├── worklfow.d.ts.map │ │ │ └── worklfow.ts │ └── tsconfig.json ├── kodyfire-config │ ├── config │ │ ├── default.d.ts │ │ ├── default.d.ts.map │ │ ├── default.js │ │ ├── default.js.map │ │ └── default.ts │ ├── index.d.ts │ ├── index.d.ts.map │ ├── index.js │ ├── index.js.map │ ├── index.ts │ ├── package-lock.json │ ├── package.json │ ├── test.js.map │ └── tsconfig.json └── kodyfire-core │ ├── .gitignore │ ├── LICENSE │ ├── Template.d.ts │ ├── Template.js.map │ ├── index.d.ts │ ├── index.d.ts.map │ ├── index.js │ ├── index.js.map │ ├── index.ts │ ├── kody.d.ts │ ├── kody.d.ts.map │ ├── lib │ ├── index.d.ts │ ├── index.d.ts.map │ ├── index.js │ ├── index.js.map │ ├── index.ts │ ├── jsonFactory.d.ts │ ├── jsonFactory.d.ts.map │ ├── jsonFactory.js.map │ ├── package.d.ts │ ├── package.d.ts.map │ ├── package.js │ ├── package.js.map │ ├── package.ts │ ├── runner.d.ts │ ├── runner.d.ts.map │ ├── runner.js │ ├── runner.js.map │ └── runner.ts │ ├── main.d.ts │ ├── package-lock.json │ ├── package.json │ ├── parser.d.ts │ ├── parser.d.ts.map │ ├── parser.js.map │ ├── resolvers │ ├── yaml.d.ts │ ├── yaml.d.ts.map │ ├── yaml.js │ ├── yaml.js.map │ └── yaml.ts │ ├── schemas │ ├── action.json │ ├── argument.json │ ├── concept.json │ └── technology.json │ ├── template.d.ts.map │ ├── tsconfig.json │ ├── typings │ ├── Template.js │ ├── action.d.ts │ ├── action.d.ts.map │ ├── action.js.map │ ├── actionList.d.ts │ ├── actionList.d.ts.map │ ├── actionList.js │ ├── actionList.js.map │ ├── actionList.ts │ ├── argument.d.ts │ ├── argument.d.ts.map │ ├── argument.js │ ├── argument.js.map │ ├── argument.ts │ ├── artifact.d.ts │ ├── artifact.d.ts.map │ ├── artifact.js │ ├── artifact.js.map │ ├── artifact.ts │ ├── concept.d.ts │ ├── concept.d.ts.map │ ├── concept.js │ ├── concept.js.map │ ├── concept.ts │ ├── generator.d.ts │ ├── generator.d.ts.map │ ├── generator.js │ ├── generator.js.map │ ├── generator.ts │ ├── kody.d.ts │ ├── kody.d.ts.map │ ├── kody.js │ ├── kody.js.map │ ├── kody.ts │ ├── package.d.ts │ ├── package.d.ts.map │ ├── package.js │ ├── package.js.map │ ├── package.ts │ ├── parser.d.ts │ ├── parser.d.ts.map │ ├── parser.js │ ├── parser.js.map │ ├── parser.ts │ ├── service.d.ts │ ├── service.d.ts.map │ ├── technology.d.ts │ ├── technology.d.ts.map │ ├── technology.js │ ├── technology.js.map │ ├── technology.ts │ ├── template.d.ts │ ├── template.d.ts.map │ ├── template.js.map │ ├── template.ts │ ├── validator.d.ts │ ├── validator.d.ts.map │ ├── validator.js │ ├── validator.js.map │ ├── validator.ts │ ├── workflow.d.ts │ ├── workflow.d.ts.map │ ├── workflow.js │ ├── workflow.js.map │ └── workflow.ts │ ├── utils │ ├── jsonSchemaToObject.d.ts │ ├── jsonSchemaToObject.d.ts.map │ ├── jsonSchemaToObject.js │ ├── jsonSchemaToObject.js.map │ └── jsonSchemaToObject.ts │ ├── validator.d.ts │ ├── validator.d.ts.map │ └── validator.js.map ├── scripts ├── gum │ └── commit.sh └── kodyfire │ ├── postpublish.mjs │ └── prepublish.mjs ├── test ├── index.test.js ├── jest.config.js └── packages │ └── kodyfire-cli │ └── index.js └── tsconfig.json /.eslintignore: -------------------------------------------------------------------------------- 1 | node_modules/ 2 | build 3 | dist 4 | packages/*/node_modules 5 | -------------------------------------------------------------------------------- /.eslintrc.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | "env": { 3 | "browser": true, 4 | "es2021": true, 5 | "amd": true, 6 | "node": true 7 | }, 8 | "extends": [ 9 | "eslint:recommended", 10 | "plugin:@typescript-eslint/recommended" 11 | ], 12 | "parser": "@typescript-eslint/parser", 13 | "parserOptions": { 14 | "ecmaVersion": "latest", 15 | "sourceType": "module" 16 | }, 17 | "plugins": [ 18 | "@typescript-eslint" 19 | ], 20 | "rules": { 21 | "@typescript-eslint/ban-ts-comment": "off", 22 | "@typescript-eslint/ban-types": "off", 23 | "@typescript-eslint/no-explicit-any": "off", 24 | "@typescript-eslint/no-var-requires": "off", 25 | "@typescript-eslint/no-unused-vars": "off", 26 | "require-yield": "off", 27 | 28 | } 29 | } -------------------------------------------------------------------------------- /.gitattributes: -------------------------------------------------------------------------------- 1 | *.json linguist-language=JSON-with-Comments -------------------------------------------------------------------------------- /.github/FUNDING.yml: -------------------------------------------------------------------------------- 1 | # These are supported funding model platforms 2 | 3 | github: [anis-marrouchi] 4 | patreon: # 5 | open_collective: # 6 | ko_fi: # 7 | tidelift: # Replace with a single Tidelift platform-name/package-name e.g., npm/babel 8 | community_bridge: # Replace with a single Community Bridge project-name e.g., cloud-foundry 9 | liberapay: # Replace with a single Liberapay username 10 | issuehunt: # 11 | otechie: # Replace with a single Otechie username 12 | custom: # Replace with up to 4 custom sponsorship URLs e.g., ['link1', 'link2'] 13 | -------------------------------------------------------------------------------- /.github/ISSUE_TEMPLATE/bug-report.md: -------------------------------------------------------------------------------- 1 | --- 2 | name: Bug Report 3 | about: Spotted a bug? Let's get that fixed 4 | title: '' 5 | labels: bug 6 | assignees: anis-marrouchi 7 | --- 8 | 9 | **Bug Description** 10 | 11 | **Steps to Reproduce** 12 | 13 | **Expected Behavior** 14 | 15 | **Screenshots** 16 | 17 | **Desktop** 18 | 19 | - OS 20 | - Browser 21 | - Version 22 | 23 | **Additional Information** 24 | -------------------------------------------------------------------------------- /.github/ISSUE_TEMPLATE/feature-request.md: -------------------------------------------------------------------------------- 1 | --- 2 | name: Feature Request 3 | about: Suggest an idea for the project 4 | title: '' 5 | labels: enhancement 6 | assignees: anis-marrouchi 7 | --- 8 | 9 | **Feature title here ** 10 | 11 | There are no specifics requirements for feature requests! 12 | -------------------------------------------------------------------------------- /.github/workflows/greetings.yml: -------------------------------------------------------------------------------- 1 | name: Auto message for Issues 2 | on: issues 3 | jobs: 4 | greeting: 5 | runs-on: ubuntu-latest 6 | steps: 7 | - uses: actions/first-interaction@v1 8 | with: 9 | repo-token: ${{ secrets.CUSTOM_TOKEN }} 10 | issue-message: 'Hello @${{ github.actor }} , thank you for submitting an issue! 👍 We highly appreciate your time and effort.' 11 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | 2 | # Outputs 3 | src/**/*.js 4 | src/**/*.js.map 5 | src/**/*.d.ts 6 | 7 | # IDEs 8 | .idea/ 9 | jsconfig.json 10 | .vscode/ 11 | 12 | # Misc 13 | node_modules/ 14 | packages/*/node_modules 15 | npm-debug.log* 16 | yarn-error.log* 17 | dist 18 | kodyfire.code-workspace 19 | # Mac OSX Finder files. 20 | **/.DS_Store 21 | .DS_Store 22 | #npm 23 | .npmrc 24 | #api-extractor.json 25 | temp/ 26 | target/ 27 | 28 | #lerna 29 | /.changelog 30 | 31 | #kodyfire 32 | .kody 33 | dist 34 | .env 35 | lerna-debug.log 36 | kody-*.json 37 | *.code-workspace 38 | archive -------------------------------------------------------------------------------- /.husky/pre-commit: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | . "$(dirname "$0")/_/husky.sh" 3 | 4 | npx lint-staged --allow-empty 5 | -------------------------------------------------------------------------------- /.npmignore: -------------------------------------------------------------------------------- 1 | 2 | # Ignores TypeScript files, but keeps definitions. 3 | *.ts 4 | !*.d.ts 5 | dist 6 | node_modules/ 7 | packages/*/node_modules 8 | -------------------------------------------------------------------------------- /.prettierignore: -------------------------------------------------------------------------------- 1 | # Ignore artifacts: 2 | build 3 | coverage 4 | dist -------------------------------------------------------------------------------- /.prettierrc.json: -------------------------------------------------------------------------------- 1 | { 2 | "arrowParens": "avoid", 3 | "singleQuote": true, 4 | "semi": true 5 | } 6 | -------------------------------------------------------------------------------- /CHANGELOG.md: -------------------------------------------------------------------------------- 1 | ## Changelog 2 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2018-present, NOQTA, SUARL. 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /SECURITY.md: -------------------------------------------------------------------------------- 1 | # Reporting Security Issues 2 | 3 | If you believe you have found a security vulnerability in Create React App, we encourage you to let us know right away. We will investigate all legitimate reports and do our best to quickly fix the problem. 4 | 5 | Please refer to the following page for our responsible disclosure policy, reward guidelines, and those things that should not be reported: 6 | 7 | https://www.facebook.com/whitehat 8 | -------------------------------------------------------------------------------- /babel.config.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | presets: [ 3 | [ 4 | '@babel/preset-env', 5 | { 6 | targets: { 7 | node: 'current', 8 | }, 9 | }, 10 | ], 11 | '@babel/preset-react', 12 | ], 13 | }; 14 | -------------------------------------------------------------------------------- /condition.ts: -------------------------------------------------------------------------------- 1 | (async () => { 2 | let i = 0; 3 | setInterval(async () => { 4 | console.log(i++); 5 | if (await stopCondition()) return false; 6 | return true; 7 | }, 1000); 8 | })(); 9 | 10 | const stopCondition = () => { 11 | return new Promise((resolve, reject) => { 12 | setTimeout(() => { 13 | resolve(true); 14 | }, 2000); 15 | }); 16 | }; 17 | -------------------------------------------------------------------------------- /docusaurus/kodyfire-docs/.gitignore: -------------------------------------------------------------------------------- 1 | # Dependencies 2 | /node_modules 3 | 4 | # Production 5 | /build 6 | 7 | # Generated files 8 | .docusaurus 9 | .cache-loader 10 | 11 | # Misc 12 | .DS_Store 13 | .env.local 14 | .env.development.local 15 | .env.test.local 16 | .env.production.local 17 | 18 | npm-debug.log* 19 | yarn-debug.log* 20 | yarn-error.log* 21 | -------------------------------------------------------------------------------- /docusaurus/kodyfire-docs/README.md: -------------------------------------------------------------------------------- 1 | # Website 2 | 3 | This website is built using [Docusaurus 2](https://docusaurus.io/), a modern static website generator. 4 | 5 | ### Installation 6 | 7 | ``` 8 | $ yarn 9 | ``` 10 | 11 | ### Local Development 12 | 13 | ``` 14 | $ yarn start 15 | ``` 16 | 17 | This command starts a local development server and opens up a browser window. Most changes are reflected live without having to restart the server. 18 | 19 | ### Build 20 | 21 | ``` 22 | $ yarn build 23 | ``` 24 | 25 | This command generates static content into the `build` directory and can be served using any static contents hosting service. 26 | 27 | ### Deployment 28 | 29 | Using SSH: 30 | 31 | ``` 32 | $ USE_SSH=true yarn deploy 33 | ``` 34 | 35 | Not using SSH: 36 | 37 | ``` 38 | $ GIT_USER= yarn deploy 39 | ``` 40 | 41 | If you are using GitHub pages for hosting, this command is a convenient way to build the website and push to the `gh-pages` branch. 42 | -------------------------------------------------------------------------------- /docusaurus/kodyfire-docs/babel.config.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | presets: [require.resolve('@docusaurus/core/lib/babel/preset')], 3 | }; 4 | -------------------------------------------------------------------------------- /docusaurus/kodyfire-docs/blog/2019-05-28-first-blog-post.md: -------------------------------------------------------------------------------- 1 | --- 2 | slug: first-blog-post 3 | title: First Blog Post 4 | authors: 5 | name: Gao Wei 6 | title: Docusaurus Core Team 7 | url: https://github.com/wgao19 8 | image_url: https://github.com/wgao19.png 9 | tags: [hola, docusaurus] 10 | --- 11 | 12 | Lorem ipsum dolor sit amet, consectetur adipiscing elit. Pellentesque elementum dignissim ultricies. Fusce rhoncus ipsum tempor eros aliquam consequat. Lorem ipsum dolor sit amet 13 | -------------------------------------------------------------------------------- /docusaurus/kodyfire-docs/blog/2021-08-01-mdx-blog-post.mdx: -------------------------------------------------------------------------------- 1 | --- 2 | slug: mdx-blog-post 3 | title: MDX Blog Post 4 | authors: [slorber] 5 | tags: [docusaurus] 6 | --- 7 | 8 | Blog posts support [Docusaurus Markdown features](https://docusaurus.io/docs/markdown-features), such as [MDX](https://mdxjs.com/). 9 | 10 | :::tip 11 | 12 | Use the power of React to create interactive blog posts. 13 | 14 | ```js 15 | 16 | ``` 17 | 18 | 19 | 20 | ::: 21 | -------------------------------------------------------------------------------- /docusaurus/kodyfire-docs/blog/2021-08-26-welcome/docusaurus-plushie-banner.jpeg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nooqta/kodyfire/82d1cb624cfc5dacade7a92fc274f1ca589cc37e/docusaurus/kodyfire-docs/blog/2021-08-26-welcome/docusaurus-plushie-banner.jpeg -------------------------------------------------------------------------------- /docusaurus/kodyfire-docs/blog/2021-08-26-welcome/index.md: -------------------------------------------------------------------------------- 1 | --- 2 | slug: welcome 3 | title: Welcome 4 | authors: [slorber, yangshun] 5 | tags: [facebook, hello, docusaurus] 6 | --- 7 | 8 | [Docusaurus blogging features](https://docusaurus.io/docs/blog) are powered by the [blog plugin](https://docusaurus.io/docs/api/plugins/@docusaurus/plugin-content-blog). 9 | 10 | Simply add Markdown files (or folders) to the `blog` directory. 11 | 12 | Regular blog authors can be added to `authors.yml`. 13 | 14 | The blog post date can be extracted from filenames, such as: 15 | 16 | - `2019-05-30-welcome.md` 17 | - `2019-05-30-welcome/index.md` 18 | 19 | A blog post folder can be convenient to co-locate blog post images: 20 | 21 | ![Docusaurus Plushie](./docusaurus-plushie-banner.jpeg) 22 | 23 | The blog supports tags as well! 24 | 25 | **And if you don't want a blog**: just delete this directory, and use `blog: false` in your Docusaurus config. 26 | -------------------------------------------------------------------------------- /docusaurus/kodyfire-docs/blog/authors.yml: -------------------------------------------------------------------------------- 1 | endi: 2 | name: Endilie Yacop Sucipto 3 | title: Maintainer of Docusaurus 4 | url: https://github.com/endiliey 5 | image_url: https://github.com/endiliey.png 6 | 7 | yangshun: 8 | name: Yangshun Tay 9 | title: Front End Engineer @ Facebook 10 | url: https://github.com/yangshun 11 | image_url: https://github.com/yangshun.png 12 | 13 | slorber: 14 | name: Sébastien Lorber 15 | title: Docusaurus maintainer 16 | url: https://sebastienlorber.com 17 | image_url: https://github.com/slorber.png 18 | -------------------------------------------------------------------------------- /docusaurus/kodyfire-docs/docs/tutorial-basics/_category_.json: -------------------------------------------------------------------------------- 1 | { 2 | "label": "Tutorial - Basics", 3 | "position": 2 4 | } 5 | -------------------------------------------------------------------------------- /docusaurus/kodyfire-docs/docs/tutorial-basics/congratulations.md: -------------------------------------------------------------------------------- 1 | --- 2 | sidebar_position: 6 3 | --- 4 | 5 | # Congratulations! 6 | 7 | You have just learned the **basics of Docusaurus** and made some changes to the **initial template**. 8 | 9 | Docusaurus has **much more to offer**! 10 | 11 | Have **5 more minutes**? Take a look at **[versioning](../tutorial-extras/manage-docs-versions.md)** and **[i18n](../tutorial-extras/translate-your-site.md)**. 12 | 13 | Anything **unclear** or **buggy** in this tutorial? [Please report it!](https://github.com/facebook/docusaurus/discussions/4610) 14 | 15 | ## What's next? 16 | 17 | - Read the [official documentation](https://docusaurus.io/). 18 | - Add a custom [Design and Layout](https://docusaurus.io/docs/styling-layout) 19 | - Add a [search bar](https://docusaurus.io/docs/search) 20 | - Find inspirations in the [Docusaurus showcase](https://docusaurus.io/showcase) 21 | - Get involved in the [Docusaurus Community](https://docusaurus.io/community/support) 22 | -------------------------------------------------------------------------------- /docusaurus/kodyfire-docs/docs/tutorial-basics/create-a-blog-post.md: -------------------------------------------------------------------------------- 1 | --- 2 | sidebar_position: 3 3 | --- 4 | 5 | # Create a Blog Post 6 | 7 | Docusaurus creates a **page for each blog post**, but also a **blog index page**, a **tag system**, an **RSS** feed... 8 | 9 | ## Create your first Post 10 | 11 | Create a file at `blog/2021-02-28-greetings.md`: 12 | 13 | ```md title="blog/2021-02-28-greetings.md" 14 | --- 15 | slug: greetings 16 | title: Greetings! 17 | authors: 18 | - name: Joel Marcey 19 | title: Co-creator of Docusaurus 1 20 | url: https://github.com/JoelMarcey 21 | image_url: https://github.com/JoelMarcey.png 22 | - name: Sébastien Lorber 23 | title: Docusaurus maintainer 24 | url: https://sebastienlorber.com 25 | image_url: https://github.com/slorber.png 26 | tags: [greetings] 27 | --- 28 | 29 | Congratulations, you have made your first post! 30 | 31 | Feel free to play around and edit this post as much you like. 32 | ``` 33 | 34 | A new blog post is now available at `http://localhost:3000/blog/greetings`. 35 | -------------------------------------------------------------------------------- /docusaurus/kodyfire-docs/docs/tutorial-basics/create-a-page.md: -------------------------------------------------------------------------------- 1 | --- 2 | sidebar_position: 1 3 | --- 4 | 5 | # Create a Page 6 | 7 | Add **Markdown or React** files to `src/pages` to create a **standalone page**: 8 | 9 | - `src/pages/index.js` -> `localhost:3000/` 10 | - `src/pages/foo.md` -> `localhost:3000/foo` 11 | - `src/pages/foo/bar.js` -> `localhost:3000/foo/bar` 12 | 13 | ## Create your first React Page 14 | 15 | Create a file at `src/pages/my-react-page.js`: 16 | 17 | ```jsx title="src/pages/my-react-page.js" 18 | import React from 'react'; 19 | import Layout from '@theme/Layout'; 20 | 21 | export default function MyReactPage() { 22 | return ( 23 | 24 |

My React page

25 |

This is a React page

26 |
27 | ); 28 | } 29 | ``` 30 | 31 | A new page is now available at `http://localhost:3000/my-react-page`. 32 | 33 | ## Create your first Markdown Page 34 | 35 | Create a file at `src/pages/my-markdown-page.md`: 36 | 37 | ```mdx title="src/pages/my-markdown-page.md" 38 | # My Markdown page 39 | 40 | This is a Markdown page 41 | ``` 42 | 43 | A new page is now available at `http://localhost:3000/my-markdown-page`. 44 | -------------------------------------------------------------------------------- /docusaurus/kodyfire-docs/docs/tutorial-basics/deploy-your-site.md: -------------------------------------------------------------------------------- 1 | --- 2 | sidebar_position: 5 3 | --- 4 | 5 | # Deploy your site 6 | 7 | Docusaurus is a **static-site-generator** (also called **[Jamstack](https://jamstack.org/)**). 8 | 9 | It builds your site as simple **static HTML, JavaScript and CSS files**. 10 | 11 | ## Build your site 12 | 13 | Build your site **for production**: 14 | 15 | ```bash 16 | npm run build 17 | ``` 18 | 19 | The static files are generated in the `build` folder. 20 | 21 | ## Deploy your site 22 | 23 | Test your production build locally: 24 | 25 | ```bash 26 | npm run serve 27 | ``` 28 | 29 | The `build` folder is now served at `http://localhost:3000/`. 30 | 31 | You can now deploy the `build` folder **almost anywhere** easily, **for free** or very small cost (read the **[Deployment Guide](https://docusaurus.io/docs/deployment)**). 32 | -------------------------------------------------------------------------------- /docusaurus/kodyfire-docs/docs/tutorial-extras/_category_.json: -------------------------------------------------------------------------------- 1 | { 2 | "label": "Tutorial - Extras", 3 | "position": 3 4 | } 5 | -------------------------------------------------------------------------------- /docusaurus/kodyfire-docs/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "kodyfire-doc", 3 | "version": "0.0.0", 4 | "private": true, 5 | "scripts": { 6 | "docusaurus": "docusaurus", 7 | "start": "docusaurus start", 8 | "build": "docusaurus build", 9 | "swizzle": "docusaurus swizzle", 10 | "deploy": "docusaurus deploy", 11 | "clear": "docusaurus clear", 12 | "serve": "docusaurus serve", 13 | "write-translations": "docusaurus write-translations", 14 | "write-heading-ids": "docusaurus write-heading-ids" 15 | }, 16 | "dependencies": { 17 | "@docusaurus/core": "2.0.0-beta.15", 18 | "@docusaurus/preset-classic": "2.0.0-beta.15", 19 | "@mdx-js/react": "^1.6.21", 20 | "clsx": "^1.1.1", 21 | "prism-react-renderer": "^1.2.1", 22 | "react": "^17.0.1", 23 | "react-dom": "^17.0.1" 24 | }, 25 | "browserslist": { 26 | "production": [ 27 | ">0.5%", 28 | "not dead", 29 | "not op_mini all" 30 | ], 31 | "development": [ 32 | "last 1 chrome version", 33 | "last 1 firefox version", 34 | "last 1 safari version" 35 | ] 36 | } 37 | } 38 | -------------------------------------------------------------------------------- /docusaurus/kodyfire-docs/ramdan-mubarak.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nooqta/kodyfire/82d1cb624cfc5dacade7a92fc274f1ca589cc37e/docusaurus/kodyfire-docs/ramdan-mubarak.png -------------------------------------------------------------------------------- /docusaurus/kodyfire-docs/sidebars.js: -------------------------------------------------------------------------------- 1 | /** 2 | * Creating a sidebar enables you to: 3 | - create an ordered group of docs 4 | - render a sidebar for each doc of that group 5 | - provide next/previous navigation 6 | 7 | The sidebars can be generated from the filesystem, or explicitly defined here. 8 | 9 | Create as many sidebars as you want. 10 | */ 11 | 12 | // @ts-check 13 | 14 | /** @type {import('@docusaurus/plugin-content-docs').SidebarsConfig} */ 15 | const sidebars = { 16 | // By default, Docusaurus generates a sidebar from the docs folder structure 17 | tutorialSidebar: [{ type: 'autogenerated', dirName: '.' }], 18 | 19 | // But you can create a sidebar manually 20 | /* 21 | tutorialSidebar: [ 22 | { 23 | type: 'category', 24 | label: 'Tutorial', 25 | items: ['hello'], 26 | }, 27 | ], 28 | */ 29 | }; 30 | 31 | module.exports = sidebars; 32 | -------------------------------------------------------------------------------- /docusaurus/kodyfire-docs/src/components/HomepageFeatures.module.css: -------------------------------------------------------------------------------- 1 | .features { 2 | display: flex; 3 | align-items: center; 4 | padding: 2rem 0; 5 | width: 100%; 6 | } 7 | 8 | .featureSvg { 9 | height: 200px; 10 | width: 200px; 11 | } 12 | -------------------------------------------------------------------------------- /docusaurus/kodyfire-docs/src/pages/index.module.css: -------------------------------------------------------------------------------- 1 | /** 2 | * CSS files with the .module.css suffix will be treated as CSS modules 3 | * and scoped locally. 4 | */ 5 | 6 | .heroBanner { 7 | padding: 4rem 0; 8 | text-align: center; 9 | position: relative; 10 | overflow: hidden; 11 | } 12 | 13 | @media screen and (max-width: 966px) { 14 | .heroBanner { 15 | padding: 2rem; 16 | } 17 | } 18 | 19 | .buttons { 20 | display: flex; 21 | align-items: center; 22 | justify-content: center; 23 | } 24 | -------------------------------------------------------------------------------- /docusaurus/kodyfire-docs/src/pages/markdown-page.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Markdown page example 3 | --- 4 | 5 | # Markdown page example 6 | 7 | You don't need React to write simple standalone pages. 8 | -------------------------------------------------------------------------------- /docusaurus/kodyfire-docs/static/.nojekyll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nooqta/kodyfire/82d1cb624cfc5dacade7a92fc274f1ca589cc37e/docusaurus/kodyfire-docs/static/.nojekyll -------------------------------------------------------------------------------- /docusaurus/kodyfire-docs/static/img/docusaurus.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nooqta/kodyfire/82d1cb624cfc5dacade7a92fc274f1ca589cc37e/docusaurus/kodyfire-docs/static/img/docusaurus.png -------------------------------------------------------------------------------- /docusaurus/kodyfire-docs/static/img/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nooqta/kodyfire/82d1cb624cfc5dacade7a92fc274f1ca589cc37e/docusaurus/kodyfire-docs/static/img/favicon.ico -------------------------------------------------------------------------------- /docusaurus/kodyfire-docs/static/img/tutorial/docsVersionDropdown.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nooqta/kodyfire/82d1cb624cfc5dacade7a92fc274f1ca589cc37e/docusaurus/kodyfire-docs/static/img/tutorial/docsVersionDropdown.png -------------------------------------------------------------------------------- /docusaurus/kodyfire-docs/static/img/tutorial/localeDropdown.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nooqta/kodyfire/82d1cb624cfc5dacade7a92fc274f1ca589cc37e/docusaurus/kodyfire-docs/static/img/tutorial/localeDropdown.png -------------------------------------------------------------------------------- /lerna.json: -------------------------------------------------------------------------------- 1 | { 2 | "packages": ["packages/*"], 3 | "changelog": { 4 | "repo": "noqta/kodyfire", 5 | "labels": { 6 | "new feature": ":rocket: New Feature", 7 | "breaking change": ":boom: Breaking Change", 8 | "bug fix": ":bug: Bug Fix", 9 | "enhancement": ":nail_care: Enhancement", 10 | "documentation": ":memo: Documentation", 11 | "internal": ":house: Internal" 12 | }, 13 | "cacheDir": ".changelog" 14 | }, 15 | "version": "0.1.36" 16 | } 17 | -------------------------------------------------------------------------------- /packages/basic-kodyfire/.gitignore: -------------------------------------------------------------------------------- 1 | 2 | # Outputs 3 | src/**/*.js 4 | src/**/*.js.map 5 | src/**/*.d.ts 6 | 7 | # IDEs 8 | .idea/ 9 | jsconfig.json 10 | .vscode/ 11 | 12 | # Misc 13 | node_modules/ 14 | npm-debug.log* 15 | yarn-error.log* 16 | 17 | # Mac OSX Finder files. 18 | **/.DS_Store 19 | .DS_Store 20 | 21 | #npm 22 | .npmrc 23 | -------------------------------------------------------------------------------- /packages/basic-kodyfire/.npmignore: -------------------------------------------------------------------------------- 1 | 2 | # Ignores TypeScript files, but keeps definitions. 3 | *.ts 4 | !*.d.ts 5 | .npmrc 6 | -------------------------------------------------------------------------------- /packages/basic-kodyfire/LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2018-present, NOQTA, SUARL. 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /packages/basic-kodyfire/build/assets.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "basic", 3 | "version": "0.1", 4 | "rootDir": "out", 5 | "concepts": [ 6 | { 7 | "name": "concept", 8 | "outputDir": "", 9 | "template": { 10 | "path": "templates/", 11 | "options": [], 12 | "placeholders": [] 13 | } 14 | } 15 | ] 16 | } 17 | -------------------------------------------------------------------------------- /packages/basic-kodyfire/build/concepts/concept.d.ts: -------------------------------------------------------------------------------- 1 | import { IConcept, ITechnology, Source, Technology, TemplateSchema } from 'kodyfire-core'; 2 | import { Engine } from './engine'; 3 | export interface IBuilder { 4 | compile(template: string): any; 5 | } 6 | export interface IEngine { 7 | builder: IBuilder; 8 | } 9 | export declare class Concept implements IConcept { 10 | name: string; 11 | source?: Source | undefined; 12 | template: TemplateSchema; 13 | outputDir: string; 14 | technology: Technology; 15 | engine: Engine; 16 | constructor(concept: Partial, technology: ITechnology); 17 | templatesPath?: string | undefined; 18 | defaultAction: string; 19 | generate(_data: any): Promise; 20 | getFilename(data: any): any; 21 | getExtension(templateName: string): string | undefined; 22 | underscorize(word: any): any; 23 | getTemplatesPath(): string; 24 | } 25 | -------------------------------------------------------------------------------- /packages/basic-kodyfire/build/concepts/engine.d.ts: -------------------------------------------------------------------------------- 1 | /// 2 | export declare class Engine { 3 | builder: any; 4 | constructor(); 5 | registerPartials(): void; 6 | read(path: string, templateName: any): Promise; 7 | getPartial(path: string, template: string, data: any): Promise; 8 | compile(template: any, data: any): any; 9 | create(rootDir: string, outputDir: string, filename: any, content: string | Buffer): Promise; 10 | overwrite(rootDir: string, outputDir: string, filename: any, content: string | Buffer): Promise; 11 | createOrOverwrite(rootDir: string, outputDir: string, filename: any, content: string | Buffer, overwrite?: boolean): Promise; 12 | setContent(filename: any, content: string | Buffer): string | Buffer; 13 | getFiles(rootDir: string, outputDir: string): Promise; 14 | } 15 | -------------------------------------------------------------------------------- /packages/basic-kodyfire/build/generator/generator.d.ts: -------------------------------------------------------------------------------- 1 | import { IGenerator, ITechnology } from 'kodyfire-core'; 2 | export declare class Generator implements IGenerator { 3 | technology: ITechnology; 4 | input: any; 5 | output: any; 6 | constructor(params: any, technology?: ITechnology); 7 | generate(content: any): Promise; 8 | } 9 | -------------------------------------------------------------------------------- /packages/basic-kodyfire/build/generator/generator.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"generator.js","sourceRoot":"","sources":["../../src/generator/generator.ts"],"names":[],"mappings":";;;;;;;;;;;;AACA,8CAA2C;AAE3C,MAAa,SAAS;IAIpB,YAAY,MAAW,EAAE,aAA0B,IAAI,uBAAU,CAAC,MAAM,CAAC;QACvE,IAAI,CAAC,UAAU,GAAG,UAAU,CAAC;IAC/B,CAAC;IACK,QAAQ,CAAC,OAAY;;;YACzB,IAAI,CAAC,KAAK,GAAG,OAAO,CAAC;YACrB,IAAI,CAAC,UAAU,CAAC,KAAK,GAAG,OAAO,CAAC;YAChC,IAAI,CAAC,UAAU,CAAC,OAAO,GAAG,OAAO,CAAC,OAAO,IAAI,IAAI,CAAC,UAAU,CAAC,OAAO,CAAC;YAErE,qCAAqC;YACrC,KAAK,MAAM,CAAC,GAAG,CAAC,IAAI,IAAI,CAAC,UAAU,CAAC,QAAQ,EAAE;gBAC5C,iDAAiD;gBACjD,IAAI,OAAO,CAAC,cAAc,CAAC,GAAG,CAAC,EAAE;oBAC/B,KAAK,MAAM,IAAI,IAAI,OAAO,CAAC,GAAG,CAAC,EAAE;wBAC/B,uBAAuB;wBACvB,IAAI,CAAC,MAAM,GAAG,MAAM,CAAA,MAAA,IAAI,CAAC,UAAU,CAAC,QAAQ,CAAC,GAAG,CAAC,GAAG,CAAC,0CAAE,QAAQ,CAAC,IAAI,CAAC,CAAA,CAAC;qBACvE;iBACF;qBAAM;oBACL,uBAAuB;iBACxB;aACF;YACD,gBAAgB;YAChB,OAAO,IAAI,CAAC,MAAM,CAAC;;KACpB;CACF;AA3BD,8BA2BC"} -------------------------------------------------------------------------------- /packages/basic-kodyfire/build/generator/index.d.ts: -------------------------------------------------------------------------------- 1 | export { Generator } from './generator'; 2 | -------------------------------------------------------------------------------- /packages/basic-kodyfire/build/generator/index.js: -------------------------------------------------------------------------------- 1 | "use strict"; 2 | Object.defineProperty(exports, "__esModule", { value: true }); 3 | exports.Generator = void 0; 4 | var generator_1 = require("./generator"); 5 | Object.defineProperty(exports, "Generator", { enumerable: true, get: function () { return generator_1.Generator; } }); 6 | //# sourceMappingURL=index.js.map -------------------------------------------------------------------------------- /packages/basic-kodyfire/build/generator/index.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/generator/index.ts"],"names":[],"mappings":";;;AAAA,yCAAwC;AAA/B,sGAAA,SAAS,OAAA"} -------------------------------------------------------------------------------- /packages/basic-kodyfire/build/index.d.ts: -------------------------------------------------------------------------------- 1 | export { Kody } from './kody'; 2 | export * from './parser'; 3 | export * from './generator'; 4 | export { Technology } from './technology'; 5 | export { Engine } from './concepts/engine'; 6 | export { Concept } from './concepts/concept'; 7 | export { schema } from './parser/validator/schema'; 8 | -------------------------------------------------------------------------------- /packages/basic-kodyfire/build/index.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;AAAA,+BAA8B;AAArB,4FAAA,IAAI,OAAA;AACb,2CAAyB;AACzB,8CAA4B;AAC5B,2CAA0C;AAAjC,wGAAA,UAAU,OAAA;AACnB,4CAA2C;AAAlC,gGAAA,MAAM,OAAA;AACf,8CAA6C;AAApC,kGAAA,OAAO,OAAA;AAChB,oDAAmD;AAA1C,gGAAA,MAAM,OAAA"} -------------------------------------------------------------------------------- /packages/basic-kodyfire/build/kody.d.ts: -------------------------------------------------------------------------------- 1 | /// 2 | import EventEmitter from 'events'; 3 | import { BaseKody, IGenerator, IKody, IParser, ITechnology, Package } from 'kodyfire-core'; 4 | import { Technology } from '.'; 5 | export declare class Kody extends BaseKody implements IKody { 6 | [x: string]: any; 7 | parser: IParser; 8 | generator: IGenerator; 9 | technology: ITechnology; 10 | package: Package; 11 | events: EventEmitter; 12 | constructor(params: any, _schema?: any, technology?: Technology); 13 | generate(_content: any): Promise; 14 | parse(content: any): any; 15 | read(source: any): any; 16 | get errors(): any; 17 | get data(): any; 18 | whereami(): string; 19 | whoami(): string; 20 | } 21 | -------------------------------------------------------------------------------- /packages/basic-kodyfire/build/parser/extractor.d.ts: -------------------------------------------------------------------------------- 1 | export declare const extract: any; 2 | -------------------------------------------------------------------------------- /packages/basic-kodyfire/build/parser/extractor.js: -------------------------------------------------------------------------------- 1 | "use strict"; 2 | Object.defineProperty(exports, "__esModule", { value: true }); 3 | exports.extract = void 0; 4 | const extract = () => { 5 | return `This is the extractor`; 6 | }; 7 | exports.extract = extract; 8 | //# sourceMappingURL=extractor.js.map -------------------------------------------------------------------------------- /packages/basic-kodyfire/build/parser/extractor.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"extractor.js","sourceRoot":"","sources":["../../src/parser/extractor.ts"],"names":[],"mappings":";;;AAAO,MAAM,OAAO,GAAQ,GAAG,EAAE;IAC/B,OAAO,uBAAuB,CAAC;AACjC,CAAC,CAAC;AAFW,QAAA,OAAO,WAElB"} -------------------------------------------------------------------------------- /packages/basic-kodyfire/build/parser/index.d.ts: -------------------------------------------------------------------------------- 1 | export { Parser } from './parser'; 2 | export { Validator } from './validator/validator'; 3 | export { schema } from './validator/schema'; 4 | -------------------------------------------------------------------------------- /packages/basic-kodyfire/build/parser/index.js: -------------------------------------------------------------------------------- 1 | "use strict"; 2 | Object.defineProperty(exports, "__esModule", { value: true }); 3 | exports.schema = exports.Validator = exports.Parser = void 0; 4 | var parser_1 = require("./parser"); 5 | Object.defineProperty(exports, "Parser", { enumerable: true, get: function () { return parser_1.Parser; } }); 6 | var validator_1 = require("./validator/validator"); 7 | Object.defineProperty(exports, "Validator", { enumerable: true, get: function () { return validator_1.Validator; } }); 8 | var schema_1 = require("./validator/schema"); 9 | Object.defineProperty(exports, "schema", { enumerable: true, get: function () { return schema_1.schema; } }); 10 | //# sourceMappingURL=index.js.map -------------------------------------------------------------------------------- /packages/basic-kodyfire/build/parser/index.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/parser/index.ts"],"names":[],"mappings":";;;AAAA,mCAAkC;AAAzB,gGAAA,MAAM,OAAA;AACf,mDAAkD;AAAzC,sGAAA,SAAS,OAAA;AAClB,6CAA4C;AAAnC,gGAAA,MAAM,OAAA"} -------------------------------------------------------------------------------- /packages/basic-kodyfire/build/parser/loader.d.ts: -------------------------------------------------------------------------------- 1 | export declare const load: any; 2 | -------------------------------------------------------------------------------- /packages/basic-kodyfire/build/parser/loader.js: -------------------------------------------------------------------------------- 1 | "use strict"; 2 | Object.defineProperty(exports, "__esModule", { value: true }); 3 | exports.load = void 0; 4 | const load = () => { 5 | return `This is the load`; 6 | }; 7 | exports.load = load; 8 | //# sourceMappingURL=loader.js.map -------------------------------------------------------------------------------- /packages/basic-kodyfire/build/parser/loader.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"loader.js","sourceRoot":"","sources":["../../src/parser/loader.ts"],"names":[],"mappings":";;;AAAO,MAAM,IAAI,GAAQ,GAAG,EAAE;IAC5B,OAAO,kBAAkB,CAAC;AAC5B,CAAC,CAAC;AAFW,QAAA,IAAI,QAEf"} -------------------------------------------------------------------------------- /packages/basic-kodyfire/build/parser/parser.d.ts: -------------------------------------------------------------------------------- 1 | import { IParser, IValidator } from 'kodyfire-core'; 2 | export declare class Parser implements IParser { 3 | validator: IValidator; 4 | requiresExtract: boolean; 5 | requiresTansform: boolean; 6 | requiresLoad: boolean; 7 | data: any; 8 | constructor(validator: IValidator); 9 | reader(source: string): any; 10 | parse(data: any): any; 11 | validate: (data: any) => boolean; 12 | extractor: any; 13 | transformer: () => string; 14 | loader: () => any; 15 | readfile(filepath: any): any; 16 | write(filepath: any, data: any): void; 17 | } 18 | -------------------------------------------------------------------------------- /packages/basic-kodyfire/build/parser/transformer.d.ts: -------------------------------------------------------------------------------- 1 | export declare const transform: () => string; 2 | -------------------------------------------------------------------------------- /packages/basic-kodyfire/build/parser/transformer.js: -------------------------------------------------------------------------------- 1 | "use strict"; 2 | Object.defineProperty(exports, "__esModule", { value: true }); 3 | exports.transform = void 0; 4 | const transform = () => { 5 | return `This is the transformer`; 6 | }; 7 | exports.transform = transform; 8 | //# sourceMappingURL=transformer.js.map -------------------------------------------------------------------------------- /packages/basic-kodyfire/build/parser/transformer.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"transformer.js","sourceRoot":"","sources":["../../src/parser/transformer.ts"],"names":[],"mappings":";;;AAAO,MAAM,SAAS,GAAG,GAAG,EAAE;IAC5B,OAAO,yBAAyB,CAAC;AACnC,CAAC,CAAC;AAFW,QAAA,SAAS,aAEpB"} -------------------------------------------------------------------------------- /packages/basic-kodyfire/build/parser/validator/index.d.ts: -------------------------------------------------------------------------------- 1 | export { schema } from './schema'; 2 | export { Validator } from './validator'; 3 | -------------------------------------------------------------------------------- /packages/basic-kodyfire/build/parser/validator/index.js: -------------------------------------------------------------------------------- 1 | "use strict"; 2 | Object.defineProperty(exports, "__esModule", { value: true }); 3 | exports.Validator = exports.schema = void 0; 4 | var schema_1 = require("./schema"); 5 | Object.defineProperty(exports, "schema", { enumerable: true, get: function () { return schema_1.schema; } }); 6 | var validator_1 = require("./validator"); 7 | Object.defineProperty(exports, "Validator", { enumerable: true, get: function () { return validator_1.Validator; } }); 8 | //# sourceMappingURL=index.js.map -------------------------------------------------------------------------------- /packages/basic-kodyfire/build/parser/validator/index.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/parser/validator/index.ts"],"names":[],"mappings":";;;AAAA,mCAAkC;AAAzB,gGAAA,MAAM,OAAA;AACf,yCAAwC;AAA/B,sGAAA,SAAS,OAAA"} -------------------------------------------------------------------------------- /packages/basic-kodyfire/build/parser/validator/schema.d.ts: -------------------------------------------------------------------------------- 1 | export declare const concept: { 2 | type: string; 3 | properties: { 4 | name: { 5 | type: string; 6 | }; 7 | template: { 8 | type: string; 9 | }; 10 | outputDir: { 11 | type: string; 12 | }; 13 | }; 14 | }; 15 | export declare const conceptArray: { 16 | type: string; 17 | items: any; 18 | }; 19 | export declare const schema: { 20 | type: string; 21 | properties: { 22 | project: { 23 | type: string; 24 | }; 25 | name: { 26 | type: string; 27 | }; 28 | rootDir: { 29 | type: string; 30 | }; 31 | concept: { 32 | type: string; 33 | items: any; 34 | }; 35 | }; 36 | required: string[]; 37 | }; 38 | -------------------------------------------------------------------------------- /packages/basic-kodyfire/build/parser/validator/schema.js: -------------------------------------------------------------------------------- 1 | "use strict"; 2 | Object.defineProperty(exports, "__esModule", { value: true }); 3 | exports.schema = exports.conceptArray = exports.concept = void 0; 4 | exports.concept = { 5 | type: 'object', 6 | properties: { 7 | name: { type: 'string' }, 8 | template: { 9 | type: 'string', 10 | }, 11 | outputDir: { type: 'string' }, 12 | }, 13 | }; 14 | exports.conceptArray = { 15 | type: 'array', 16 | items: exports.concept, 17 | }; 18 | exports.schema = { 19 | type: 'object', 20 | properties: { 21 | project: { type: 'string' }, 22 | name: { type: 'string' }, 23 | rootDir: { type: 'string' }, 24 | concept: exports.conceptArray, 25 | }, 26 | required: ['name'], 27 | }; 28 | //# sourceMappingURL=schema.js.map -------------------------------------------------------------------------------- /packages/basic-kodyfire/build/parser/validator/schema.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"schema.js","sourceRoot":"","sources":["../../../src/parser/validator/schema.ts"],"names":[],"mappings":";;;AAAa,QAAA,OAAO,GAAG;IACrB,IAAI,EAAE,QAAQ;IACd,UAAU,EAAE;QACV,IAAI,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE;QACxB,QAAQ,EAAE;YACR,IAAI,EAAE,QAAQ;SACf;QACD,SAAS,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE;KAC9B;CACF,CAAC;AAEW,QAAA,YAAY,GAAiC;IACxD,IAAI,EAAE,OAAO;IACb,KAAK,EAAE,eAAO;CACf,CAAC;AACW,QAAA,MAAM,GAAG;IACpB,IAAI,EAAE,QAAQ;IACd,UAAU,EAAE;QACV,OAAO,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE;QAC3B,IAAI,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE;QACxB,OAAO,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE;QAC3B,OAAO,EAAE,oBAAY;KACtB;IACD,QAAQ,EAAE,CAAC,MAAM,CAAC;CACnB,CAAC"} -------------------------------------------------------------------------------- /packages/basic-kodyfire/build/parser/validator/validator.d.ts: -------------------------------------------------------------------------------- 1 | import { IValidator } from 'kodyfire-core'; 2 | import Ajv, { ErrorObject } from 'ajv'; 3 | export declare class Validator implements IValidator { 4 | rules: any; 5 | schemaValidator: Ajv; 6 | errors: ErrorObject, unknown>[] | null | undefined; 7 | constructor(_schema?: any); 8 | validate(data: any): boolean; 9 | } 10 | -------------------------------------------------------------------------------- /packages/basic-kodyfire/build/parser/validator/validator.js: -------------------------------------------------------------------------------- 1 | "use strict"; 2 | var __importDefault = (this && this.__importDefault) || function (mod) { 3 | return (mod && mod.__esModule) ? mod : { "default": mod }; 4 | }; 5 | Object.defineProperty(exports, "__esModule", { value: true }); 6 | exports.Validator = void 0; 7 | const schema_1 = require("./schema"); 8 | const ajv_1 = __importDefault(require("ajv")); 9 | class Validator { 10 | constructor(_schema = schema_1.schema) { 11 | this.rules = _schema; 12 | this.schemaValidator = new ajv_1.default(); 13 | } 14 | validate(data) { 15 | const schema = this.rules; 16 | // validate is a type guard for data - type is inferred from schema type 17 | const validate = this.schemaValidator.compile(schema); 18 | if (validate(data)) { 19 | // data is MyData here 20 | return true; 21 | } 22 | else { 23 | this.errors = validate.errors; 24 | console.log(validate.errors); 25 | return false; 26 | } 27 | } 28 | } 29 | exports.Validator = Validator; 30 | //# sourceMappingURL=validator.js.map -------------------------------------------------------------------------------- /packages/basic-kodyfire/build/parser/validator/validator.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"validator.js","sourceRoot":"","sources":["../../../src/parser/validator/validator.ts"],"names":[],"mappings":";;;;;;AACA,qCAAkC;AAClC,8CAAuD;AAEvD,MAAa,SAAS;IAOpB,YAAY,UAAe,eAAM;QAC/B,IAAI,CAAC,KAAK,GAAG,OAAO,CAAC;QACrB,IAAI,CAAC,eAAe,GAAG,IAAI,aAAG,EAAE,CAAC;IACnC,CAAC;IACD,QAAQ,CAAC,IAAS;QAChB,MAAM,MAAM,GAAgC,IAAI,CAAC,KAAK,CAAC;QAEvD,wEAAwE;QACxE,MAAM,QAAQ,GAAG,IAAI,CAAC,eAAe,CAAC,OAAO,CAAC,MAAM,CAAC,CAAC;QAEtD,IAAI,QAAQ,CAAC,IAAI,CAAC,EAAE;YAClB,sBAAsB;YACtB,OAAO,IAAI,CAAC;SACb;aAAM;YACL,IAAI,CAAC,MAAM,GAAG,QAAQ,CAAC,MAAM,CAAC;YAC9B,OAAO,CAAC,GAAG,CAAC,QAAQ,CAAC,MAAM,CAAC,CAAC;YAC7B,OAAO,KAAK,CAAC;SACd;IACH,CAAC;CACF;AA1BD,8BA0BC"} -------------------------------------------------------------------------------- /packages/basic-kodyfire/build/technology.d.ts: -------------------------------------------------------------------------------- 1 | import { ActionList, IConcept, Technology as BaseTechnology } from 'kodyfire-core'; 2 | export declare class Technology implements BaseTechnology { 3 | id: string; 4 | name: string; 5 | version: string; 6 | rootDir: string; 7 | concepts: Map; 8 | assets: any; 9 | actions: ActionList; 10 | input?: any; 11 | params: any; 12 | constructor(params: any, _assets?: any); 13 | initConcepts(): void; 14 | updateTemplatesPath(params: any): void; 15 | prepareConcept(dependency: string, conceptName: string, preparedConcept: any): Promise; 16 | } 17 | -------------------------------------------------------------------------------- /packages/basic-kodyfire/src/assets.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "basic", 3 | "version": "0.1", 4 | "rootDir": "out", 5 | "concepts": [ 6 | { 7 | "name": "concept", 8 | "outputDir": "", 9 | "template": { 10 | "path": "templates/", 11 | "options": [], 12 | "placeholders": [] 13 | } 14 | } 15 | ] 16 | } 17 | -------------------------------------------------------------------------------- /packages/basic-kodyfire/src/generator/generator.ts: -------------------------------------------------------------------------------- 1 | import { IGenerator, ITechnology } from 'kodyfire-core'; 2 | import { Technology } from '../technology'; 3 | 4 | export class Generator implements IGenerator { 5 | technology: ITechnology; 6 | input: any; 7 | output: any; 8 | constructor(params: any, technology: ITechnology = new Technology(params)) { 9 | this.technology = technology; 10 | } 11 | async generate(content: any) { 12 | this.input = content; 13 | this.technology.input = content; 14 | this.technology.rootDir = content.rootDir || this.technology.rootDir; 15 | 16 | // for every concept in concepts list 17 | for (const [key] of this.technology.concepts) { 18 | // eslint-disable-next-line no-prototype-builtins 19 | if (content.hasOwnProperty(key)) { 20 | for (const data of content[key]) { 21 | // do apropriate action 22 | this.output = await this.technology.concepts.get(key)?.generate(data); 23 | } 24 | } else { 25 | // do apropriate action 26 | } 27 | } 28 | // return result 29 | return this.output; 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /packages/basic-kodyfire/src/generator/index.ts: -------------------------------------------------------------------------------- 1 | export { Generator } from './generator'; 2 | -------------------------------------------------------------------------------- /packages/basic-kodyfire/src/index.ts: -------------------------------------------------------------------------------- 1 | export { Kody } from './kody'; 2 | export * from './parser'; 3 | export * from './generator'; 4 | export { Technology } from './technology'; 5 | export { Engine } from './concepts/engine'; 6 | export { Concept } from './concepts/concept'; 7 | export { schema } from './parser/validator/schema'; 8 | -------------------------------------------------------------------------------- /packages/basic-kodyfire/src/parser/extractor.ts: -------------------------------------------------------------------------------- 1 | export const extract: any = () => { 2 | return `This is the extractor`; 3 | }; 4 | -------------------------------------------------------------------------------- /packages/basic-kodyfire/src/parser/index.ts: -------------------------------------------------------------------------------- 1 | export { Parser } from './parser'; 2 | export { Validator } from './validator/validator'; 3 | export { schema } from './validator/schema'; 4 | -------------------------------------------------------------------------------- /packages/basic-kodyfire/src/parser/loader.ts: -------------------------------------------------------------------------------- 1 | export const load: any = () => { 2 | return `This is the load`; 3 | }; 4 | -------------------------------------------------------------------------------- /packages/basic-kodyfire/src/parser/transformer.ts: -------------------------------------------------------------------------------- 1 | export const transform = () => { 2 | return `This is the transformer`; 3 | }; 4 | -------------------------------------------------------------------------------- /packages/basic-kodyfire/src/parser/validator/index.ts: -------------------------------------------------------------------------------- 1 | export { schema } from './schema'; 2 | export { Validator } from './validator'; 3 | -------------------------------------------------------------------------------- /packages/basic-kodyfire/src/parser/validator/schema.ts: -------------------------------------------------------------------------------- 1 | export const concept = { 2 | type: 'object', 3 | properties: { 4 | name: { type: 'string' }, 5 | template: { 6 | type: 'string', 7 | }, 8 | outputDir: { type: 'string' }, 9 | }, 10 | }; 11 | 12 | export const conceptArray: { type: string; items: any } = { 13 | type: 'array', 14 | items: concept, 15 | }; 16 | export const schema = { 17 | type: 'object', 18 | properties: { 19 | project: { type: 'string' }, 20 | name: { type: 'string' }, 21 | rootDir: { type: 'string' }, 22 | concept: conceptArray, 23 | }, 24 | required: ['name'], 25 | }; 26 | -------------------------------------------------------------------------------- /packages/basic-kodyfire/src/parser/validator/validator.ts: -------------------------------------------------------------------------------- 1 | import { IValidator } from 'kodyfire-core'; 2 | import { schema } from './schema'; 3 | import Ajv, { ErrorObject, JSONSchemaType } from 'ajv'; 4 | 5 | export class Validator implements IValidator { 6 | rules: any; 7 | schemaValidator: Ajv; 8 | errors: 9 | | ErrorObject, unknown>[] 10 | | null 11 | | undefined; 12 | constructor(_schema: any = schema) { 13 | this.rules = _schema; 14 | this.schemaValidator = new Ajv(); 15 | } 16 | validate(data: any): boolean { 17 | const schema: JSONSchemaType = this.rules; 18 | 19 | // validate is a type guard for data - type is inferred from schema type 20 | const validate = this.schemaValidator.compile(schema); 21 | 22 | if (validate(data)) { 23 | // data is MyData here 24 | return true; 25 | } else { 26 | this.errors = validate.errors; 27 | console.log(validate.errors); 28 | return false; 29 | } 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /packages/basic-kodyfire/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": "tsconfig", 4 | "lib": ["es2018"], 5 | "declaration": true, 6 | "module": "commonjs", 7 | "moduleResolution": "node", 8 | "esModuleInterop": true, 9 | "resolveJsonModule": true, 10 | "noEmitOnError": true, 11 | "noFallthroughCasesInSwitch": true, 12 | "noImplicitAny": true, 13 | "noImplicitThis": true, 14 | "noUnusedParameters": true, 15 | "noUnusedLocals": true, 16 | "rootDir": "src", 17 | "outDir": "build", 18 | "skipDefaultLibCheck": true, 19 | "skipLibCheck": true, 20 | "sourceMap": true, 21 | "strictNullChecks": true, 22 | "target": "es6", 23 | "types": ["node"] 24 | }, 25 | "include": ["src/**/*"], 26 | "exclude": ["src/*/files/**/*", "node_modules"] 27 | } 28 | -------------------------------------------------------------------------------- /packages/kodyfire-cli/.gitattributes: -------------------------------------------------------------------------------- 1 | *.json linguist-language=JSON-with-Comments -------------------------------------------------------------------------------- /packages/kodyfire-cli/.gitignore: -------------------------------------------------------------------------------- 1 | 2 | # Outputs 3 | src/**/*.js 4 | src/**/*.js.map 5 | src/**/*.d.ts 6 | 7 | # IDEs 8 | .idea/ 9 | jsconfig.json 10 | .vscode/ 11 | 12 | # Misc 13 | node_modules/ 14 | npm-debug.log* 15 | yarn-error.log* 16 | dist 17 | kodyfire.code-workspace 18 | # Mac OSX Finder files. 19 | **/.DS_Store 20 | .DS_Store 21 | src/core 22 | #npm 23 | .npmrc 24 | #api-extractor.json 25 | temp/ 26 | target/ -------------------------------------------------------------------------------- /packages/kodyfire-cli/.npmignore: -------------------------------------------------------------------------------- 1 | 2 | # Ignores TypeScript files, but keeps definitions. 3 | *.ts 4 | !*.d.ts 5 | dist 6 | -------------------------------------------------------------------------------- /packages/kodyfire-cli/LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2018-present, NOQTA, SUARL. 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/batch/index.d.ts: -------------------------------------------------------------------------------- 1 | export {}; 2 | //# sourceMappingURL=index.d.ts.map -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/batch/index.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["index.ts"],"names":[],"mappings":""} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/data.json: -------------------------------------------------------------------------------- 1 | { 2 | "technology": "techno", 3 | "name": "sample", 4 | "version": "0.1", 5 | "templateFolder": "" 6 | } 7 | -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/index.d.ts: -------------------------------------------------------------------------------- 1 | export {}; 2 | //# sourceMappingURL=index.d.ts.map -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/index.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["index.ts"],"names":[],"mappings":""} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/index.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"index.js","sourceRoot":"","sources":["index.ts"],"names":[],"mappings":"AAAA,YAAY,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AACb,oCAAkC;AAClC,mDAAqC;AAErC,MAAM,EAAE,OAAO,EAAE,GAAG,OAAO,CAAC,WAAW,CAAC,CAAC;AAEzC,SAAe,MAAM,CAAC,IAAS;;QAC7B,MAAM,IAAI,GAAG,IAAI,UAAI,CAAC,IAAI,CAAC,CAAC;QAE5B,eAAe;QACf,IAAI,IAAI,GAAG,IAAI,CAAC,KAAK,CAAC,KAAK,CAAC,CAAC;QAC7B,IAAI,mCAAQ,IAAI,GAAK,IAAI,CAAE,CAAC;QAC5B,IAAI,CAAC,SAAS,GAAG,GAAG,IAAI,CAAC,IAAI,WAAW,CAAC;QACzC,MAAM,MAAM,GAAG,MAAM,IAAI,CAAC,QAAQ,CAAC,IAAI,CAAC,CAAC;QACzC,OAAO,MAAM,CAAC;IAChB,CAAC;CAAA;AAED,MAAM,CAAC,OAAO,GAAG,CAAC,OAAuB,EAAE,EAAE;IAC3C,OAAO;SACJ,OAAO,CAAC,QAAQ,CAAC;SACjB,WAAW,CAAC,mCAAmC,CAAC;SAChD,QAAQ,CAAC,QAAQ,EAAE,cAAc,CAAC;SAClC,QAAQ,CAAC,cAAc,EAAE,oBAAoB,CAAC;SAC9C,MAAM,CACL,yCAAyC,EACzC,6EAA6E,EAC7E,QAAQ,CACT;SACA,MAAM,CAAC,CAAO,IAAY,EAAE,UAAkB,EAAE,IAAS,EAAE,EAAE;QAC5D,yEAAyE;QACzE,IAAI;YACF,MAAM,iBAAG,IAAI,EAAE,UAAU,IAAK,IAAI,EAAG,CAAC;SACvC;QAAC,OAAO,KAAU,EAAE;YACnB,OAAO,CAAC,GAAG,CAAC,KAAK,CAAC,CAAC;SACpB;IACH,CAAC,CAAA,CAAC,CAAC;AACP,CAAC,CAAC"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/index.d.ts: -------------------------------------------------------------------------------- 1 | export { Kody } from '.'; 2 | export * from './parser'; 3 | export * from './generator'; 4 | export { Scaffold } from './concepts/scaffold'; 5 | //# sourceMappingURL=index.d.ts.map 6 | -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/index.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,MAAM,QAAQ,CAAC;AAC9B,cAAc,cAAc,CAAC;AAC7B,cAAc,iBAAiB,CAAC;AAChC,OAAO,EAAE,QAAQ,EAAE,MAAM,yBAAyB,CAAC"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/index.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"index.js","sourceRoot":"","sources":["index.ts"],"names":[],"mappings":";;;;;;;;;;;;;AAAA,+BAA8B;AAArB,4FAAA,IAAI,OAAA;AACb,+CAA6B;AAC7B,kDAAgC;AAChC,oDAAmD;AAA1C,oGAAA,QAAQ,OAAA"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/kody.d.ts: -------------------------------------------------------------------------------- 1 | /// 2 | import EventEmitter from 'events'; 3 | import { 4 | BaseKody, 5 | IGenerator, 6 | IKody, 7 | IParser, 8 | ITechnology, 9 | } from 'kodyfire-core'; 10 | export declare class Kody extends BaseKody implements IKody { 11 | [x: string]: any; 12 | parser: IParser; 13 | generator: IGenerator; 14 | technology: ITechnology; 15 | events: EventEmitter; 16 | constructor(params: any); 17 | generate(_content: any): Promise; 18 | parse(content: any): any; 19 | read(source: any): any; 20 | get errors(): any; 21 | get data(): any; 22 | whereami(): string; 23 | whoami(): string; 24 | } 25 | //# sourceMappingURL=kody.d.ts.map 26 | -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/kody.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"kody.d.ts","sourceRoot":"","sources":["kody.ts"],"names":[],"mappings":";AAAA,OAAO,YAAY,MAAM,QAAQ,CAAC;AAClC,OAAO,EACL,QAAQ,EACR,UAAU,EACV,KAAK,EACL,OAAO,EACP,WAAW,EACZ,MAAM,eAAe,CAAC;AAGvB,qBAAa,IAAK,SAAQ,QAAS,YAAW,KAAK;IACjD,CAAC,CAAC,EAAE,MAAM,GAAG,GAAG,CAAC;IACjB,MAAM,EAAE,OAAO,CAAC;IAChB,SAAS,EAAE,UAAU,CAAC;IACtB,UAAU,EAAE,WAAW,CAAC;IACxB,MAAM,EAAE,YAAY,CAAC;gBACT,MAAM,EAAE,GAAG;IASjB,QAAQ,CAAC,QAAQ,EAAE,GAAG;IAG5B,KAAK,CAAC,OAAO,EAAE,GAAG;IAGlB,IAAI,CAAC,MAAM,EAAE,GAAG;IAGhB,IAAI,MAAM,QAET;IACD,IAAI,IAAI,QAEP;IACD,QAAQ,IAAI,MAAM;IAGlB,MAAM,IAAI,MAAM;CAGjB"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/kody.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"kody.js","sourceRoot":"","sources":["kody.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;AAAA,oDAAkC;AAClC,iDAMuB;AACvB,wBAAiD;AAEjD,MAAa,IAAK,SAAQ,wBAAQ;IAMhC,YAAY,MAAW;QACrB,KAAK,EAAE,CAAC;QACR,IAAI,CAAC,MAAM,GAAG,MAAM,CAAC;QACrB,MAAM,SAAS,GAAG,IAAI,YAAS,EAAE,CAAC;QAClC,IAAI,CAAC,MAAM,GAAG,IAAI,SAAM,CAAC,SAAS,CAAC,CAAC;QACpC,IAAI,CAAC,SAAS,GAAG,IAAI,YAAS,CAAC,MAAM,CAAC,CAAC;QACvC,IAAI,CAAC,UAAU,GAAG,IAAI,CAAC,SAAS,CAAC,UAAU,CAAC;QAC5C,IAAI,CAAC,MAAM,GAAG,IAAI,gBAAY,EAAE,CAAC;IACnC,CAAC;IACK,QAAQ,CAAC,QAAa;;YAC1B,MAAM,IAAI,CAAC,SAAS,CAAC,QAAQ,CAAC,QAAQ,CAAC,CAAC;QAC1C,CAAC;KAAA;IACD,KAAK,CAAC,OAAY;QAChB,OAAO,IAAI,CAAC,MAAM,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC;IACpC,CAAC;IACD,IAAI,CAAC,MAAW;QACd,OAAO,IAAI,CAAC,MAAM,CAAC,MAAM,CAAC,MAAM,CAAC,CAAC;IACpC,CAAC;IACD,IAAI,MAAM;QACR,OAAO,IAAI,CAAC,MAAM,CAAC,SAAS,CAAC,MAAM,CAAC;IACtC,CAAC;IACD,IAAI,IAAI;QACN,OAAO,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC;IAC1B,CAAC;IACD,QAAQ;QACN,OAAO,SAAS,CAAC;IACnB,CAAC;IACD,MAAM;QACJ,OAAO,UAAU,CAAC;IACpB,CAAC;CACF;AApCD,oBAoCC"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/assets.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "Kodyfire", 3 | "version": "1.0.0", 4 | "rootDir": "", 5 | "concepts": [ 6 | { 7 | "name": "scaffold", 8 | "template": { 9 | "path": "templates" 10 | } 11 | } 12 | ] 13 | } 14 | -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/concepts/concept.d.ts: -------------------------------------------------------------------------------- 1 | import { IConcept, ITechnology, Source, Technology, TemplateSchema } from 'kodyfire-core'; 2 | import { Engine } from './engine'; 3 | export declare class Concept implements IConcept { 4 | name: string; 5 | defaultAction: string; 6 | source?: Source | undefined; 7 | template: TemplateSchema; 8 | outputDir: string; 9 | technology: Technology; 10 | engine: Engine; 11 | constructor(concept: Partial, technology: ITechnology); 12 | generate(_data: any): void; 13 | underscorize(word: any): any; 14 | } 15 | //# sourceMappingURL=concept.d.ts.map -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/concepts/concept.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"concept.d.ts","sourceRoot":"","sources":["concept.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,QAAQ,EACR,WAAW,EACX,MAAM,EACN,UAAU,EACV,cAAc,EACf,MAAM,eAAe,CAAC;AACvB,OAAO,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC;AAElC,qBAAa,OAAQ,YAAW,QAAQ;IACtC,IAAI,EAAE,MAAM,CAAC;IACb,aAAa,EAAE,MAAM,CAAC;IACtB,MAAM,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;IAC5B,QAAQ,EAAE,cAAc,CAAC;IACzB,SAAS,EAAE,MAAM,CAAC;IAClB,UAAU,EAAE,UAAU,CAAC;IACvB,MAAM,EAAE,MAAM,CAAC;gBACH,OAAO,EAAE,OAAO,CAAC,QAAQ,CAAC,EAAE,UAAU,EAAE,WAAW;IAO/D,QAAQ,CAAC,KAAK,EAAE,GAAG;IAGnB,YAAY,CAAC,IAAI,EAAE,GAAG;CAKvB"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/concepts/concept.js: -------------------------------------------------------------------------------- 1 | "use strict"; 2 | Object.defineProperty(exports, "__esModule", { value: true }); 3 | exports.Concept = void 0; 4 | const kodyfire_core_1 = require("kodyfire-core"); 5 | class Concept { 6 | constructor(concept, technology) { 7 | var _a, _b, _c; 8 | this.source = (_a = concept.source) !== null && _a !== void 0 ? _a : kodyfire_core_1.Source.Template; 9 | this.outputDir = (_b = concept.outputDir) !== null && _b !== void 0 ? _b : ''; 10 | this.name = (_c = concept.name) !== null && _c !== void 0 ? _c : ''; 11 | this.template = concept.template; 12 | this.technology = technology; 13 | } 14 | generate(_data) { 15 | throw new Error('Method should be implemented in child.'); 16 | } 17 | underscorize(word) { 18 | return word.replace(/[A-Z]/g, function (char, index) { 19 | return (index !== 0 ? '_' : '') + char.toLowerCase(); 20 | }); 21 | } 22 | } 23 | exports.Concept = Concept; 24 | //# sourceMappingURL=concept.js.map -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/concepts/concept.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"concept.js","sourceRoot":"","sources":["concept.ts"],"names":[],"mappings":";;;AAAA,iDAMuB;AAGvB,MAAa,OAAO;IAQlB,YAAY,OAA0B,EAAE,UAAuB;;QAC7D,IAAI,CAAC,MAAM,GAAG,MAAA,OAAO,CAAC,MAAM,mCAAI,sBAAM,CAAC,QAAQ,CAAC;QAChD,IAAI,CAAC,SAAS,GAAG,MAAA,OAAO,CAAC,SAAS,mCAAI,EAAE,CAAC;QACzC,IAAI,CAAC,IAAI,GAAG,MAAA,OAAO,CAAC,IAAI,mCAAI,EAAE,CAAC;QAC/B,IAAI,CAAC,QAAQ,GAAG,OAAO,CAAC,QAA0B,CAAC;QACnD,IAAI,CAAC,UAAU,GAAG,UAAU,CAAC;IAC/B,CAAC;IACD,QAAQ,CAAC,KAAU;QACjB,MAAM,IAAI,KAAK,CAAC,wCAAwC,CAAC,CAAC;IAC5D,CAAC;IACD,YAAY,CAAC,IAAS;QACpB,OAAO,IAAI,CAAC,OAAO,CAAC,QAAQ,EAAE,UAAU,IAAS,EAAE,KAAU;YAC3D,OAAO,CAAC,KAAK,KAAK,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,CAAC,GAAG,IAAI,CAAC,WAAW,EAAE,CAAC;QACvD,CAAC,CAAC,CAAC;IACL,CAAC;CACF;AAvBD,0BAuBC"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/concepts/concept.ts: -------------------------------------------------------------------------------- 1 | import { 2 | IConcept, 3 | ITechnology, 4 | Source, 5 | Technology, 6 | TemplateSchema, 7 | } from 'kodyfire-core'; 8 | import { Engine } from './engine'; 9 | 10 | export class Concept implements IConcept { 11 | name: string; 12 | defaultAction: string; 13 | source?: Source | undefined; 14 | template: TemplateSchema; 15 | outputDir: string; 16 | technology: Technology; 17 | engine: Engine; 18 | constructor(concept: Partial, technology: ITechnology) { 19 | this.source = concept.source ?? Source.Template; 20 | this.outputDir = concept.outputDir ?? ''; 21 | this.name = concept.name ?? ''; 22 | this.template = concept.template as TemplateSchema; 23 | this.technology = technology; 24 | } 25 | generate(_data: any) { 26 | throw new Error('Method should be implemented in child.'); 27 | } 28 | underscorize(word: any) { 29 | return word.replace(/[A-Z]/g, function (char: any, index: any) { 30 | return (index !== 0 ? '_' : '') + char.toLowerCase(); 31 | }); 32 | } 33 | } 34 | -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/concepts/engine.d.ts: -------------------------------------------------------------------------------- 1 | /// 2 | export declare class Engine { 3 | builder: any; 4 | constructor(); 5 | registerPartials(): void; 6 | read(path: string, templateName: any): Promise; 7 | compile(template: any, data: any): any; 8 | create(rootDir: string, outputDir: string, filename: any, content: string | Buffer): Promise; 9 | overwrite(rootDir: string, outputDir: string, filename: any, content: string | Buffer): Promise; 10 | createOrOverwrite(rootDir: string, outputDir: string, filename: any, content: string | Buffer): Promise; 11 | } 12 | //# sourceMappingURL=engine.d.ts.map -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/concepts/engine.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"engine.d.ts","sourceRoot":"","sources":["engine.ts"],"names":[],"mappings":";AAOA,qBAAa,MAAM;IACjB,OAAO,EAAE,GAAG,CAAC;;IAMb,gBAAgB;IAsBV,IAAI,CAAC,IAAI,EAAE,MAAM,EAAE,YAAY,EAAE,GAAG;IAO1C,OAAO,CAAC,QAAQ,EAAE,GAAG,EAAE,IAAI,EAAE,GAAG;IAI1B,MAAM,CACV,OAAO,EAAE,MAAM,EACf,SAAS,EAAE,MAAM,EACjB,QAAQ,EAAE,GAAG,EACb,OAAO,EAAE,MAAM,GAAG,MAAM;IAIpB,SAAS,CACb,OAAO,EAAE,MAAM,EACf,SAAS,EAAE,MAAM,EACjB,QAAQ,EAAE,GAAG,EACb,OAAO,EAAE,MAAM,GAAG,MAAM;IAKpB,iBAAiB,CACrB,OAAO,EAAE,MAAM,EACf,SAAS,EAAE,MAAM,EACjB,QAAQ,EAAE,GAAG,EACb,OAAO,EAAE,MAAM,GAAG,MAAM;CAO3B"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/concepts/scaffold.d.ts: -------------------------------------------------------------------------------- 1 | import { IConcept, ITechnology } from 'kodyfire-core'; 2 | import { Concept } from './concept'; 3 | export declare class Scaffold extends Concept { 4 | model: any; 5 | constructor(concept: Partial, technology: ITechnology); 6 | initEngine(): void; 7 | generate(_data: any): Promise; 8 | readFolder(folder: string): Promise; 9 | getFilename(path: string, name: string): string; 10 | } 11 | //# sourceMappingURL=scaffold.d.ts.map -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/concepts/scaffold.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"scaffold.d.ts","sourceRoot":"","sources":["scaffold.ts"],"names":[],"mappings":"AAEA,OAAO,EACL,QAAQ,EACR,WAAW,EAIZ,MAAM,eAAe,CAAC;AAMvB,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AAIpC,qBAAa,QAAS,SAAQ,OAAO;IACnC,KAAK,EAAE,GAAG,CAAC;gBACC,OAAO,EAAE,OAAO,CAAC,QAAQ,CAAC,EAAE,UAAU,EAAE,WAAW;IAI/D,UAAU;IAIJ,QAAQ,CAAC,KAAK,EAAE,GAAG;IA4CnB,UAAU,CAAC,MAAM,EAAE,MAAM,GAAG,OAAO,CAAC,GAAG,EAAE,CAAC;IAYhD,WAAW,CAAC,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,MAAM;CAGvC"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/concepts/templates/.npmignore: -------------------------------------------------------------------------------- 1 | 2 | .npmrc 3 | !*.ts 4 | -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/concepts/templates/basic/.gitignore.template: -------------------------------------------------------------------------------- 1 | 2 | # Outputs 3 | src/**/*.js 4 | src/**/*.js.map 5 | src/**/*.d.ts 6 | 7 | # IDEs 8 | .idea/ 9 | jsconfig.json 10 | .vscode/ 11 | 12 | # Misc 13 | node_modules/ 14 | npm-debug.log* 15 | yarn-error.log* 16 | 17 | # Mac OSX Finder files. 18 | **/.DS_Store 19 | .DS_Store 20 | 21 | #npm 22 | .npmrc 23 | -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/concepts/templates/basic/.npmignore.template: -------------------------------------------------------------------------------- 1 | 2 | # Ignores TypeScript files, but keeps definitions. 3 | *.ts 4 | !*.d.ts 5 | .npmrc 6 | -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/concepts/templates/basic/package.json.template: -------------------------------------------------------------------------------- 1 | { 2 | "name": "<%= dasherize name %>-kodyfire", 3 | "version": "0.0.1", 4 | "description": "Scaffold a <%= dasherize name %> kodyfire", 5 | "main": "build/index.js", 6 | "scripts": { 7 | "test": "echo \"Error: no test specified\" && exit 1", 8 | "build": "tsc -p tsconfig.json", 9 | "postbuild": "npm run copy-files", 10 | "copy-files": "cp -R src/concepts/templates build/concepts", 11 | "watch": "tsc -w" 12 | }, 13 | "kodyfire": { 14 | "id": "<%= dasherize name %>", 15 | "type": "<%= technology %>", 16 | "version": "0.1" 17 | }, 18 | "author": "NOQTA", 19 | "license": "ISC", 20 | "dependencies": { 21 | "@angular-devkit/core": "^12.2.3", 22 | "@angular-devkit/schematics": "^12.2.3", 23 | "ajv": "^8.6.3", 24 | "fs-extra": "^10.0.0", 25 | "handlebars": "^4.7.7", 26 | "handlebars-delimiters": "^1.0.0", 27 | "kodyfire-core": "^0.1.35", 28 | "moment": "^2.29.1", 29 | "pluralize": "^8.0.0", 30 | "typescript": "~4.5.5" 31 | }, 32 | "devDependencies": { 33 | "@types/node": "^12.20.43", 34 | "@types/pluralize": "0.0.29", 35 | "copyfiles": "^2.4.1" 36 | } 37 | } 38 | -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/concepts/templates/basic/src/assets.json.template: -------------------------------------------------------------------------------- 1 | { 2 | "name": "<%= technology %>", 3 | "version": "<%= classify version %>", 4 | "rootDir": "out", 5 | "concepts": [ 6 | { 7 | "name": "concept", 8 | "outputDir": "", 9 | "template": { 10 | "path": "templates/", 11 | "options": [ 12 | ], 13 | "placeholders": [ 14 | ] 15 | } 16 | } 17 | ] 18 | 19 | } -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/concepts/templates/basic/src/generator/index.ts.template: -------------------------------------------------------------------------------- 1 | export { Generator } from "./generator"; -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/concepts/templates/basic/src/index.ts.template: -------------------------------------------------------------------------------- 1 | export { Kody } from "./kody"; 2 | export * from './parser'; 3 | export * from './generator'; 4 | export { Technology } from './technology'; 5 | export { Concept } from './concepts/concept' -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/concepts/templates/basic/src/parser/extractor.ts: -------------------------------------------------------------------------------- 1 | export const extract: any = () => { 2 | return `This is the extractor`; 3 | }; 4 | -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/concepts/templates/basic/src/parser/index.ts: -------------------------------------------------------------------------------- 1 | export { Parser } from './parser'; 2 | export { Validator } from './validator/validator'; 3 | export { schema } from './validator/schema'; 4 | -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/concepts/templates/basic/src/parser/loader.ts: -------------------------------------------------------------------------------- 1 | export const load: any = () => { 2 | return `This is the load`; 3 | }; 4 | -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/concepts/templates/basic/src/parser/transformer.ts: -------------------------------------------------------------------------------- 1 | export const transform = () => { 2 | return `This is the transformer`; 3 | }; 4 | -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/concepts/templates/basic/src/parser/validator/index.ts: -------------------------------------------------------------------------------- 1 | export { schema } from './schema'; 2 | export { Validator } from './validator'; 3 | -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/concepts/templates/basic/src/parser/validator/schema.ts: -------------------------------------------------------------------------------- 1 | export const concept = { 2 | type: 'object', 3 | properties: { 4 | name: { type: 'string' }, 5 | template: { 6 | type: 'string', 7 | enum: ['sample.html.template'], 8 | }, 9 | outputDir: { type: 'string' }, 10 | }, 11 | }; 12 | 13 | export const conceptArray = { 14 | type: 'array', 15 | items: concept, 16 | }; 17 | export const schema = { 18 | type: 'object', 19 | properties: { 20 | project: { type: 'string' }, 21 | name: { type: 'string' }, 22 | rootDir: { type: 'string' }, 23 | concept: conceptArray, 24 | }, 25 | required: ['name'], 26 | }; 27 | -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/concepts/templates/basic/src/parser/validator/validator.ts: -------------------------------------------------------------------------------- 1 | import { IValidator } from 'kodyfire-core'; 2 | import { schema } from './schema'; 3 | import Ajv, { ErrorObject, JSONSchemaType } from 'ajv'; 4 | 5 | export class Validator implements IValidator { 6 | rules: any; 7 | schemaValidator: Ajv; 8 | errors: 9 | | ErrorObject, unknown>[] 10 | | null 11 | | undefined; 12 | constructor() { 13 | this.rules = schema; 14 | this.schemaValidator = new Ajv(); 15 | } 16 | validate(data: any): boolean { 17 | const schema: JSONSchemaType = this.rules; 18 | 19 | // validate is a type guard for data - type is inferred from schema type 20 | const validate = this.schemaValidator.compile(schema); 21 | 22 | if (validate(data)) { 23 | // data is MyData here 24 | return true; 25 | } else { 26 | this.errors = validate.errors; 27 | return false; 28 | } 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/concepts/templates/basic/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": "tsconfig", 4 | "lib": ["es2018"], 5 | "declaration": true, 6 | "module": "commonjs", 7 | "moduleResolution": "node", 8 | "esModuleInterop": true, 9 | "resolveJsonModule": true, 10 | "noEmitOnError": true, 11 | "noFallthroughCasesInSwitch": true, 12 | "noImplicitAny": true, 13 | "noImplicitThis": true, 14 | "noUnusedParameters": true, 15 | "noUnusedLocals": true, 16 | "rootDir": "src", 17 | "outDir": "build", 18 | "skipDefaultLibCheck": true, 19 | "skipLibCheck": true, 20 | "sourceMap": true, 21 | "strictNullChecks": true, 22 | "target": "ES6", 23 | "types": ["node"] 24 | }, 25 | "include": ["src/**/*"], 26 | "exclude": ["src/*/files/**/*", "node_modules"] 27 | } 28 | -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/concepts/templates/simple/.gitignore.template: -------------------------------------------------------------------------------- 1 | 2 | # Outputs 3 | src/**/*.js 4 | src/**/*.js.map 5 | src/**/*.d.ts 6 | 7 | # IDEs 8 | .idea/ 9 | jsconfig.json 10 | .vscode/ 11 | 12 | # Misc 13 | node_modules/ 14 | npm-debug.log* 15 | yarn-error.log* 16 | 17 | # Mac OSX Finder files. 18 | **/.DS_Store 19 | .DS_Store 20 | 21 | #npm 22 | .npmrc 23 | -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/concepts/templates/simple/.npmignore.template: -------------------------------------------------------------------------------- 1 | 2 | # Ignores TypeScript files, but keeps definitions. 3 | *.ts 4 | !*.d.ts 5 | .npmrc 6 | -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/concepts/templates/simple/package.json.template: -------------------------------------------------------------------------------- 1 | { 2 | "name": "<%= name %>-kodyfire", 3 | "version": "0.0.1", 4 | "description": "Generate x with <%= name %> kodyfire", 5 | "main": "build/index.js", 6 | "scripts": { 7 | "test": "echo \"Error: no test specified\" && exit 1", 8 | "build": "tsc -p tsconfig.json", 9 | "postbuild": "npm run copy-files", 10 | "copy-files": "cp -R src/templates build", 11 | "watch": "tsc -w" 12 | }, 13 | "kodyfire": { 14 | "id": "<%= name %>", 15 | "type": "<%= technology %>", 16 | "version": "0.1" 17 | }, 18 | "author": "NOQTA", 19 | "license": "ISC", 20 | "dependencies": { 21 | "@angular-devkit/core": "^12.2.3", 22 | "@angular-devkit/schematics": "^12.2.3", 23 | "ajv": "^8.6.3", 24 | "basic-kodyfire": "^0.1.35", 25 | "fs-extra": "^10.0.0", 26 | "handlebars": "^4.7.7", 27 | "handlebars-delimiters": "^1.0.0", 28 | "kodyfire-core": "^0.1.35", 29 | "moment": "^2.29.1", 30 | "pluralize": "^8.0.0", 31 | "typescript": "~4.5.5" 32 | }, 33 | "devDependencies": { 34 | "@types/node": "^12.20.43", 35 | "@types/pluralize": "0.0.29", 36 | "copyfiles": "^2.4.1" 37 | } 38 | } 39 | -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/concepts/templates/simple/src/assets.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "basic", 3 | "version": "0.1", 4 | "rootDir": "out", 5 | "concepts": [ 6 | { 7 | "name": "concept", 8 | "outputDir": "", 9 | "template": { 10 | "path": "templates/", 11 | "options": [], 12 | "placeholders": [] 13 | } 14 | } 15 | ] 16 | } 17 | -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/concepts/templates/simple/src/index.ts: -------------------------------------------------------------------------------- 1 | export * from 'basic-kodyfire'; 2 | export { Technology } from './technology'; 3 | export { schema } from './schema'; 4 | export { Concept } from './concept'; 5 | export { Kody } from './kody'; 6 | -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/concepts/templates/simple/src/kody.ts: -------------------------------------------------------------------------------- 1 | import { Kody as BaseKody } from 'basic-kodyfire'; 2 | import { Technology } from './technology'; 3 | import { schema } from './schema'; 4 | import assets from './assets.json'; 5 | 6 | export class Kody extends BaseKody { 7 | constructor( 8 | params: any, 9 | _schema = schema, 10 | technology = new Technology(params, assets) 11 | ) { 12 | // override the templateDir property to point to our directory 13 | params.templatesPath = __dirname; 14 | // override the assets.json to include custom concepts when needed 15 | super(params, schema, technology); 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/concepts/templates/simple/src/schema.ts: -------------------------------------------------------------------------------- 1 | export const concept = { 2 | type: 'object', 3 | properties: { 4 | name: { type: 'string' }, 5 | template: { 6 | type: 'string', 7 | }, 8 | outputDir: { type: 'string' }, 9 | }, 10 | }; 11 | 12 | export const conceptArray = { 13 | type: 'array', 14 | items: concept, 15 | }; 16 | export const schema = { 17 | type: 'object', 18 | properties: { 19 | project: { type: 'string' }, 20 | name: { type: 'string' }, 21 | rootDir: { type: 'string' }, 22 | concept: conceptArray, 23 | }, 24 | required: ['name'], 25 | }; 26 | -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/concepts/templates/simple/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": "tsconfig", 4 | "lib": ["es2018"], 5 | "declaration": true, 6 | "module": "commonjs", 7 | "moduleResolution": "node", 8 | "esModuleInterop": true, 9 | "allowJs": true, 10 | "resolveJsonModule": true, 11 | "noEmitOnError": true, 12 | "noFallthroughCasesInSwitch": true, 13 | "noImplicitAny": true, 14 | "noImplicitThis": true, 15 | "noUnusedParameters": true, 16 | "noUnusedLocals": true, 17 | "rootDir": "src", 18 | "outDir": "build", 19 | "skipDefaultLibCheck": true, 20 | "skipLibCheck": true, 21 | "sourceMap": true, 22 | "strictNullChecks": true, 23 | "target": "ES6", 24 | "types": ["node"] 25 | }, 26 | "include": ["src/**/*"], 27 | "exclude": ["src/*/files/**/*", "node_modules"] 28 | } 29 | -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/generator/generator.d.ts: -------------------------------------------------------------------------------- 1 | import { Tree } from '@angular-devkit/schematics'; 2 | import { IGenerator, ITechnology } from 'kodyfire-core'; 3 | export declare class Generator implements IGenerator { 4 | technology: ITechnology; 5 | input: any; 6 | tree: Tree; 7 | constructor(params: any, technology?: ITechnology); 8 | generate(content: any): Promise; 9 | } 10 | //# sourceMappingURL=generator.d.ts.map -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/generator/generator.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"generator.d.ts","sourceRoot":"","sources":["generator.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,IAAI,EAAY,MAAM,4BAA4B,CAAC;AAC5D,OAAO,EAAE,UAAU,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAGxD,qBAAa,SAAU,YAAW,UAAU;IAC1C,UAAU,EAAE,WAAW,CAAC;IACxB,KAAK,EAAE,GAAG,CAAC;IACX,IAAI,EAAE,IAAI,CAAC;gBACC,MAAM,EAAE,GAAG,EAAE,UAAU,GAAE,WAAoC;IAQnE,QAAQ,CAAC,OAAO,EAAE,GAAG,GAAG,OAAO,CAAC,IAAI,CAAC;CAW5C"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/generator/generator.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"generator.js","sourceRoot":"","sources":["generator.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,+CAA4D;AAC5D,oDAA2D;AAC3D,2DAA4D;AAE5D,8CAA2C;AAE3C,MAAa,SAAS;IAIpB,YAAY,MAAW,EAAE,aAA0B,IAAI,uBAAU,CAAC,MAAM,CAAC;QACvE,IAAI,CAAC,UAAU,GAAG,UAAU,CAAC;QAC7B,MAAM,QAAQ,GAAG,IAAI,gBAAS,CAAC,UAAU,CACvC,IAAI,qBAAc,EAAE,EACpB,IAAA,gBAAS,EAAC,OAAO,CAAC,GAAG,EAAE,CAAC,CACzB,CAAC;QACF,IAAI,CAAC,IAAI,GAAG,IAAI,qBAAQ,CAAC,QAAQ,CAAC,CAAC;IACrC,CAAC;IACK,QAAQ,CAAC,OAAY;;;YACzB,IAAI,CAAC,KAAK,GAAG,OAAO,CAAC;YACrB,IAAI,CAAC,UAAU,CAAC,KAAK,GAAG,OAAO,CAAC;YAChC,qCAAqC;YACrC,KAAK,MAAM,CAAC,GAAG,CAAC,IAAI,IAAI,CAAC,UAAU,CAAC,QAAQ,EAAE;gBAC5C,uBAAuB;gBACvB,IAAI,CAAC,IAAI,GAAG,MAAM,CAAA,MAAA,IAAI,CAAC,UAAU,CAAC,QAAQ,CAAC,GAAG,CAAC,GAAG,CAAC,0CAAE,QAAQ,CAAC,OAAO,CAAC,CAAA,CAAC;aACxE;YACD,gBAAgB;YAChB,OAAO,IAAI,CAAC,IAAI,CAAC;;KAClB;CACF;AAvBD,8BAuBC"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/generator/generator.ts: -------------------------------------------------------------------------------- 1 | import { normalize, virtualFs } from '@angular-devkit/core'; 2 | import { NodeJsSyncHost } from '@angular-devkit/core/node'; 3 | import { Tree, HostTree } from '@angular-devkit/schematics'; 4 | import { IGenerator, ITechnology } from 'kodyfire-core'; 5 | import { Technology } from '../technology'; 6 | 7 | export class Generator implements IGenerator { 8 | technology: ITechnology; 9 | input: any; 10 | tree: Tree; 11 | constructor(params: any, technology: ITechnology = new Technology(params)) { 12 | this.technology = technology; 13 | const _backend = new virtualFs.ScopedHost( 14 | new NodeJsSyncHost(), 15 | normalize(process.cwd()) 16 | ); 17 | this.tree = new HostTree(_backend); 18 | } 19 | async generate(content: any): Promise { 20 | this.input = content; 21 | this.technology.input = content; 22 | // for every concept in concepts list 23 | for (const [key] of this.technology.concepts) { 24 | // do apropriate action 25 | this.tree = await this.technology.concepts.get(key)?.generate(content); 26 | } 27 | // return result 28 | return this.tree; 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/generator/index.d.ts: -------------------------------------------------------------------------------- 1 | export { Generator } from './generator'; 2 | //# sourceMappingURL=index.d.ts.map -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/generator/index.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/generator/index.js: -------------------------------------------------------------------------------- 1 | "use strict"; 2 | Object.defineProperty(exports, "__esModule", { value: true }); 3 | exports.Generator = void 0; 4 | var generator_1 = require("./generator"); 5 | Object.defineProperty(exports, "Generator", { enumerable: true, get: function () { return generator_1.Generator; } }); 6 | //# sourceMappingURL=index.js.map -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/generator/index.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"index.js","sourceRoot":"","sources":["index.ts"],"names":[],"mappings":";;;AAAA,yCAAwC;AAA/B,sGAAA,SAAS,OAAA"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/generator/index.ts: -------------------------------------------------------------------------------- 1 | export { Generator } from './generator'; 2 | -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/index.d.ts: -------------------------------------------------------------------------------- 1 | export { Kody } from './kody'; 2 | export * from './parser'; 3 | export * from './generator'; 4 | export { Technology } from './technology'; 5 | export { Scaffold } from './concepts/scaffold'; 6 | //# sourceMappingURL=index.d.ts.map -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/index.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,MAAM,QAAQ,CAAC;AAC9B,cAAc,UAAU,CAAC;AACzB,cAAc,aAAa,CAAC;AAC5B,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAC1C,OAAO,EAAE,QAAQ,EAAE,MAAM,qBAAqB,CAAC"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/index.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"index.js","sourceRoot":"","sources":["index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;AAAA,+BAA8B;AAArB,4FAAA,IAAI,OAAA;AACb,2CAAyB;AACzB,8CAA4B;AAC5B,2CAA0C;AAAjC,wGAAA,UAAU,OAAA;AACnB,gDAA+C;AAAtC,oGAAA,QAAQ,OAAA"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/index.ts: -------------------------------------------------------------------------------- 1 | export { Kody } from './kody'; 2 | export * from './parser'; 3 | export * from './generator'; 4 | export { Technology } from './technology'; 5 | export { Scaffold } from './concepts/scaffold'; 6 | -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/kody.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"kody.d.ts","sourceRoot":"","sources":["kody.ts"],"names":[],"mappings":";AAAA,OAAO,YAAY,MAAM,QAAQ,CAAC;AAClC,OAAO,EACL,QAAQ,EACR,UAAU,EACV,KAAK,EACL,OAAO,EACP,WAAW,EACZ,MAAM,eAAe,CAAC;AACvB,OAAO,EAAwC,UAAU,EAAE,MAAM,GAAG,CAAC;AAErE,qBAAa,IAAK,SAAQ,QAAS,YAAW,KAAK;IACjD,CAAC,CAAC,EAAE,MAAM,GAAG,GAAG,CAAC;IACjB,MAAM,EAAE,OAAO,CAAC;IAChB,SAAS,EAAE,UAAU,CAAC;IACtB,UAAU,EAAE,WAAW,CAAC;IACxB,MAAM,EAAE,YAAY,CAAC;gBAEnB,MAAM,EAAE,GAAG,EACX,OAAO;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;KAAS,EAChB,UAAU,aAAyB;IAU/B,QAAQ,CAAC,QAAQ,EAAE,GAAG;IAG5B,KAAK,CAAC,OAAO,EAAE,GAAG;IAGlB,IAAI,CAAC,MAAM,EAAE,GAAG;IAGhB,IAAI,MAAM,QAET;IACD,IAAI,IAAI,QAEP;IACD,QAAQ,IAAI,MAAM;IAGlB,MAAM,IAAI,MAAM;CAGjB"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/kody.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"kody.js","sourceRoot":"","sources":["kody.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;AAAA,oDAAkC;AAClC,iDAMuB;AACvB,wBAAqE;AAErE,MAAa,IAAK,SAAQ,wBAAQ;IAMhC,YACE,MAAW,EACX,OAAO,GAAG,SAAM,EAChB,UAAU,GAAG,IAAI,aAAU,CAAC,MAAM,CAAC;QAEnC,KAAK,EAAE,CAAC;QACR,IAAI,CAAC,MAAM,GAAG,MAAM,CAAC;QACrB,MAAM,SAAS,GAAG,IAAI,YAAS,EAAE,CAAC;QAClC,IAAI,CAAC,MAAM,GAAG,IAAI,SAAM,CAAC,SAAS,CAAC,CAAC;QACpC,IAAI,CAAC,SAAS,GAAG,IAAI,YAAS,CAAC,MAAM,CAAC,CAAC;QACvC,IAAI,CAAC,UAAU,GAAG,UAAU,CAAC;QAC7B,IAAI,CAAC,MAAM,GAAG,IAAI,gBAAY,EAAE,CAAC;IACnC,CAAC;IACK,QAAQ,CAAC,QAAa;;YAC1B,MAAM,IAAI,CAAC,SAAS,CAAC,QAAQ,CAAC,QAAQ,CAAC,CAAC;QAC1C,CAAC;KAAA;IACD,KAAK,CAAC,OAAY;QAChB,OAAO,IAAI,CAAC,MAAM,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC;IACpC,CAAC;IACD,IAAI,CAAC,MAAW;QACd,OAAO,IAAI,CAAC,MAAM,CAAC,MAAM,CAAC,MAAM,CAAC,CAAC;IACpC,CAAC;IACD,IAAI,MAAM;QACR,OAAO,IAAI,CAAC,MAAM,CAAC,SAAS,CAAC,MAAM,CAAC;IACtC,CAAC;IACD,IAAI,IAAI;QACN,OAAO,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC;IAC1B,CAAC;IACD,QAAQ;QACN,OAAO,SAAS,CAAC;IACnB,CAAC;IACD,MAAM;QACJ,OAAO,UAAU,CAAC;IACpB,CAAC;CACF;AAxCD,oBAwCC"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/parser/extractor.d.ts: -------------------------------------------------------------------------------- 1 | export declare const extract: any; 2 | //# sourceMappingURL=extractor.d.ts.map -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/parser/extractor.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"extractor.d.ts","sourceRoot":"","sources":["extractor.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,OAAO,EAAE,GAErB,CAAC"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/parser/extractor.js: -------------------------------------------------------------------------------- 1 | "use strict"; 2 | Object.defineProperty(exports, "__esModule", { value: true }); 3 | exports.extract = void 0; 4 | const extract = () => { 5 | return `This is the extractor`; 6 | }; 7 | exports.extract = extract; 8 | //# sourceMappingURL=extractor.js.map -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/parser/extractor.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"extractor.js","sourceRoot":"","sources":["extractor.ts"],"names":[],"mappings":";;;AAAO,MAAM,OAAO,GAAQ,GAAG,EAAE;IAC/B,OAAO,uBAAuB,CAAC;AACjC,CAAC,CAAC;AAFW,QAAA,OAAO,WAElB"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/parser/extractor.ts: -------------------------------------------------------------------------------- 1 | export const extract: any = () => { 2 | return `This is the extractor`; 3 | }; 4 | -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/parser/index.d.ts: -------------------------------------------------------------------------------- 1 | export { Parser } from './parser'; 2 | export { Validator } from './validator/validator'; 3 | export { schema } from './validator/schema'; 4 | //# sourceMappingURL=index.d.ts.map -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/parser/index.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC;AAClC,OAAO,EAAE,SAAS,EAAE,MAAM,uBAAuB,CAAC;AAClD,OAAO,EAAE,MAAM,EAAE,MAAM,oBAAoB,CAAC"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/parser/index.js: -------------------------------------------------------------------------------- 1 | "use strict"; 2 | Object.defineProperty(exports, "__esModule", { value: true }); 3 | exports.schema = exports.Validator = exports.Parser = void 0; 4 | var parser_1 = require("./parser"); 5 | Object.defineProperty(exports, "Parser", { enumerable: true, get: function () { return parser_1.Parser; } }); 6 | var validator_1 = require("./validator/validator"); 7 | Object.defineProperty(exports, "Validator", { enumerable: true, get: function () { return validator_1.Validator; } }); 8 | var schema_1 = require("./validator/schema"); 9 | Object.defineProperty(exports, "schema", { enumerable: true, get: function () { return schema_1.schema; } }); 10 | //# sourceMappingURL=index.js.map -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/parser/index.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"index.js","sourceRoot":"","sources":["index.ts"],"names":[],"mappings":";;;AAAA,mCAAkC;AAAzB,gGAAA,MAAM,OAAA;AACf,mDAAkD;AAAzC,sGAAA,SAAS,OAAA;AAClB,6CAA4C;AAAnC,gGAAA,MAAM,OAAA"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/parser/index.ts: -------------------------------------------------------------------------------- 1 | export { Parser } from './parser'; 2 | export { Validator } from './validator/validator'; 3 | export { schema } from './validator/schema'; 4 | -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/parser/loader.d.ts: -------------------------------------------------------------------------------- 1 | export declare const load: any; 2 | //# sourceMappingURL=loader.d.ts.map -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/parser/loader.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"loader.d.ts","sourceRoot":"","sources":["loader.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,IAAI,EAAE,GAElB,CAAC"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/parser/loader.js: -------------------------------------------------------------------------------- 1 | "use strict"; 2 | Object.defineProperty(exports, "__esModule", { value: true }); 3 | exports.load = void 0; 4 | const load = () => { 5 | return `This is the load`; 6 | }; 7 | exports.load = load; 8 | //# sourceMappingURL=loader.js.map -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/parser/loader.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"loader.js","sourceRoot":"","sources":["loader.ts"],"names":[],"mappings":";;;AAAO,MAAM,IAAI,GAAQ,GAAG,EAAE;IAC5B,OAAO,kBAAkB,CAAC;AAC5B,CAAC,CAAC;AAFW,QAAA,IAAI,QAEf"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/parser/loader.ts: -------------------------------------------------------------------------------- 1 | export const load: any = () => { 2 | return `This is the load`; 3 | }; 4 | -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/parser/parser.d.ts: -------------------------------------------------------------------------------- 1 | import { IParser, IValidator } from 'kodyfire-core'; 2 | export declare class Parser implements IParser { 3 | validator: IValidator; 4 | requiresExtract: boolean; 5 | requiresTansform: boolean; 6 | requiresLoad: boolean; 7 | data: any; 8 | constructor(validator: IValidator); 9 | reader(source: string): any; 10 | parse(data: any): any; 11 | validate: (data: any) => boolean; 12 | extractor: any; 13 | transformer: () => string; 14 | loader: () => any; 15 | readfile(filepath: any): any; 16 | write(filepath: any, data: any): void; 17 | } 18 | //# sourceMappingURL=parser.d.ts.map -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/parser/parser.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"parser.d.ts","sourceRoot":"","sources":["parser.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,OAAO,EAAE,UAAU,EAAQ,MAAM,eAAe,CAAC;AAG1D,qBAAa,MAAO,YAAW,OAAO;IACpC,SAAS,EAAE,UAAU,CAAC;IACtB,eAAe,EAAE,OAAO,CAAC;IACzB,gBAAgB,EAAE,OAAO,CAAC;IAC1B,YAAY,EAAE,OAAO,CAAC;IACtB,IAAI,EAAE,GAAG,CAAC;gBACE,SAAS,EAAE,UAAU;IAMjC,MAAM,CAAC,MAAM,EAAE,MAAM;IAIrB,KAAK,CAAC,IAAI,EAAE,GAAG;IAQf,QAAQ,SAAU,GAAG,aAEnB;IACF,SAAS,EAAE,GAAG,CAGZ;IAEF,WAAW,eAGT;IAEF,MAAM,YAEJ;IACF,QAAQ,CAAC,QAAQ,EAAE,GAAG;IAUtB,KAAK,CAAC,QAAQ,EAAE,GAAG,EAAE,IAAI,EAAE,GAAG;CAG/B"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/parser/transformer.d.ts: -------------------------------------------------------------------------------- 1 | export declare const transform: () => string; 2 | //# sourceMappingURL=transformer.d.ts.map -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/parser/transformer.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"transformer.d.ts","sourceRoot":"","sources":["transformer.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,SAAS,cAErB,CAAC"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/parser/transformer.js: -------------------------------------------------------------------------------- 1 | "use strict"; 2 | Object.defineProperty(exports, "__esModule", { value: true }); 3 | exports.transform = void 0; 4 | const transform = () => { 5 | return `This is the transformer`; 6 | }; 7 | exports.transform = transform; 8 | //# sourceMappingURL=transformer.js.map -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/parser/transformer.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"transformer.js","sourceRoot":"","sources":["transformer.ts"],"names":[],"mappings":";;;AAAO,MAAM,SAAS,GAAG,GAAG,EAAE;IAC5B,OAAO,yBAAyB,CAAC;AACnC,CAAC,CAAC;AAFW,QAAA,SAAS,aAEpB"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/parser/transformer.ts: -------------------------------------------------------------------------------- 1 | export const transform = () => { 2 | return `This is the transformer`; 3 | }; 4 | -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/parser/validator.d.ts: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nooqta/kodyfire/82d1cb624cfc5dacade7a92fc274f1ca589cc37e/packages/kodyfire-cli/commands/create/kody/src/parser/validator.d.ts -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/parser/validator/index.d.ts: -------------------------------------------------------------------------------- 1 | export { schema } from './schema'; 2 | export { Validator } from './validator'; 3 | //# sourceMappingURL=index.d.ts.map -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/parser/validator/index.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC;AAClC,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/parser/validator/index.js: -------------------------------------------------------------------------------- 1 | "use strict"; 2 | Object.defineProperty(exports, "__esModule", { value: true }); 3 | exports.Validator = exports.schema = void 0; 4 | var schema_1 = require("./schema"); 5 | Object.defineProperty(exports, "schema", { enumerable: true, get: function () { return schema_1.schema; } }); 6 | var validator_1 = require("./validator"); 7 | Object.defineProperty(exports, "Validator", { enumerable: true, get: function () { return validator_1.Validator; } }); 8 | //# sourceMappingURL=index.js.map -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/parser/validator/index.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"index.js","sourceRoot":"","sources":["index.ts"],"names":[],"mappings":";;;AAAA,mCAAkC;AAAzB,gGAAA,MAAM,OAAA;AACf,yCAAwC;AAA/B,sGAAA,SAAS,OAAA"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/parser/validator/index.ts: -------------------------------------------------------------------------------- 1 | export { schema } from './schema'; 2 | export { Validator } from './validator'; 3 | -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/parser/validator/schema.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"schema.d.ts","sourceRoot":"","sources":["schema.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,OAAO;;;;;;;;;;;;;;;;;CAWnB,CAAC;AAEF,eAAO,MAAM,YAAY;;;;;;;;;;;;;;;;;;;;CAGxB,CAAC;AACF,eAAO,MAAM,MAAM;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CASlB,CAAC"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/parser/validator/schema.js: -------------------------------------------------------------------------------- 1 | "use strict"; 2 | Object.defineProperty(exports, "__esModule", { value: true }); 3 | exports.schema = exports.conceptArray = exports.concept = void 0; 4 | exports.concept = { 5 | type: 'object', 6 | properties: { 7 | anis: { type: 'string' }, 8 | name: { type: 'string' }, 9 | template: { 10 | type: 'string', 11 | enum: ['sample.html.template'], 12 | }, 13 | outputDir: { type: 'string' }, 14 | }, 15 | }; 16 | exports.conceptArray = { 17 | type: 'array', 18 | items: exports.concept, 19 | }; 20 | exports.schema = { 21 | type: 'object', 22 | properties: { 23 | project: { type: 'string' }, 24 | name: { type: 'string' }, 25 | rootDir: { type: 'string' }, 26 | concept: exports.conceptArray, 27 | }, 28 | required: ['name'], 29 | }; 30 | //# sourceMappingURL=schema.js.map -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/parser/validator/schema.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"schema.js","sourceRoot":"","sources":["schema.ts"],"names":[],"mappings":";;;AAAa,QAAA,OAAO,GAAG;IACrB,IAAI,EAAE,QAAQ;IACd,UAAU,EAAE;QACV,IAAI,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE;QACxB,IAAI,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE;QACxB,QAAQ,EAAE;YACR,IAAI,EAAE,QAAQ;YACd,IAAI,EAAE,CAAC,sBAAsB,CAAC;SAC/B;QACD,SAAS,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE;KAC9B;CACF,CAAC;AAEW,QAAA,YAAY,GAAG;IAC1B,IAAI,EAAE,OAAO;IACb,KAAK,EAAE,eAAO;CACf,CAAC;AACW,QAAA,MAAM,GAAG;IACpB,IAAI,EAAE,QAAQ;IACd,UAAU,EAAE;QACV,OAAO,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE;QAC3B,IAAI,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE;QACxB,OAAO,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE;QAC3B,OAAO,EAAE,oBAAY;KACtB;IACD,QAAQ,EAAE,CAAC,MAAM,CAAC;CACnB,CAAC"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/parser/validator/schema.ts: -------------------------------------------------------------------------------- 1 | export const concept = { 2 | type: 'object', 3 | properties: { 4 | anis: { type: 'string' }, 5 | name: { type: 'string' }, 6 | template: { 7 | type: 'string', 8 | enum: ['sample.html.template'], 9 | }, 10 | outputDir: { type: 'string' }, 11 | }, 12 | }; 13 | 14 | export const conceptArray = { 15 | type: 'array', 16 | items: concept, 17 | }; 18 | export const schema = { 19 | type: 'object', 20 | properties: { 21 | project: { type: 'string' }, 22 | name: { type: 'string' }, 23 | rootDir: { type: 'string' }, 24 | concept: conceptArray, 25 | }, 26 | required: ['name'], 27 | }; 28 | -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/parser/validator/validator.d.ts: -------------------------------------------------------------------------------- 1 | import { IValidator } from 'kodyfire-core'; 2 | import Ajv, { ErrorObject } from 'ajv'; 3 | export declare class Validator implements IValidator { 4 | rules: any; 5 | schemaValidator: Ajv; 6 | errors: ErrorObject, unknown>[] | null | undefined; 7 | constructor(); 8 | validate(data: any): boolean; 9 | } 10 | //# sourceMappingURL=validator.d.ts.map -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/parser/validator/validator.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"validator.d.ts","sourceRoot":"","sources":["validator.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAE3C,OAAO,GAAG,EAAE,EAAE,WAAW,EAAkB,MAAM,KAAK,CAAC;AAEvD,qBAAa,SAAU,YAAW,UAAU;IAC1C,KAAK,EAAE,GAAG,CAAC;IACX,eAAe,EAAE,GAAG,CAAC;IACrB,MAAM,EACF,WAAW,CAAC,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,EAAE,OAAO,CAAC,EAAE,GACnD,IAAI,GACJ,SAAS,CAAC;;IAKd,QAAQ,CAAC,IAAI,EAAE,GAAG,GAAG,OAAO;CAe7B"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/parser/validator/validator.js: -------------------------------------------------------------------------------- 1 | "use strict"; 2 | var __importDefault = (this && this.__importDefault) || function (mod) { 3 | return (mod && mod.__esModule) ? mod : { "default": mod }; 4 | }; 5 | Object.defineProperty(exports, "__esModule", { value: true }); 6 | exports.Validator = void 0; 7 | const schema_1 = require("./schema"); 8 | const ajv_1 = __importDefault(require("ajv")); 9 | class Validator { 10 | constructor() { 11 | this.rules = schema_1.schema; 12 | this.schemaValidator = new ajv_1.default(); 13 | } 14 | validate(data) { 15 | const schema = this.rules; 16 | // validate is a type guard for data - type is inferred from schema type 17 | const validate = this.schemaValidator.compile(schema); 18 | if (validate(data)) { 19 | // data is MyData here 20 | return true; 21 | } 22 | else { 23 | this.errors = validate.errors; 24 | console.log(validate.errors); 25 | return false; 26 | } 27 | } 28 | } 29 | exports.Validator = Validator; 30 | //# sourceMappingURL=validator.js.map -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/parser/validator/validator.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"validator.js","sourceRoot":"","sources":["validator.ts"],"names":[],"mappings":";;;;;;AACA,qCAAkC;AAClC,8CAAuD;AAEvD,MAAa,SAAS;IAOpB;QACE,IAAI,CAAC,KAAK,GAAG,eAAM,CAAC;QACpB,IAAI,CAAC,eAAe,GAAG,IAAI,aAAG,EAAE,CAAC;IACnC,CAAC;IACD,QAAQ,CAAC,IAAS;QAChB,MAAM,MAAM,GAAgC,IAAI,CAAC,KAAK,CAAC;QAEvD,wEAAwE;QACxE,MAAM,QAAQ,GAAG,IAAI,CAAC,eAAe,CAAC,OAAO,CAAC,MAAM,CAAC,CAAC;QAEtD,IAAI,QAAQ,CAAC,IAAI,CAAC,EAAE;YAClB,sBAAsB;YACtB,OAAO,IAAI,CAAC;SACb;aAAM;YACL,IAAI,CAAC,MAAM,GAAG,QAAQ,CAAC,MAAM,CAAC;YAC9B,OAAO,CAAC,GAAG,CAAC,QAAQ,CAAC,MAAM,CAAC,CAAC;YAC7B,OAAO,KAAK,CAAC;SACd;IACH,CAAC;CACF;AA1BD,8BA0BC"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/parser/validator/validator.ts: -------------------------------------------------------------------------------- 1 | import { IValidator } from 'kodyfire-core'; 2 | import { schema } from './schema'; 3 | import Ajv, { ErrorObject, JSONSchemaType } from 'ajv'; 4 | 5 | export class Validator implements IValidator { 6 | rules: any; 7 | schemaValidator: Ajv; 8 | errors: 9 | | ErrorObject, unknown>[] 10 | | null 11 | | undefined; 12 | constructor() { 13 | this.rules = schema; 14 | this.schemaValidator = new Ajv(); 15 | } 16 | validate(data: any): boolean { 17 | const schema: JSONSchemaType = this.rules; 18 | 19 | // validate is a type guard for data - type is inferred from schema type 20 | const validate = this.schemaValidator.compile(schema); 21 | 22 | if (validate(data)) { 23 | // data is MyData here 24 | return true; 25 | } else { 26 | this.errors = validate.errors; 27 | console.log(validate.errors); 28 | return false; 29 | } 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/technology.d.ts: -------------------------------------------------------------------------------- 1 | import { ActionList, IConcept, ITechnology } from 'kodyfire-core'; 2 | export declare class Technology implements ITechnology { 3 | id: string; 4 | name: string; 5 | version: string; 6 | rootDir: string; 7 | concepts: Map; 8 | assets: any; 9 | actions: ActionList; 10 | input?: any; 11 | params: any; 12 | constructor(params: any, _assets?: { 13 | name: string; 14 | version: string; 15 | rootDir: string; 16 | concepts: { 17 | name: string; 18 | template: { 19 | path: string; 20 | }; 21 | }[]; 22 | }); 23 | prepareConcept(dependency: string, conceptName: string, preparedConcept: any): Promise; 24 | } 25 | //# sourceMappingURL=technology.d.ts.map -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/create/kody/src/technology.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"technology.d.ts","sourceRoot":"","sources":["technology.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAc,QAAQ,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAK9E,qBAAa,UAAW,YAAW,WAAW;IAC5C,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,EAAE,MAAM,CAAC;IAChB,OAAO,EAAE,MAAM,CAAC;IAChB,QAAQ,EAAE,GAAG,CAAC,MAAM,EAAE,QAAQ,CAAC,CAAC;IAChC,MAAM,EAAE,GAAG,CAAC;IACZ,OAAO,EAAE,UAAU,CAAC;IACpB,KAAK,CAAC,EAAE,GAAG,CAAC;IACZ,MAAM,EAAE,GAAG,CAAC;gBACA,MAAM,EAAE,GAAG,EAAE,OAAO;;;;;;;;;;KAAS;IAwBnC,cAAc,CAClB,UAAU,EAAE,MAAM,EAClB,WAAW,EAAE,MAAM,EACnB,eAAe,EAAE,GAAG;CAmBvB"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/generate/helper.d.ts: -------------------------------------------------------------------------------- 1 | declare const _default: (args: any) => Promise; 2 | export default _default; 3 | //# sourceMappingURL=helper.d.ts.map 4 | -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/generate/helper.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"helper.d.ts","sourceRoot":"","sources":["helper.ts"],"names":[],"mappings":"+BAK4B,GAAG;AAA/B,wBA2BE"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/generate/helper.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"helper.js","sourceRoot":"","sources":["helper.ts"],"names":[],"mappings":";;;;;;;;;;;;;;AAAA,kDAA0B;AAC1B,MAAM,EAAE,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;AACzB,MAAM,EAAE,IAAI,EAAE,GAAG,OAAO,CAAC,MAAM,CAAC,CAAC;AACjC,2BAA2B;AAE3B,kBAAe,CAAO,IAAS,EAAE,EAAE;IACjC,wCAAwC;IACxC,IAAI,OAAO,IAAI,CAAC,MAAM,KAAK,WAAW,EAAE;QACtC,IAAI,CAAC,MAAM,GAAG,IAAI,CAAC,OAAO,CAAC,GAAG,EAAE,EAAE,WAAW,CAAC,CAAC;KAChD;IACD,IAAI,CAAC,EAAE,CAAC,UAAU,CAAC,IAAI,CAAC,MAAM,CAAC,EAAE;QAC/B,OAAO,CAAC,GAAG,CACT,eAAK,CAAC,GAAG,CACP,GAAG,eAAK,CAAC,KAAK,CACZ,eAAK,CAAC,KAAK,CAAC,IAAI,CAAC,MAAM,CAAC,CACzB,wDAAwD,CAC1D,CACF,CAAC;QACF,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;KACjB;IACD,MAAM,MAAM,GAAG,IAAI,CAAC,KAAK,CAAC,EAAE,CAAC,YAAY,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC,CAAC;IACxD,MAAM,EAAE,OAAO,GAAG,EAAE,EAAE,GAAG,MAAM,CAAC;IAChC,IAAI,OAAO,CAAC,MAAM,KAAK,CAAC;QAAE,OAAO;IACjC,wCAAwC;IACxC,MAAM,UAAU,GAAG,OAAO,CAAC,GAAG,EAAE,CAAC;IACjC,MAAM,OAAO,GAAG,MAAM,CAAC,OAAO,IAAI,UAAU,CAAC;IAC7C,OAAE,CAAC,OAAO,CAAC,CAAC;IACZ,KAAK,MAAM,MAAM,IAAI,OAAO,EAAE;QAC5B,OAAO,CAAC,GAAG,CAAC,kBAAkB,MAAM,EAAE,CAAC,CAAC;QACxC,MAAM,MAAC,CAAA,GAAG,MAAM,EAAE,CAAC;KACpB;IACD,OAAE,CAAC,UAAU,CAAC,CAAC;AACjB,CAAC,CAAA,CAAC"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/generate/index.d.ts: -------------------------------------------------------------------------------- 1 | export {}; 2 | //# sourceMappingURL=index.d.ts.map -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/generate/index.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["index.ts"],"names":[],"mappings":""} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/import/action.d.ts: -------------------------------------------------------------------------------- 1 | export declare const supportedTypes: string[]; 2 | export declare class Action { 3 | static displayMessage(message: string, color?: string): void; 4 | static execute(_args: any): Promise; 5 | } 6 | //# sourceMappingURL=action.d.ts.map -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/import/action.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"action.d.ts","sourceRoot":"","sources":["action.ts"],"names":[],"mappings":"AAKA,eAAO,MAAM,cAAc,UAQ1B,CAAC;AACF,qBAAa,MAAM;IACjB,MAAM,CAAC,cAAc,CAAC,OAAO,EAAE,MAAM,EAAE,KAAK,SAAW;WAW1C,OAAO,CAAC,KAAK,EAAE,GAAG;CAgHhC"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/import/index.d.ts: -------------------------------------------------------------------------------- 1 | export {}; 2 | //# sourceMappingURL=index.d.ts.map -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/import/index.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["index.ts"],"names":[],"mappings":""} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/import/index.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"index.js","sourceRoot":"","sources":["index.ts"],"names":[],"mappings":";;;;;;;;;;;AAAA,MAAM,EAAE,OAAO,EAAE,GAAG,OAAO,CAAC,WAAW,CAAC,CAAC;AACzC,yCAA6C;AAC7C,qCAAkD;AAElD,MAAM,CAAC,OAAO,GAAG,CAAC,OAAuB,EAAE,EAAE;IAC3C,OAAO;SACJ,OAAO,CAAC,QAAQ,CAAC;SACjB,KAAK,CAAC,IAAI,CAAC;SACX,WAAW,CAAC,IAAI,oBAAQ,CAAC,QAAQ,EAAE,gCAAgC,CAAC,CAAC;SACrE,WAAW,CACV,IAAI,oBAAQ,CACV,YAAY,EACZ,gEAAgE,CACjE,CACF;SACA,WAAW,CAAC,sCAAsC,CAAC;SACnD,SAAS,CACR,IAAI,kBAAM,CAAC,mBAAmB,EAAE,qCAAqC,CAAC;SACnE,OAAO,CAAC,MAAM,CAAC;SACf,mBAAmB,EAAE;SACrB,OAAO,CAAC,uBAAc,CAAC,CAC3B;SACA,SAAS,CACR,IAAI,kBAAM,CACR,uBAAuB,EACvB,uCAAuC,CACxC,CAAC,mBAAmB,EAAE,CACxB;SACA,MAAM,CAAC,CAAO,IAAY,EAAE,QAAgB,EAAE,IAAS,EAAE,EAAE;QAC1D,IAAI,CAAC,QAAQ,GAAG,QAAQ,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,GAAG,CAAC,CAAC,CAAS,EAAE,EAAE,CAAC,CAAC,CAAC,IAAI,EAAE,CAAC,CAAC;QACjE,OAAO,MAAM,eAAM,CAAC,OAAO,iBAAG,IAAI,IAAK,IAAI,EAAG,CAAC;IACjD,CAAC,CAAA,CAAC,CAAC;AACP,CAAC,CAAC"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/import/index.ts: -------------------------------------------------------------------------------- 1 | const { Command } = require('commander'); 2 | import { Argument, Option } from 'commander'; 3 | import { Action, supportedTypes } from './action'; 4 | 5 | module.exports = (program: typeof Command) => { 6 | program 7 | .command('import') 8 | .alias('in') 9 | .addArgument(new Argument('', 'The kody to use for the import')) 10 | .addArgument( 11 | new Argument( 12 | '', 13 | 'A comma seperated list of concepts to generate from the source' 14 | ) 15 | ) 16 | .description('Mass create artifacts from a source.') 17 | .addOption( 18 | new Option('-t, --type ', 'The type of the artifacts to import') 19 | .default('yaml') 20 | .makeOptionMandatory() 21 | .choices(supportedTypes) 22 | ) 23 | .addOption( 24 | new Option( 25 | '-s, --source ', 26 | 'The source of the artifacts to import' 27 | ).makeOptionMandatory() 28 | ) 29 | .action(async (kody: string, concepts: string, _opt: any) => { 30 | _opt.concepts = concepts.split(',').map((c: string) => c.trim()); 31 | return await Action.execute({ kody, ..._opt }); 32 | }); 33 | }; 34 | -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/init/action.d.ts: -------------------------------------------------------------------------------- 1 | export declare const question: (name: string) => { 2 | type: string; 3 | name: string; 4 | message: string; 5 | initial: string; 6 | }; 7 | export declare class Action { 8 | static displayMessage(message: string): void; 9 | static execute(_args?: any): Promise; 10 | static createDefinitionFile(rootDir: string, dep: string): Promise; 11 | static getEntries(rootDirectory: string, dep: string): Promise; 12 | static getPackageDependencies(rootDir?: string): Promise; 13 | static getNpmGlobalPrefix(): string; 14 | static getDependencyConcepts(dependency: string, rootDir?: string): Promise<{ 15 | name: string; 16 | concepts: any; 17 | } | undefined>; 18 | static getConceptAttributes(schema: any): Promise; 19 | static addConcept(dependency: string, concept: string, data: any, rootDir?: string): Promise; 20 | } 21 | //# sourceMappingURL=action.d.ts.map -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/init/action.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"action.d.ts","sourceRoot":"","sources":["action.ts"],"names":[],"mappings":"AAMA,eAAO,MAAM,QAAQ,SAAU,MAAM;;;;;CAKnC,CAAC;AACH,qBAAa,MAAM;IACjB,MAAM,CAAC,cAAc,CAAC,OAAO,EAAE,MAAM;WAWxB,OAAO,CAAC,KAAK,GAAE,GAAgC;WA6C/C,oBAAoB,CAAC,OAAO,EAAE,MAAM,EAAE,GAAG,EAAE,MAAM;WAajD,UAAU,CAAC,aAAa,EAAE,MAAM,EAAE,GAAG,EAAE,MAAM;WAkB7C,sBAAsB,CAAC,OAAO,SAAgB,GAAG,OAAO,CAAC,GAAG,CAAC;IAwB1E,MAAM,CAAC,kBAAkB;WAkBZ,qBAAqB,CAChC,UAAU,EAAE,MAAM,EAClB,OAAO,SAAgB;;;;WA0CZ,oBAAoB,CAAC,MAAM,EAAE,GAAG,GAAG,OAAO,CAAC,GAAG,CAAC;WAc/C,UAAU,CACrB,UAAU,EAAE,MAAM,EAClB,OAAO,EAAE,MAAM,EACf,IAAI,EAAE,GAAG,EACT,OAAO,GAAE,MAAsB;CAmBlC"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/init/helper.d.ts: -------------------------------------------------------------------------------- 1 | declare const _default: (args: any) => Promise; 2 | export default _default; 3 | //# sourceMappingURL=helper.d.ts.map 4 | -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/init/helper.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"helper.d.ts","sourceRoot":"","sources":["helper.ts"],"names":[],"mappings":"+BAK4B,GAAG;AAA/B,wBA2BE"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/init/helper.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"helper.js","sourceRoot":"","sources":["helper.ts"],"names":[],"mappings":";;;;;;;;;;;;;;AAAA,kDAA0B;AAC1B,MAAM,EAAE,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;AACzB,MAAM,EAAE,IAAI,EAAE,GAAG,OAAO,CAAC,MAAM,CAAC,CAAC;AACjC,2BAA2B;AAE3B,kBAAe,CAAO,IAAS,EAAE,EAAE;IACjC,wCAAwC;IACxC,IAAI,OAAO,IAAI,CAAC,MAAM,KAAK,WAAW,EAAE;QACtC,IAAI,CAAC,MAAM,GAAG,IAAI,CAAC,OAAO,CAAC,GAAG,EAAE,EAAE,WAAW,CAAC,CAAC;KAChD;IACD,IAAI,CAAC,EAAE,CAAC,UAAU,CAAC,IAAI,CAAC,MAAM,CAAC,EAAE;QAC/B,OAAO,CAAC,GAAG,CACT,eAAK,CAAC,GAAG,CACP,GAAG,eAAK,CAAC,KAAK,CACZ,eAAK,CAAC,KAAK,CAAC,IAAI,CAAC,MAAM,CAAC,CACzB,wDAAwD,CAC1D,CACF,CAAC;QACF,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;KACjB;IACD,MAAM,MAAM,GAAG,IAAI,CAAC,KAAK,CAAC,EAAE,CAAC,YAAY,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC,CAAC;IACxD,MAAM,EAAE,OAAO,GAAG,EAAE,EAAE,GAAG,MAAM,CAAC;IAChC,IAAI,OAAO,CAAC,MAAM,KAAK,CAAC;QAAE,OAAO;IACjC,wCAAwC;IACxC,MAAM,UAAU,GAAG,OAAO,CAAC,GAAG,EAAE,CAAC;IACjC,MAAM,OAAO,GAAG,MAAM,CAAC,OAAO,IAAI,UAAU,CAAC;IAC7C,OAAE,CAAC,OAAO,CAAC,CAAC;IACZ,KAAK,MAAM,MAAM,IAAI,OAAO,EAAE;QAC5B,OAAO,CAAC,GAAG,CAAC,kBAAkB,MAAM,EAAE,CAAC,CAAC;QACxC,MAAM,MAAC,CAAA,GAAG,MAAM,EAAE,CAAC;KACpB;IACD,OAAE,CAAC,UAAU,CAAC,CAAC;AACjB,CAAC,CAAA,CAAC"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/init/index.d.ts: -------------------------------------------------------------------------------- 1 | export {}; 2 | //# sourceMappingURL=index.d.ts.map -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/init/index.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["index.ts"],"names":[],"mappings":""} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/init/index.js: -------------------------------------------------------------------------------- 1 | "use strict"; 2 | var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) { 3 | function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); } 4 | return new (P || (P = Promise))(function (resolve, reject) { 5 | function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } } 6 | function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } } 7 | function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); } 8 | step((generator = generator.apply(thisArg, _arguments || [])).next()); 9 | }); 10 | }; 11 | Object.defineProperty(exports, "__esModule", { value: true }); 12 | const { Command } = require('commander'); 13 | const action_1 = require("./action"); 14 | module.exports = (program) => { 15 | program 16 | .command('init') 17 | .description('Initialize a new kodyfire project') 18 | .action((_opt) => __awaiter(void 0, void 0, void 0, function* () { 19 | return yield action_1.Action.execute(); 20 | })); 21 | }; 22 | //# sourceMappingURL=index.js.map -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/init/index.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"index.js","sourceRoot":"","sources":["index.ts"],"names":[],"mappings":";;;;;;;;;;;AAAA,MAAM,EAAE,OAAO,EAAE,GAAG,OAAO,CAAC,WAAW,CAAC,CAAC;AACzC,qCAAkC;AAElC,MAAM,CAAC,OAAO,GAAG,CAAC,OAAuB,EAAE,EAAE;IAC3C,OAAO;SACJ,OAAO,CAAC,MAAM,CAAC;SACf,WAAW,CAAC,mCAAmC,CAAC;SAChD,MAAM,CAAC,CAAO,IAAS,EAAE,EAAE;QAC1B,OAAO,MAAM,eAAM,CAAC,OAAO,EAAE,CAAC;IAChC,CAAC,CAAA,CAAC,CAAC;AACP,CAAC,CAAC"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/init/index.ts: -------------------------------------------------------------------------------- 1 | const { Command } = require('commander'); 2 | import { Action } from './action'; 3 | 4 | module.exports = (program: typeof Command) => { 5 | program 6 | .command('init') 7 | .description('Initialize a new kodyfire project') 8 | .action(async (_opt: any) => { 9 | return await Action.execute(); 10 | }); 11 | }; 12 | -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/install/action.d.ts: -------------------------------------------------------------------------------- 1 | export declare class Action { 2 | static prompter(kody: string): Promise; 3 | static runCommand(kody: string, path?: string): Promise; 4 | static displayMessage(message: string): void; 5 | static execute(kody: string): Promise; 6 | static addConcept(dependency: string, concept: string, data: any, rootDir?: string): Promise; 7 | static addConceptProperty(dependency: string, concept: string, property: string, data: any, rootDir?: string): Promise; 8 | static getSchemaDefinition(dependency: string, rootDir: string): any; 9 | static conceptToQuestion(name: string, concept: { 10 | type?: string; 11 | enum?: any; 12 | }, concepts?: any, message?: boolean | string, useIndex?: boolean): Promise; 13 | } 14 | //# sourceMappingURL=action.d.ts.map -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/install/action.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"action.d.ts","sourceRoot":"","sources":["action.ts"],"names":[],"mappings":"AAeA,qBAAa,MAAM;WACJ,QAAQ,CAAC,IAAI,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,GAAG,GAAG,CAAC;WAyC3C,UAAU,CAAC,IAAI,EAAE,MAAM,EAAE,IAAI,SAAO;IAcjD,MAAM,CAAC,cAAc,CAAC,OAAO,EAAE,MAAM;WAWxB,OAAO,CAAC,IAAI,EAAE,MAAM;WAQpB,UAAU,CACrB,UAAU,EAAE,MAAM,EAClB,OAAO,EAAE,MAAM,EACf,IAAI,EAAE,GAAG,EACT,OAAO,GAAE,MAAsB;WAkBpB,kBAAkB,CAC7B,UAAU,EAAE,MAAM,EAClB,OAAO,EAAE,MAAM,EACf,QAAQ,EAAE,MAAM,EAChB,IAAI,EAAE,GAAG,EACT,OAAO,GAAE,MAAsB;IAyBjC,MAAM,CAAC,mBAAmB,CAAC,UAAU,EAAE,MAAM,EAAE,OAAO,EAAE,MAAM;WAQjD,iBAAiB,CAC5B,IAAI,EAAE,MAAM,EACZ,OAAO,EAAE;QAAE,IAAI,CAAC,EAAE,MAAM,CAAC;QAAC,IAAI,CAAC,EAAE,GAAG,CAAA;KAAE,EACtC,QAAQ,GAAE,GAAQ,EAClB,OAAO,GAAE,OAAO,GAAG,MAAc,EACjC,QAAQ,UAAQ,GACf,OAAO,CAAC,GAAG,GAAG,IAAI,CAAC;CAoCvB"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/install/helper.d.ts: -------------------------------------------------------------------------------- 1 | declare const _default: (args: any) => Promise; 2 | export default _default; 3 | //# sourceMappingURL=helper.d.ts.map 4 | -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/install/helper.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"helper.d.ts","sourceRoot":"","sources":["helper.ts"],"names":[],"mappings":"+BAK4B,GAAG;AAA/B,wBA2BE"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/install/helper.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"helper.js","sourceRoot":"","sources":["helper.ts"],"names":[],"mappings":";;;;;;;;;;;;;;AAAA,kDAA0B;AAC1B,MAAM,EAAE,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;AACzB,MAAM,EAAE,IAAI,EAAE,GAAG,OAAO,CAAC,MAAM,CAAC,CAAC;AACjC,2BAA2B;AAE3B,kBAAe,CAAO,IAAS,EAAE,EAAE;IACjC,wCAAwC;IACxC,IAAI,OAAO,IAAI,CAAC,MAAM,KAAK,WAAW,EAAE;QACtC,IAAI,CAAC,MAAM,GAAG,IAAI,CAAC,OAAO,CAAC,GAAG,EAAE,EAAE,WAAW,CAAC,CAAC;KAChD;IACD,IAAI,CAAC,EAAE,CAAC,UAAU,CAAC,IAAI,CAAC,MAAM,CAAC,EAAE;QAC/B,OAAO,CAAC,GAAG,CACT,eAAK,CAAC,GAAG,CACP,GAAG,eAAK,CAAC,KAAK,CACZ,eAAK,CAAC,KAAK,CAAC,IAAI,CAAC,MAAM,CAAC,CACzB,wDAAwD,CAC1D,CACF,CAAC;QACF,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;KACjB;IACD,MAAM,MAAM,GAAG,IAAI,CAAC,KAAK,CAAC,EAAE,CAAC,YAAY,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC,CAAC;IACxD,MAAM,EAAE,OAAO,GAAG,EAAE,EAAE,GAAG,MAAM,CAAC;IAChC,IAAI,OAAO,CAAC,MAAM,KAAK,CAAC;QAAE,OAAO;IACjC,wCAAwC;IACxC,MAAM,UAAU,GAAG,OAAO,CAAC,GAAG,EAAE,CAAC;IACjC,MAAM,OAAO,GAAG,MAAM,CAAC,OAAO,IAAI,UAAU,CAAC;IAC7C,OAAE,CAAC,OAAO,CAAC,CAAC;IACZ,KAAK,MAAM,MAAM,IAAI,OAAO,EAAE;QAC5B,OAAO,CAAC,GAAG,CAAC,kBAAkB,MAAM,EAAE,CAAC,CAAC;QACxC,MAAM,MAAC,CAAA,GAAG,MAAM,EAAE,CAAC;KACpB;IACD,OAAE,CAAC,UAAU,CAAC,CAAC;AACjB,CAAC,CAAA,CAAC"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/install/index.d.ts: -------------------------------------------------------------------------------- 1 | export {}; 2 | //# sourceMappingURL=index.d.ts.map -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/install/index.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["index.ts"],"names":[],"mappings":""} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/install/index.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"index.js","sourceRoot":"","sources":["index.ts"],"names":[],"mappings":";;;;;;;;;;;AAAA,MAAM,EAAE,OAAO,EAAE,GAAG,OAAO,CAAC,WAAW,CAAC,CAAC;AACzC,qCAAkC;AAElC,MAAM,CAAC,OAAO,GAAG,CAAC,OAAuB,EAAE,EAAE;IAC3C,OAAO;SACJ,OAAO,CAAC,SAAS,CAAC;SAClB,KAAK,CAAC,GAAG,CAAC;SACV,QAAQ,CAAC,QAAQ,EAAE,yGAAyG,CAAC;SAC7H,WAAW,CAAC,kCAAkC,CAAC;SAC/C,MAAM,CAAC,CAAO,IAAY,EAAE,IAAS,EAAE,EAAE;QACxC,OAAO,MAAM,eAAM,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC;IACpC,CAAC,CAAA,CAAC,CAAC;AACP,CAAC,CAAC"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/install/index.ts: -------------------------------------------------------------------------------- 1 | const { Command } = require('commander'); 2 | import { Action } from './action'; 3 | 4 | module.exports = (program: typeof Command) => { 5 | program 6 | .command('install') 7 | .alias('i') 8 | .argument('[kody]', 'The kody package name you want to install. You can pas the package name without the `-kodyfire` suffix.') 9 | .description('Prompt user to choose to install') 10 | .action(async (kody: string, _opt: any) => { 11 | return await Action.execute(kody); 12 | }); 13 | }; 14 | -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/list/action.d.ts: -------------------------------------------------------------------------------- 1 | export declare class Action { 2 | static displayMessage(message: string): void; 3 | static displayKodies(kodies: any[]): void; 4 | static execute(args: { 5 | technology: any; 6 | summary: any; 7 | }): Promise; 8 | static getInstalledKodies(): Promise; 9 | static displayTemplates(packageName: string): Promise; 10 | static displayOverwrites(packageName: string): Promise; 11 | static displayConcepts(packageName: string): Promise; 12 | static getDependencyConcepts(dependency: string, rootDir?: string): Promise<{ 13 | name: string; 14 | concepts: any; 15 | } | undefined>; 16 | static getDependencyTemplates(dependency: string, rootDir?: string): Promise; 17 | static getConceptAttributes(schema: any): Promise; 18 | } 19 | export declare const action: (args: any) => Promise; 20 | //# sourceMappingURL=action.d.ts.map -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/list/action.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"action.d.ts","sourceRoot":"","sources":["action.ts"],"names":[],"mappings":"AASA,qBAAa,MAAM;IACjB,MAAM,CAAC,cAAc,CAAC,OAAO,EAAE,MAAM;IAWrC,MAAM,CAAC,aAAa,CAAC,MAAM,EAAE,GAAG,EAAE;WAgBrB,OAAO,CAAC,IAAI,EAAE;QAAE,UAAU,EAAE,GAAG,CAAC;QAAC,OAAO,EAAE,GAAG,CAAA;KAAE;WAyC/C,kBAAkB,IAAI,OAAO,CAAC,MAAM,EAAE,CAAC;WAMvC,gBAAgB,CAAC,WAAW,EAAE,MAAM;WAkBpC,iBAAiB,CAAC,WAAW,EAAE,MAAM;WAkBrC,eAAe,CAAC,WAAW,EAAE,MAAM;WAmBnC,qBAAqB,CAChC,UAAU,EAAE,MAAM,EAClB,OAAO,SAAgB;;;;WAgCZ,sBAAsB,CACjC,UAAU,EAAE,MAAM,EAClB,OAAO,SAAgB;WA2CZ,oBAAoB,CAAC,MAAM,EAAE,GAAG,GAAG,OAAO,CAAC,GAAG,CAAC;CAa7D;AACD,eAAO,MAAM,MAAM,SAAgB,GAAG,kBAmBrC,CAAC"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/list/index.d.ts: -------------------------------------------------------------------------------- 1 | export {}; 2 | //# sourceMappingURL=index.d.ts.map -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/list/index.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["index.ts"],"names":[],"mappings":""} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/list/index.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"index.js","sourceRoot":"","sources":["index.ts"],"names":[],"mappings":";;;;;;;;;;;AAAA,yCAAmC;AACnC,qCAAkC;AAClC,MAAM,EAAE,OAAO,EAAE,GAAG,OAAO,CAAC,WAAW,CAAC,CAAC;AAEzC,MAAM,CAAC,OAAO,GAAG,CAAC,OAAuB,EAAE,EAAE;IAC3C,OAAO;SACJ,OAAO,CAAC,MAAM,CAAC;SACf,KAAK,CAAC,IAAI,CAAC;SACX,WAAW,CAAC,oDAAoD,CAAC;SACjE,QAAQ,CACP,YAAY,EACZ,gEAAgE,CACjE;SACA,SAAS,CAAC,IAAI,kBAAM,CAAC,yBAAyB,EAAE,4DAA4D,CAAC,CAAC,OAAO,CAAC,CAAC,UAAU,EAAE,WAAW,EAAE,YAAY,CAAC,CAAC,CAAC,OAAO,CAAC,UAAU,CAAC,CAAC;SACnL,MAAM,CAAC,CAAO,QAAa,EAAE,IAAS,EAAE,EAAE;QACzC,OAAO,IAAA,eAAM,kBAAG,UAAU,EAAE,QAAQ,IAAK,IAAI,EAAG,CAAC;IACnD,CAAC,CAAA,CAAC,CAAC;AACP,CAAC,CAAC"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/list/index.ts: -------------------------------------------------------------------------------- 1 | import { Option } from 'commander'; 2 | import { action } from './action'; 3 | const { Command } = require('commander'); 4 | 5 | module.exports = (program: typeof Command) => { 6 | program 7 | .command('list') 8 | .alias('ls') 9 | .description('list installed kodies within your current project.') 10 | .argument( 11 | '[kodyName]', 12 | 'List details of a kody by passing the kody name as an argument' 13 | ) 14 | .addOption(new Option('-s, --summary
', 'List kody details such as `template` names and `concepts`.').choices(['concepts', 'templates', 'overwrites']).default('concepts')) 15 | .action(async (kodyName: any, opts: any) => { 16 | return action({ technology: kodyName, ...opts }); 17 | }); 18 | }; 19 | -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/prompt/action.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"action.d.ts","sourceRoot":"","sources":["action.ts"],"names":[],"mappings":";AAeA,qBAAa,MAAM;IACjB,MAAM,CAAC,aAAa,EAAE,MAAM,CAAC;IAC7B,MAAM,CAAC,UAAU,UAAS;IAC1B,MAAM,CAAC,OAAO,SAAK;IACnB,MAAM,CAAC,QAAQ,EAAE,GAAG,CAAC;IACrB,MAAM,CAAC,eAAe,SAAM;IAC5B,MAAM,CAAC,SAAS,SAAW;IAE3B,MAAM,CAAC,SAAS;;;;;QAmBd;WACW,QAAQ;IAMrB,MAAM,CAAC,cAAc,CAAC,OAAO,EAAE,MAAM,EAAE,WAAW,SAAW;WAYhD,MAAM,CACjB,GAAG,EAAE,GAAG,EACR,MAAM,EAAE,GAAG,EAAE,EACb,OAAO,EAAE,GAAG,EACZ,gBAAgB,EAAE,OAAO,EACzB,MAAM,EAAE,GAAG;;;;;WAiCA,QAAQ,CAAC,MAAM,SAAK;IA6FjC,OAAO,CAAC,MAAM,CAAC,UAAU;WAiBZ,MAAM,CAAC,QAAQ,EAAE,GAAG,EAAE,OAAO,EAAE,MAAM,GAAG,MAAM;WAI9C,YAAY,CAAC,MAAM,EAAE,GAAG,EAAE,EAAE,OAAO,EAAE,GAAG;WAQxC,SAAS;WAST,eAAe;WASf,iBAAiB,CAAC,QAAQ,EAAE,GAAG,EAAE,OAAO,EAAE,MAAM,GAAG,MAAM;WAKzD,OAAO,CAAC,MAAM,EAAE,GAAG,EAAE,IAAI,KAAA;WA4DzB,iBAAiB;CA8B/B"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/prompt/helper.d.ts: -------------------------------------------------------------------------------- 1 | declare const _default: (args: any) => Promise; 2 | export default _default; 3 | //# sourceMappingURL=helper.d.ts.map 4 | -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/prompt/helper.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"helper.d.ts","sourceRoot":"","sources":["helper.ts"],"names":[],"mappings":"+BAK4B,GAAG;AAA/B,wBA2BE"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/prompt/helper.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"helper.js","sourceRoot":"","sources":["helper.ts"],"names":[],"mappings":";;;;;;;;;;;;;;AAAA,kDAA0B;AAC1B,MAAM,EAAE,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;AACzB,MAAM,EAAE,IAAI,EAAE,GAAG,OAAO,CAAC,MAAM,CAAC,CAAC;AACjC,2BAA2B;AAE3B,kBAAe,CAAO,IAAS,EAAE,EAAE;IACjC,wCAAwC;IACxC,IAAI,OAAO,IAAI,CAAC,MAAM,KAAK,WAAW,EAAE;QACtC,IAAI,CAAC,MAAM,GAAG,IAAI,CAAC,OAAO,CAAC,GAAG,EAAE,EAAE,WAAW,CAAC,CAAC;KAChD;IACD,IAAI,CAAC,EAAE,CAAC,UAAU,CAAC,IAAI,CAAC,MAAM,CAAC,EAAE;QAC/B,OAAO,CAAC,GAAG,CACT,eAAK,CAAC,GAAG,CACP,GAAG,eAAK,CAAC,KAAK,CACZ,eAAK,CAAC,KAAK,CAAC,IAAI,CAAC,MAAM,CAAC,CACzB,wDAAwD,CAC1D,CACF,CAAC;QACF,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;KACjB;IACD,MAAM,MAAM,GAAG,IAAI,CAAC,KAAK,CAAC,EAAE,CAAC,YAAY,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC,CAAC;IACxD,MAAM,EAAE,OAAO,GAAG,EAAE,EAAE,GAAG,MAAM,CAAC;IAChC,IAAI,OAAO,CAAC,MAAM,KAAK,CAAC;QAAE,OAAO;IACjC,wCAAwC;IACxC,MAAM,UAAU,GAAG,OAAO,CAAC,GAAG,EAAE,CAAC;IACjC,MAAM,OAAO,GAAG,MAAM,CAAC,OAAO,IAAI,UAAU,CAAC;IAC7C,OAAE,CAAC,OAAO,CAAC,CAAC;IACZ,KAAK,MAAM,MAAM,IAAI,OAAO,EAAE;QAC5B,OAAO,CAAC,GAAG,CAAC,kBAAkB,MAAM,EAAE,CAAC,CAAC;QACxC,MAAM,MAAC,CAAA,GAAG,MAAM,EAAE,CAAC;KACpB;IACD,OAAE,CAAC,UAAU,CAAC,CAAC;AACjB,CAAC,CAAA,CAAC"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/prompt/index.d.ts: -------------------------------------------------------------------------------- 1 | export {}; 2 | //# sourceMappingURL=index.d.ts.map -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/prompt/index.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["index.ts"],"names":[],"mappings":""} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/prompt/index.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"index.js","sourceRoot":"","sources":["index.ts"],"names":[],"mappings":";;;;;;;;;;;AAAA,cAAc;AACd,MAAM,EAAE,OAAO,EAAE,GAAG,OAAO,CAAC,WAAW,CAAC,CAAC;AAEzC,qCAAkC;AAGlC,MAAM,CAAC,OAAO,GAAG,CAAC,OAAuB,EAAE,EAAE;IAC3C,OAAO;SACJ,OAAO,CAAC,QAAQ,CAAC;SACjB,KAAK,CAAC,IAAI,CAAC;SACX,WAAW,CAAC,6DAA6D,CAAC;SAC1E,QAAQ,CACP,aAAa,EACb,oGAAoG,CACrG;QACD,uDAAuD;SACtD,MAAM,CAAC,cAAc,EAAE,uCAAuC,CAAC;SAC/D,MAAM,CAAC,CAAO,MAAM,EAAE,IAAI,EAAE,EAAE;QAC7B,OAAO,MAAM,eAAM,CAAC,OAAO,CAAC,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,IAAG,EAAE,EAAE,IAAI,CAAC,CAAC;IAC3D,CAAC,CAAA,CAAC,CAAC;AACP,CAAC,CAAC"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/prompt/index.ts: -------------------------------------------------------------------------------- 1 | // @ts-nocheck 2 | const { Command } = require('commander'); 3 | import chalk from 'chalk'; 4 | import { Action } from './action'; 5 | import { fs } from 'zx'; 6 | 7 | module.exports = (program: typeof Command) => { 8 | program 9 | .command('prompt') 10 | .alias('ai') 11 | .description('AI powered prompt assistant to quickly generate an artifact') 12 | .argument( 13 | '[prompt...]', 14 | 'This prompt to be used to generate the artifact. You can use the prompt command to create a prompt' 15 | ) 16 | // use audio recorder speech to text to create a prompt 17 | .option('-r, --record', 'Record a prompt using your microphone') 18 | .action(async (prompt, opts) => { 19 | return await Action.execute(prompt.join(' ')|| '', opts); 20 | }); 21 | }; 22 | -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/publish/index.d.ts: -------------------------------------------------------------------------------- 1 | export {}; 2 | //# sourceMappingURL=index.d.ts.map -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/publish/index.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["index.ts"],"names":[],"mappings":""} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/ride/action.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"action.d.ts","sourceRoot":"","sources":["action.ts"],"names":[],"mappings":"AAQA,qBAAa,MAAM;IACjB,MAAM,CAAC,IAAI,EAAE,GAAG,CAAC;IACjB,MAAM,CAAC,OAAO,EAAE,GAAG,CAAC;IACpB,MAAM,CAAC,UAAU,EAAE,GAAG,CAAC;IACvB,MAAM,CAAC,UAAU,UAAS;WAEb,QAAQ,CAAC,OAAO,EAAE,GAAG;WAIrB,qBAAqB,CAAC,UAAU,EAAE,MAAM;WAKxC,sBAAsB,CAAC,OAAO,SAAgB,GAAG,OAAO,CAAC,GAAG,CAAC;WA4B7D,QAAQ,IAAI,OAAO,CAAC,IAAI,GAAG,GAAG,CAAC;WAqC/B,iBAAiB;WAKjB,oBAAoB,CAAC,OAAO,EAAE,GAAG;WA8EjC,kBAAkB;;;;;;;;;WAiBlB,eAAe;;;;;;IAgB5B,MAAM,CAAC,cAAc,CAAC,OAAO,EAAE,MAAM;WAWxB,OAAO;WAQP,UAAU,CACrB,UAAU,EAAE,MAAM,EAClB,OAAO,EAAE,MAAM,EACf,IAAI,EAAE,GAAG,EACT,OAAO,GAAE,MAAsB;WAkBpB,kBAAkB,CAC7B,UAAU,EAAE,MAAM,EAClB,OAAO,EAAE,MAAM,EACf,QAAQ,EAAE,MAAM,EAChB,IAAI,EAAE,GAAG,EACT,OAAO,GAAE,MAAsB;IAyBjC,MAAM,CAAC,mBAAmB,CAAC,UAAU,EAAE,MAAM,EAAE,OAAO,SAAgB;WAUzD,iBAAiB,CAC5B,IAAI,EAAE,MAAM,EACZ,OAAO,EAAE;QACP,WAAW,EAAE,MAAM,CAAC;QACpB,OAAO,CAAC,EAAE,GAAG,CAAC;QACd,IAAI,CAAC,EAAE,MAAM,CAAC;QACd,IAAI,CAAC,EAAE,GAAG,CAAC;QACX,KAAK,CAAC,EAAE,GAAG,CAAC;KACb,EACD,SAAS,GAAE,GAAQ,EACnB,OAAO,GAAE,OAAO,GAAG,MAAc,EACjC,SAAS,UAAQ,EACjB,KAAK,SAAK,EACV,cAAc,UAAQ,GACrB,OAAO,CAAC,GAAG,GAAG,IAAI,CAAC;CAqEvB"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/ride/helper.d.ts: -------------------------------------------------------------------------------- 1 | declare const _default: (args: any) => Promise; 2 | export default _default; 3 | //# sourceMappingURL=helper.d.ts.map 4 | -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/ride/helper.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"helper.d.ts","sourceRoot":"","sources":["helper.ts"],"names":[],"mappings":"+BAK4B,GAAG;AAA/B,wBA2BE"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/ride/helper.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"helper.js","sourceRoot":"","sources":["helper.ts"],"names":[],"mappings":";;;;;;;;;;;;;;AAAA,kDAA0B;AAC1B,MAAM,EAAE,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;AACzB,MAAM,EAAE,IAAI,EAAE,GAAG,OAAO,CAAC,MAAM,CAAC,CAAC;AACjC,2BAA2B;AAE3B,kBAAe,CAAO,IAAS,EAAE,EAAE;IACjC,wCAAwC;IACxC,IAAI,OAAO,IAAI,CAAC,MAAM,KAAK,WAAW,EAAE;QACtC,IAAI,CAAC,MAAM,GAAG,IAAI,CAAC,OAAO,CAAC,GAAG,EAAE,EAAE,WAAW,CAAC,CAAC;KAChD;IACD,IAAI,CAAC,EAAE,CAAC,UAAU,CAAC,IAAI,CAAC,MAAM,CAAC,EAAE;QAC/B,OAAO,CAAC,GAAG,CACT,eAAK,CAAC,GAAG,CACP,GAAG,eAAK,CAAC,KAAK,CACZ,eAAK,CAAC,KAAK,CAAC,IAAI,CAAC,MAAM,CAAC,CACzB,wDAAwD,CAC1D,CACF,CAAC;QACF,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;KACjB;IACD,MAAM,MAAM,GAAG,IAAI,CAAC,KAAK,CAAC,EAAE,CAAC,YAAY,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC,CAAC;IACxD,MAAM,EAAE,OAAO,GAAG,EAAE,EAAE,GAAG,MAAM,CAAC;IAChC,IAAI,OAAO,CAAC,MAAM,KAAK,CAAC;QAAE,OAAO;IACjC,wCAAwC;IACxC,MAAM,UAAU,GAAG,OAAO,CAAC,GAAG,EAAE,CAAC;IACjC,MAAM,OAAO,GAAG,MAAM,CAAC,OAAO,IAAI,UAAU,CAAC;IAC7C,OAAE,CAAC,OAAO,CAAC,CAAC;IACZ,KAAK,MAAM,MAAM,IAAI,OAAO,EAAE;QAC5B,OAAO,CAAC,GAAG,CAAC,kBAAkB,MAAM,EAAE,CAAC,CAAC;QACxC,MAAM,MAAC,CAAA,GAAG,MAAM,EAAE,CAAC;KACpB;IACD,OAAE,CAAC,UAAU,CAAC,CAAC;AACjB,CAAC,CAAA,CAAC"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/ride/index.d.ts: -------------------------------------------------------------------------------- 1 | export {}; 2 | //# sourceMappingURL=index.d.ts.map -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/ride/index.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["index.ts"],"names":[],"mappings":""} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/ride/index.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"index.js","sourceRoot":"","sources":["index.ts"],"names":[],"mappings":";;;;;;;;;;;AAAA,MAAM,EAAE,OAAO,EAAE,GAAG,OAAO,CAAC,WAAW,CAAC,CAAC;AACzC,qCAAkC;AAElC,MAAM,CAAC,OAAO,GAAG,CAAC,OAAuB,EAAE,EAAE;IAC3C,OAAO;SACJ,OAAO,CAAC,MAAM,CAAC;SACf,KAAK,CAAC,GAAG,CAAC;SACV,WAAW,CAAC,oDAAoD,CAAC;SACjE,MAAM,CAAC,CAAO,IAAS,EAAE,EAAE;QAC1B,OAAO,MAAM,eAAM,CAAC,OAAO,EAAE,CAAC;IAChC,CAAC,CAAA,CAAC,CAAC;AACP,CAAC,CAAC"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/ride/index.ts: -------------------------------------------------------------------------------- 1 | const { Command } = require('commander'); 2 | import { Action } from './action'; 3 | 4 | module.exports = (program: typeof Command) => { 5 | program 6 | .command('ride') 7 | .alias('↻') 8 | .description('Prompt assistant to help build your kody.json file') 9 | .action(async (_opt: any) => { 10 | return await Action.execute(); 11 | }); 12 | }; 13 | -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/run-script/helper.d.ts: -------------------------------------------------------------------------------- 1 | declare const _default: (args: any) => Promise; 2 | export default _default; 3 | //# sourceMappingURL=helper.d.ts.map -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/run-script/helper.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"helper.d.ts","sourceRoot":"","sources":["helper.ts"],"names":[],"mappings":"+BAK4B,GAAG;AAA/B,wBA2BE"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/run-script/helper.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"helper.js","sourceRoot":"","sources":["helper.ts"],"names":[],"mappings":";;;;;;;;;;;;;;AAAA,kDAA0B;AAC1B,MAAM,EAAE,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;AACzB,MAAM,EAAE,IAAI,EAAE,GAAG,OAAO,CAAC,MAAM,CAAC,CAAC;AACjC,2BAA2B;AAE3B,kBAAe,CAAO,IAAS,EAAE,EAAE;IACjC,wCAAwC;IACxC,IAAI,OAAO,IAAI,CAAC,MAAM,KAAK,WAAW,EAAE;QACtC,IAAI,CAAC,MAAM,GAAG,IAAI,CAAC,OAAO,CAAC,GAAG,EAAE,EAAE,WAAW,CAAC,CAAC;KAChD;IACD,IAAI,CAAC,EAAE,CAAC,UAAU,CAAC,IAAI,CAAC,MAAM,CAAC,EAAE;QAC/B,OAAO,CAAC,GAAG,CACT,eAAK,CAAC,GAAG,CACP,GAAG,eAAK,CAAC,KAAK,CACZ,eAAK,CAAC,KAAK,CAAC,IAAI,CAAC,MAAM,CAAC,CACzB,wDAAwD,CAC1D,CACF,CAAC;QACF,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;KACjB;IACD,MAAM,MAAM,GAAG,IAAI,CAAC,KAAK,CAAC,EAAE,CAAC,YAAY,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC,CAAC;IACxD,MAAM,EAAE,OAAO,GAAG,EAAE,EAAE,GAAG,MAAM,CAAC;IAChC,IAAI,OAAO,CAAC,MAAM,KAAK,CAAC;QAAE,OAAO;IACjC,wCAAwC;IACxC,MAAM,UAAU,GAAG,OAAO,CAAC,GAAG,EAAE,CAAC;IACjC,MAAM,OAAO,GAAG,MAAM,CAAC,OAAO,IAAI,UAAU,CAAC;IAC7C,IAAA,OAAE,EAAC,OAAO,CAAC,CAAC;IACZ,KAAK,MAAM,MAAM,IAAI,OAAO,EAAE;QAC5B,OAAO,CAAC,GAAG,CAAC,kBAAkB,MAAM,EAAE,CAAC,CAAC;QACxC,MAAM,IAAA,MAAC,EAAA,GAAG,MAAM,EAAE,CAAC;KACpB;IACD,IAAA,OAAE,EAAC,UAAU,CAAC,CAAC;AACjB,CAAC,CAAA,CAAC"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/run-script/helper.ts: -------------------------------------------------------------------------------- 1 | import chalk from 'chalk'; 2 | const fs = require('fs'); 3 | const { join } = require('path'); 4 | import { $, cd } from 'zx'; 5 | 6 | export default async (args: any) => { 7 | // @todo: Refactor used by watch command 8 | if (typeof args.source === 'undefined') { 9 | args.source = join(process.cwd(), 'kody.json'); 10 | } 11 | if (!fs.existsSync(args.source)) { 12 | console.log( 13 | chalk.red( 14 | `${chalk.bgRed( 15 | chalk.white(args.source) 16 | )} not found. Please provide the source file to be used.` 17 | ) 18 | ); 19 | process.exit(1); 20 | } 21 | const schema = JSON.parse(fs.readFileSync(args.source)); 22 | const { scripts = [] } = schema; 23 | if (scripts.length === 0) return; 24 | // We access rootDir if it was specified 25 | const currentDir = process.cwd(); 26 | const rootDir = schema.rootDir || currentDir; 27 | cd(rootDir); 28 | for (const script of scripts) { 29 | console.log(`running script ${script}`); 30 | await $`${script}`; 31 | } 32 | cd(currentDir); 33 | }; 34 | -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/run-script/index.d.ts: -------------------------------------------------------------------------------- 1 | declare const action: (args: any) => Promise; 2 | export default action; 3 | //# sourceMappingURL=index.d.ts.map -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/run-script/index.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["index.ts"],"names":[],"mappings":"AAGA,QAAA,MAAM,MAAM,SAAgB,GAAG,kBAE9B,CAAC;AAYF,eAAe,MAAM,CAAC"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/run-script/index.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"index.js","sourceRoot":"","sources":["index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;AAAA,MAAM,EAAE,OAAO,EAAE,GAAG,OAAO,CAAC,WAAW,CAAC,CAAC;AACzC,sDAAiC;AAEjC,MAAM,MAAM,GAAG,CAAO,IAAS,EAAE,EAAE;IACjC,MAAM,IAAA,gBAAS,EAAC,IAAI,CAAC,CAAC;AACxB,CAAC,CAAA,CAAC;AAEF,MAAM,CAAC,OAAO,GAAG,CAAC,OAAuB,EAAE,EAAE;IAC3C,OAAO;SACJ,OAAO,CAAC,YAAY,CAAC;SACrB,KAAK,CAAC,IAAI,CAAC;SACX,WAAW,CAAC,aAAa,CAAC;SAC1B,MAAM,CAAC,CAAO,IAAS,EAAE,EAAE;QAC1B,OAAO,MAAM,MAAM,CAAC,IAAI,CAAC,CAAC;IAC5B,CAAC,CAAA,CAAC,CAAC;AACP,CAAC,CAAC;AAEF,kBAAe,MAAM,CAAC"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/run-script/index.ts: -------------------------------------------------------------------------------- 1 | const { Command } = require('commander'); 2 | import runScript from './helper'; 3 | 4 | const action = async (args: any) => { 5 | await runScript(args); 6 | }; 7 | 8 | module.exports = (program: typeof Command) => { 9 | program 10 | .command('run-script') 11 | .alias('rs') 12 | .description('run scripts') 13 | .action(async (_opt: any) => { 14 | return await action(_opt); 15 | }); 16 | }; 17 | 18 | export default action; 19 | -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/run/index.d.ts: -------------------------------------------------------------------------------- 1 | export declare function action(args: any): Promise<0 | 1>; 2 | //# sourceMappingURL=index.d.ts.map -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/run/index.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["index.ts"],"names":[],"mappings":"AAMA,wBAAsB,MAAM,CAAC,IAAI,EAAE,GAAG,GAAG,OAAO,CAAC,CAAC,GAAG,CAAC,CAAC,CA4BtD"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/search/action.d.ts: -------------------------------------------------------------------------------- 1 | export declare class Action { 2 | static displayMessage(message: string): void; 3 | static displaySearchResults(kodies: any[]): void; 4 | static execute(_args: any): Promise; 5 | static getKodies(keywords: string[]): Promise; 6 | } 7 | export declare const action: (_args: any) => Promise; 8 | //# sourceMappingURL=action.d.ts.map -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/search/action.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"action.d.ts","sourceRoot":"","sources":["action.ts"],"names":[],"mappings":"AAOA,qBAAa,MAAM;IACjB,MAAM,CAAC,cAAc,CAAC,OAAO,EAAE,MAAM;IAWrC,MAAM,CAAC,oBAAoB,CAAC,MAAM,EAAE,GAAG,EAAE;WAwB5B,OAAO,CAAC,KAAK,EAAE,GAAG;WAsBX,SAAS,CAAC,QAAQ,EAAE,MAAM,EAAE;CAMjD;AACD,eAAO,MAAM,MAAM,UAAiB,GAAG,kBAOtC,CAAC"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/search/helper.d.ts: -------------------------------------------------------------------------------- 1 | declare const _default: (args: any) => Promise; 2 | export default _default; 3 | //# sourceMappingURL=helper.d.ts.map 4 | -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/search/helper.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"helper.d.ts","sourceRoot":"","sources":["helper.ts"],"names":[],"mappings":"+BAK4B,GAAG;AAA/B,wBA2BE"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/search/helper.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"helper.js","sourceRoot":"","sources":["helper.ts"],"names":[],"mappings":";;;;;;;;;;;;;;AAAA,kDAA0B;AAC1B,MAAM,EAAE,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;AACzB,MAAM,EAAE,IAAI,EAAE,GAAG,OAAO,CAAC,MAAM,CAAC,CAAC;AACjC,2BAA2B;AAE3B,kBAAe,CAAO,IAAS,EAAE,EAAE;IACjC,wCAAwC;IACxC,IAAI,OAAO,IAAI,CAAC,MAAM,KAAK,WAAW,EAAE;QACtC,IAAI,CAAC,MAAM,GAAG,IAAI,CAAC,OAAO,CAAC,GAAG,EAAE,EAAE,WAAW,CAAC,CAAC;KAChD;IACD,IAAI,CAAC,EAAE,CAAC,UAAU,CAAC,IAAI,CAAC,MAAM,CAAC,EAAE;QAC/B,OAAO,CAAC,GAAG,CACT,eAAK,CAAC,GAAG,CACP,GAAG,eAAK,CAAC,KAAK,CACZ,eAAK,CAAC,KAAK,CAAC,IAAI,CAAC,MAAM,CAAC,CACzB,wDAAwD,CAC1D,CACF,CAAC;QACF,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;KACjB;IACD,MAAM,MAAM,GAAG,IAAI,CAAC,KAAK,CAAC,EAAE,CAAC,YAAY,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC,CAAC;IACxD,MAAM,EAAE,OAAO,GAAG,EAAE,EAAE,GAAG,MAAM,CAAC;IAChC,IAAI,OAAO,CAAC,MAAM,KAAK,CAAC;QAAE,OAAO;IACjC,wCAAwC;IACxC,MAAM,UAAU,GAAG,OAAO,CAAC,GAAG,EAAE,CAAC;IACjC,MAAM,OAAO,GAAG,MAAM,CAAC,OAAO,IAAI,UAAU,CAAC;IAC7C,IAAA,OAAE,EAAC,OAAO,CAAC,CAAC;IACZ,KAAK,MAAM,MAAM,IAAI,OAAO,EAAE;QAC5B,OAAO,CAAC,GAAG,CAAC,kBAAkB,MAAM,EAAE,CAAC,CAAC;QACxC,MAAM,IAAA,MAAC,EAAA,GAAG,MAAM,EAAE,CAAC;KACpB;IACD,IAAA,OAAE,EAAC,UAAU,CAAC,CAAC;AACjB,CAAC,CAAA,CAAC"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/search/index.d.ts: -------------------------------------------------------------------------------- 1 | import { action } from './action'; 2 | export default action; 3 | //# sourceMappingURL=index.d.ts.map -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/search/index.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["index.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC;AAclC,eAAe,MAAM,CAAC"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/search/index.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"index.js","sourceRoot":"","sources":["index.ts"],"names":[],"mappings":";;;;;;;;;;;AAAA,MAAM,EAAE,OAAO,EAAE,GAAG,OAAO,CAAC,WAAW,CAAC,CAAC;AACzC,qCAAkC;AAElC,MAAM,CAAC,OAAO,GAAG,CAAC,OAAuB,EAAE,EAAE;IAC3C,OAAO;SACJ,OAAO,CAAC,QAAQ,CAAC;SACjB,KAAK,CAAC,GAAG,CAAC;SACV,QAAQ,CAAC,eAAe,EAAE,yCAAyC,CAAC;SACpE,WAAW,CAAC,4CAA4C,CAAC;SACzD,MAAM,CAAC,CAAO,QAAkB,EAAE,IAAS,EAAE,EAAE;QAC9C,IAAI,CAAC,QAAQ,GAAG,QAAQ,CAAC;QACzB,OAAO,MAAM,IAAA,eAAM,EAAC,IAAI,CAAC,CAAC;IAC5B,CAAC,CAAA,CAAC,CAAC;AACP,CAAC,CAAC;AAEF,kBAAe,eAAM,CAAC"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/search/index.ts: -------------------------------------------------------------------------------- 1 | const { Command } = require('commander'); 2 | import { action } from './action'; 3 | 4 | module.exports = (program: typeof Command) => { 5 | program 6 | .command('search') 7 | .alias('s') 8 | .argument('[keywords...]', 'search kodyfire packages using keywords') 9 | .description('search kodyfire packages from npm registry') 10 | .action(async (keywords: string[], _opt: any) => { 11 | _opt.keywords = keywords; 12 | return await action(_opt); 13 | }); 14 | }; 15 | 16 | export default action; 17 | -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/watch/index.d.ts: -------------------------------------------------------------------------------- 1 | export {}; 2 | //# sourceMappingURL=index.d.ts.map -------------------------------------------------------------------------------- /packages/kodyfire-cli/commands/watch/index.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["index.ts"],"names":[],"mappings":""} -------------------------------------------------------------------------------- /packages/kodyfire-cli/kodyfire.d.ts: -------------------------------------------------------------------------------- 1 | export declare interface IKody { 2 | parser: IParser; 3 | } 4 | 5 | /** 6 | * The IParser interface 7 | * @alpha 8 | */ 9 | export declare interface IParser { 10 | data: any; 11 | requiresExtract: boolean; 12 | requiresTansform: boolean; 13 | requiresLoad: boolean; 14 | validator: IValidator; 15 | reader(filename: string): any; 16 | parse(data: any): any; 17 | } 18 | 19 | export declare interface IValidator { 20 | rules: any; 21 | errors: any; 22 | validate(data: any): boolean; 23 | } 24 | 25 | export {}; 26 | -------------------------------------------------------------------------------- /packages/kodyfire-cli/src/bin/kody.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"kody.d.ts","sourceRoot":"","sources":["kody.ts"],"names":[],"mappings":";AAEA,QAAA,MAAQ,OAAO,KAAyB,CAAC;AACzC,QAAA,MAAM,OAAO,KAAgB,CAAC;AAC9B,QAAA,MAAQ,WAAW,KAAkB,CAAC;AACtC,QAAA,MAAM,IAAI,KAAkB,EAC1B,IAAI,KAAkB,CAAC;AAEzB,QAAA,MAAQ,OAAO,KAIO,CAAC;AAIvB,QAAA,MAAM,cAAc,WAAY,MAAM,QAGA,CAAC;AAEvC,QAAA,MAAM,MAAM,KAED,CAAC"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/src/bin/watch.mjs: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env zx 2 | 3 | import fs from 'fs'; 4 | import { $ } from 'zx'; 5 | const { join } = require('path'); 6 | const watchFile = async (source) => { 7 | console.log(`Watching for file changes on ${source}`); 8 | fs.watchFile(source, async (event, filename) => { 9 | if (filename) { 10 | console.log(`${filename} file Changed, running kody`); 11 | await $`kody run`; 12 | } 13 | }); 14 | } 15 | const argv = process.argv.slice(3); 16 | let source = argv[0]; 17 | const schema = JSON.parse(fs.readFileSync(source)); 18 | if(schema.sources) { 19 | for (const item of schema.sources) { 20 | await watchFile(item.filename); 21 | } 22 | } else { 23 | await watchFile(source); 24 | } -------------------------------------------------------------------------------- /packages/kodyfire-cli/src/design/generator.wsd: -------------------------------------------------------------------------------- 1 | @startuml 2 | start 3 | package Kodyfire { 4 | package Parser { 5 | :generate output.json; 6 | floating note left: Parsed source 7 | } 8 | package Generator { 9 | :load technology registered actions; 10 | :read output.json; 11 | repeat 12 | :read next concept; 13 | :run action using template; 14 | repeat while (more concept?) is (true) 15 | ->false; 16 | :do action using artifact; 17 | :return result; 18 | } 19 | package Packager { 20 | :package result; 21 | } 22 | } 23 | end 24 | 25 | @enduml -------------------------------------------------------------------------------- /packages/kodyfire-cli/src/helpers/commands/action.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"action.d.ts","sourceRoot":"","sources":["action.ts"],"names":[],"mappings":"AAAA,qBAAa,UAAU;CAAG"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/src/helpers/commands/action.ts: -------------------------------------------------------------------------------- 1 | export class BaseAction {} 2 | -------------------------------------------------------------------------------- /packages/kodyfire-cli/src/lib/cli/worklfow.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"worklfow.d.ts","sourceRoot":"","sources":["worklfow.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,eAAe,CAAC;AAG7C,qBAAa,WAAY,SAAQ,YAAY;gBAC/B,KAAK,EAAE,GAAG;IAKtB,kBAAkB,SAAU,MAAM,WAchC;IACF,eAAe,YAAa,MAAM,WAWhC;IAEF,oBAAoB,WAAY,GAAG,WAGjC;IAEF,iBAAiB,aAEf;CACH"} -------------------------------------------------------------------------------- /packages/kodyfire-cli/src/lib/cli/worklfow.ts: -------------------------------------------------------------------------------- 1 | import { KodyWorkflow } from 'kodyfire-core'; 2 | const boxen = require('boxen'); 3 | const chalk = require('chalk'); 4 | export class CliWorkflow extends KodyWorkflow { 5 | constructor(input: any) { 6 | super(); 7 | this.input = input; 8 | } 9 | 10 | handleKodyNotFound = (name: string) => { 11 | const message = `🚨 ${chalk.bold( 12 | chalk.yellow(name) 13 | )} is not a registered kody.`; 14 | console.log( 15 | boxen(message, { 16 | padding: 1, 17 | margin: 1, 18 | align: 'center', 19 | borderColor: 'red', 20 | borderStyle: 'round', 21 | }) 22 | ); 23 | process.exit(); 24 | }; 25 | handleKodyError = (message: string) => { 26 | console.log( 27 | boxen(message, { 28 | padding: 1, 29 | margin: 1, 30 | align: 'center', 31 | borderColor: 'red', 32 | borderStyle: 'round', 33 | }) 34 | ); 35 | process.exit(); 36 | }; 37 | 38 | handleSourceNotValid = (errors: any) => { 39 | console.log(errors); 40 | process.exit(); 41 | }; 42 | 43 | handleKodySuccess = () => { 44 | console.log(chalk.green('🙌 kody done! ')); 45 | }; 46 | } 47 | -------------------------------------------------------------------------------- /packages/kodyfire-cli/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": "tsconfig", 4 | "lib": ["es2018", "dom"], 5 | "declaration": true, 6 | "declarationMap": true, 7 | "resolveJsonModule": true, 8 | "esModuleInterop": true, 9 | "module": "commonjs", 10 | "moduleResolution": "node", 11 | "noEmitOnError": true, 12 | "noFallthroughCasesInSwitch": true, 13 | "noImplicitAny": true, 14 | "noImplicitThis": true, 15 | "noUnusedParameters": true, 16 | "noUnusedLocals": true, 17 | "rootDir": "", 18 | "skipDefaultLibCheck": true, 19 | "skipLibCheck": true, 20 | "sourceMap": true, 21 | "strictNullChecks": true, 22 | "target": "es6", 23 | "types": ["jasmine", "node"] 24 | }, 25 | "include": ["src/**/*", "commands/**/*"], 26 | "exclude": [ 27 | "src/*/files/**/*", 28 | "commands/create/kody/src/concepts/templates/**/*" 29 | ] 30 | } 31 | -------------------------------------------------------------------------------- /packages/kodyfire-config/config/default.d.ts: -------------------------------------------------------------------------------- 1 | declare const _default: { 2 | mode: string; 3 | useClassicIfKodyFound: boolean; 4 | technology: { 5 | continueOnNotFound: boolean; 6 | prompts: { 7 | useLocalPrompts: boolean; 8 | fallback: string; 9 | }; 10 | }; 11 | technologies: string[]; 12 | prompts: string[]; 13 | }; 14 | export default _default; 15 | //# sourceMappingURL=default.d.ts.map -------------------------------------------------------------------------------- /packages/kodyfire-config/config/default.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"default.d.ts","sourceRoot":"","sources":["default.ts"],"names":[],"mappings":";;;;;;;;;;;;;AAAA,wBAsDE"} -------------------------------------------------------------------------------- /packages/kodyfire-config/config/default.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"default.js","sourceRoot":"","sources":["default.ts"],"names":[],"mappings":";;AAAA,kBAAe;IACX,IAAI,EAAE,IAAI;IACV,qBAAqB,EAAE,IAAI;IAC3B,UAAU,EAAE;QACR,kBAAkB,EAAE,IAAI;QACxB,OAAO,EAAE;YACT,eAAe,EAAE,IAAI;YACrB,QAAQ,EAAE,IAAI;SACb;KACJ;IACD,YAAY,EAAE;QACV,WAAW;QACX,eAAe;QACf,cAAc;QACd,KAAK;QACL,aAAa;QACb,MAAM;QACN,QAAQ;QACR,YAAY;QACZ,SAAS;QACT,OAAO;QACP,IAAI;QACJ,QAAQ;QACR,SAAS;QACT,WAAW;QACX,MAAM;QACN,OAAO;QACP,QAAQ;QACR,SAAS;QACT,UAAU;QACV,WAAW;QACX,QAAQ;QACR,SAAS;QACT,SAAS;QACT,KAAK;QACL,MAAM;QACN,QAAQ;QACR,OAAO;QACP,OAAO;QACP,MAAM;QACN,eAAe;QACf,OAAO;QACP,OAAO;QACP,QAAQ;QACR,QAAQ;QACR,SAAS;QACT,OAAO;QACP,YAAY;QACZ,QAAQ;QACR,QAAQ;KACT;IACH,OAAO,EAAE;QACL,gBAAgB;KACnB;CACJ,CAAC"} -------------------------------------------------------------------------------- /packages/kodyfire-config/index.d.ts: -------------------------------------------------------------------------------- 1 | import * as defaultConfig from './config/default'; 2 | declare class Config { 3 | config: any; 4 | initialConfig: typeof defaultConfig; 5 | constructor(); 6 | private init; 7 | get(key?: string): any; 8 | has(key?: string): any; 9 | getTechnology(alias: string): any; 10 | } 11 | export { Config }; 12 | //# sourceMappingURL=index.d.ts.map -------------------------------------------------------------------------------- /packages/kodyfire-config/index.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,aAAa,MAAM,kBAAkB,CAAC;AAElD,cAAM,MAAM;IACV,MAAM,EAAE,GAAG,CAAC;IACZ,aAAa,uBAAiB;;IAI9B,OAAO,CAAC,IAAI;IAMZ,GAAG,CAAC,GAAG,SAAK;IAIZ,GAAG,CAAC,GAAG,SAAK;IAKV,aAAa,CAAC,KAAK,EAAE,MAAM;CAW9B;AAED,OAAO,EAAE,MAAM,EAAE,CAAC"} -------------------------------------------------------------------------------- /packages/kodyfire-config/index.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"index.js","sourceRoot":"","sources":["index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;AAAA,gEAAkD;AAClD,+BAAuC;AACvC,MAAM,MAAM;IAGV;QADA,kBAAa,GAAG,aAAa,CAAC;QAE5B,IAAI,CAAC,IAAI,EAAE,CAAC;IACd,CAAC;IACO,IAAI;;QACR,OAAO,CAAC,GAAG,CAAC,iBAAiB,CAAC,GAAG,GAAG,IAAA,WAAI,EAAC,SAAS,EAAE,QAAQ,CAAC,GAAG,gBAAS,GACrE,MAAA,OAAO,CAAC,GAAG,CAAC,iBAAiB,CAAC,mCAAI,IAAA,WAAI,EAAC,OAAO,CAAC,GAAG,EAAE,EAAE,OAAO,CAC/D,EAAE,CAAC;QACH,IAAI,CAAC,MAAM,GAAG,OAAO,CAAC,QAAQ,CAAC,CAAC;IACtC,CAAC;IACD,GAAG,CAAC,GAAG,GAAG,EAAE;QACV,IAAG,CAAC,GAAG;YAAE,OAAO,IAAI,CAAC,MAAM,CAAC;QAC5B,OAAO,IAAI,CAAC,MAAM,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC;IAC9B,CAAC;IACD,GAAG,CAAC,GAAG,GAAG,EAAE;QACV,OAAO,IAAI,CAAC,MAAM,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC;IAC9B,CAAC;IACD,gIAAgI;IAC9H,oBAAoB;IACpB,aAAa,CAAC,KAAa;QACvB,MAAM,YAAY,GAAG,IAAI,CAAC,GAAG,CAAC,cAAc,CAAC,CAAC;QAC9C,MAAM,OAAO,GAAG,IAAI,CAAC,GAAG,CAAC,SAAS,CAAC,CAAC;QACpC,IAAI,OAAO,IAAI,OAAO,CAAC,KAAK,CAAC,EAAE;YAC3B,OAAO,OAAO,CAAC,KAAK,CAAC,CAAC;SACzB;QACD,IAAI,YAAY,CAAC,QAAQ,CAAC,KAAK,CAAC,EAAE;YAC9B,OAAO,KAAK,CAAC;SAChB;QACD,OAAO,IAAI,CAAC;IACZ,CAAC;CACR;AAEQ,wBAAM"} -------------------------------------------------------------------------------- /packages/kodyfire-config/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "kodyfire-config", 3 | "version": "0.1.36", 4 | "description": "Kodyfire global configurations", 5 | "main": "index.js", 6 | "scripts": { 7 | "watch": "tsc -w", 8 | "test": "echo \"Error: no test specified\" && exit 1", 9 | "build": "tsc -p tsconfig.json" 10 | }, 11 | "repository": { 12 | "type": "git", 13 | "url": "git+https://github.com/nooqta/kodyfire.git" 14 | }, 15 | "keywords": [ 16 | "kodyfire" 17 | ], 18 | "author": "NOQTA", 19 | "license": "ISC", 20 | "bugs": { 21 | "url": "https://github.com/nooqta/kodyfire/issues" 22 | }, 23 | "homepage": "https://github.com/nooqta/kodyfire#readme", 24 | "dependencies": { 25 | "config": "^3.3.9", 26 | "typescript": "~4.5.5" 27 | }, 28 | "devDependencies": { 29 | "@types/config": "^3.3.0", 30 | "@types/node": "^17.0.14" 31 | }, 32 | "gitHead": "6a69e666b918d428502ce37fae8ccf17b884cbed" 33 | } 34 | -------------------------------------------------------------------------------- /packages/kodyfire-config/test.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"test.js","sourceRoot":"","sources":["test.ts"],"names":[],"mappings":";;;;;AAAA,yCAAuB;AAEvB,OAAO,CAAC,GAAG,CAAC,QAAQ,EAAE,UAAM,CAAC,GAAG,CAAC,SAAS,CAAC,CAAC,CAAC"} -------------------------------------------------------------------------------- /packages/kodyfire-config/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": "./", 4 | "lib": ["es2018", "dom"], 5 | "declaration": true, 6 | "declarationMap": true, 7 | "resolveJsonModule": true, 8 | "esModuleInterop": true, 9 | "allowJs": true, 10 | "module": "commonjs", 11 | "moduleResolution": "node", 12 | "noEmitOnError": true, 13 | "noFallthroughCasesInSwitch": true, 14 | "noImplicitAny": true, 15 | "noImplicitThis": true, 16 | "noUnusedParameters": true, 17 | "noUnusedLocals": true, 18 | "rootDir": "./", 19 | "skipDefaultLibCheck": true, 20 | "skipLibCheck": true, 21 | "sourceMap": true, 22 | "strictNullChecks": true, 23 | "target": "es6", 24 | "types": ["node"] 25 | }, 26 | "include": ["**/*"], 27 | "exclude": ["node_modules", "**/*.tsx"] 28 | } 29 | -------------------------------------------------------------------------------- /packages/kodyfire-core/.gitignore: -------------------------------------------------------------------------------- 1 | node_modules 2 | .npmrc -------------------------------------------------------------------------------- /packages/kodyfire-core/LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2018-present, NOQTA, SUARL. 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /packages/kodyfire-core/Template.d.ts: -------------------------------------------------------------------------------- 1 | export interface Template { 2 | id: any; 3 | name: any; 4 | type: any; 5 | version: any; 6 | enabled: any; 7 | } 8 | //# sourceMappingURL=template.d.ts.map 9 | -------------------------------------------------------------------------------- /packages/kodyfire-core/Template.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"template.js","sourceRoot":"","sources":["template.ts"],"names":[],"mappings":"AAAA,YAAY,CAAC;;AAQb,CAAC"} -------------------------------------------------------------------------------- /packages/kodyfire-core/index.d.ts: -------------------------------------------------------------------------------- 1 | import { Runner, Package } from './lib'; 2 | import { IKody, BaseKody } from './typings/kody'; 3 | import { IParser } from './typings/parser'; 4 | import { IValidator } from './typings/validator'; 5 | import { IGenerator } from './typings/generator'; 6 | import { IAction } from './typings/action'; 7 | import { ActionList } from './typings/actionList'; 8 | import { ITechnology, Technology } from './typings/technology'; 9 | import { IConcept, Source, TemplateSchema } from './typings/concept'; 10 | import { IArgument } from './typings/argument'; 11 | import { Template } from './typings/template'; 12 | import { KodyWorkflow, IKodyWorkflow } from './typings/workflow'; 13 | import { capitalize, camelize, dasherize, decamelize, underscore } from '@angular-devkit/core/src/utils/strings'; 14 | import { Yaml } from './resolvers/yaml'; 15 | export { Runner, Package, IKody, BaseKody, IParser, IValidator, IGenerator, ITechnology, Technology, IConcept, Template, TemplateSchema, Source, IAction, IArgument, ActionList, capitalize, camelize, dasherize, decamelize, underscore, KodyWorkflow, IKodyWorkflow, Yaml, }; 16 | //# sourceMappingURL=index.d.ts.map -------------------------------------------------------------------------------- /packages/kodyfire-core/index.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,OAAO,EAAE,MAAM,OAAO,CAAC;AACxC,OAAO,EAAE,KAAK,EAAE,QAAQ,EAAE,MAAM,gBAAgB,CAAC;AACjD,OAAO,EAAE,OAAO,EAAE,MAAM,kBAAkB,CAAC;AAC3C,OAAO,EAAE,UAAU,EAAE,MAAM,qBAAqB,CAAC;AACjD,OAAO,EAAE,UAAU,EAAE,MAAM,qBAAqB,CAAC;AACjD,OAAO,EAAE,OAAO,EAAE,MAAM,kBAAkB,CAAC;AAC3C,OAAO,EAAE,UAAU,EAAE,MAAM,sBAAsB,CAAC;AAClD,OAAO,EAAE,WAAW,EAAE,UAAU,EAAE,MAAM,sBAAsB,CAAC;AAC/D,OAAO,EAAE,QAAQ,EAAE,MAAM,EAAE,cAAc,EAAE,MAAM,mBAAmB,CAAC;AACrE,OAAO,EAAE,SAAS,EAAE,MAAM,oBAAoB,CAAC;AAC/C,OAAO,EAAE,QAAQ,EAAE,MAAM,oBAAoB,CAAC;AAC9C,OAAO,EAAE,YAAY,EAAE,aAAa,EAAE,MAAM,oBAAoB,CAAC;AACjE,OAAO,EACL,UAAU,EACV,QAAQ,EACR,SAAS,EACT,UAAU,EACV,UAAU,EACX,MAAM,wCAAwC,CAAC;AAChD,OAAO,EAAE,IAAI,EAAE,MAAM,kBAAkB,CAAC;AACxC,OAAO,EACL,MAAM,EACN,OAAO,EACP,KAAK,EACL,QAAQ,EACR,OAAO,EACP,UAAU,EACV,UAAU,EACV,WAAW,EACX,UAAU,EACV,QAAQ,EACR,QAAQ,EACR,cAAc,EACd,MAAM,EACN,OAAO,EACP,SAAS,EACT,UAAU,EACV,UAAU,EACV,QAAQ,EACR,SAAS,EACT,UAAU,EACV,UAAU,EACV,YAAY,EACZ,aAAa,EACb,IAAI,GACL,CAAC"} -------------------------------------------------------------------------------- /packages/kodyfire-core/index.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"index.js","sourceRoot":"","sources":["index.ts"],"names":[],"mappings":";;;AAAA,+BAAwC;AAqBtC,uFArBO,YAAM,OAqBP;AACN,wFAtBe,aAAO,OAsBf;AArBT,yCAAiD;AAuB/C,yFAvBc,eAAQ,OAuBd;AAlBV,qDAAkD;AA8BhD,2FA9BO,uBAAU,OA8BP;AA7BZ,qDAA+D;AAsB7D,2FAtBoB,uBAAU,OAsBpB;AArBZ,+CAAqE;AAyBnE,uFAzBiB,gBAAM,OAyBjB;AAtBR,iDAAiE;AA+B/D,6FA/BO,uBAAY,OA+BP;AA9Bd,oEAMgD;AAmB9C,2FAxBA,oBAAU,OAwBA;AACV,yFAxBA,kBAAQ,OAwBA;AACR,0FAxBA,mBAAS,OAwBA;AACT,2FAxBA,oBAAU,OAwBA;AACV,2FAxBA,oBAAU,OAwBA;AAtBZ,2CAAwC;AAyBtC,qFAzBO,WAAI,OAyBP"} -------------------------------------------------------------------------------- /packages/kodyfire-core/kody.d.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * The IKody interface 3 | * @alpha 4 | */ 5 | import { IParser } from '../parser'; 6 | export interface IKody { 7 | parser: IParser; 8 | } 9 | //# sourceMappingURL=kody.d.ts.map 10 | -------------------------------------------------------------------------------- /packages/kodyfire-core/kody.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"kody.d.ts","sourceRoot":"","sources":["kody.ts"],"names":[],"mappings":"AAAA;;;GAGG;AACH,OAAO,EAAE,OAAO,EAAE,MAAM,UAAU,CAAC;AAEnC,MAAM,WAAW,KAAK;IAClB,MAAM,EAAE,OAAO,CAAC;CAKnB"} -------------------------------------------------------------------------------- /packages/kodyfire-core/lib/index.d.ts: -------------------------------------------------------------------------------- 1 | import { Package } from './package'; 2 | import { Runner } from './runner'; 3 | export { Package, Runner }; 4 | //# sourceMappingURL=index.d.ts.map -------------------------------------------------------------------------------- /packages/kodyfire-core/lib/index.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AACpC,OAAO,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC;AAElC,OAAO,EAAE,OAAO,EAAE,MAAM,EAAE,CAAC"} -------------------------------------------------------------------------------- /packages/kodyfire-core/lib/index.js: -------------------------------------------------------------------------------- 1 | "use strict"; 2 | Object.defineProperty(exports, "__esModule", { value: true }); 3 | exports.Runner = exports.Package = void 0; 4 | const package_1 = require("./package"); 5 | Object.defineProperty(exports, "Package", { enumerable: true, get: function () { return package_1.Package; } }); 6 | const runner_1 = require("./runner"); 7 | Object.defineProperty(exports, "Runner", { enumerable: true, get: function () { return runner_1.Runner; } }); 8 | //# sourceMappingURL=index.js.map -------------------------------------------------------------------------------- /packages/kodyfire-core/lib/index.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"index.js","sourceRoot":"","sources":["index.ts"],"names":[],"mappings":";;;AAAA,uCAAoC;AAG3B,wFAHA,iBAAO,OAGA;AAFhB,qCAAkC;AAEhB,uFAFT,eAAM,OAES"} -------------------------------------------------------------------------------- /packages/kodyfire-core/lib/index.ts: -------------------------------------------------------------------------------- 1 | import { Package } from './package'; 2 | import { Runner } from './runner'; 3 | 4 | export { Package, Runner }; 5 | -------------------------------------------------------------------------------- /packages/kodyfire-core/lib/jsonFactory.d.ts: -------------------------------------------------------------------------------- 1 | export interface ISchema { 2 | type: string; 3 | default?: string; 4 | properties?: any; 5 | items?: ISchema; 6 | } 7 | declare const jsonSchemaToObject: (schema: ISchema) => any; 8 | export default jsonSchemaToObject; 9 | //# sourceMappingURL=jsonFactory.d.ts.map 10 | -------------------------------------------------------------------------------- /packages/kodyfire-core/lib/jsonFactory.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"jsonFactory.d.ts","sourceRoot":"","sources":["jsonFactory.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,OAAO;IACpB,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,UAAU,CAAC,EAAE,GAAG,CAAC;IACjB,KAAK,CAAC,EAAE,OAAO,CAAC;CACnB;AACD,QAAA,MAAM,kBAAkB,WAAY,OAAO,QAmC1C,CAAC;AAEF,eAAe,kBAAkB,CAAC"} -------------------------------------------------------------------------------- /packages/kodyfire-core/lib/jsonFactory.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"jsonFactory.js","sourceRoot":"","sources":["jsonFactory.ts"],"names":[],"mappings":";;AAMA,MAAM,kBAAkB,GAAG,CAAC,MAAe,EAAE,EAAE;IAC3C,IAAI,aAAkB,CAAC;IACvB,IAAI,CAAC,MAAM,CAAC,IAAI,EAAE;QACd,OAAO;KACV;IAED,QAAQ,MAAM,CAAC,IAAI,EAAE;QACjB,KAAK,QAAQ,CAAC;QACd,KAAK,QAAQ,CAAC;QACd,KAAK,SAAS;YACV,IAAI,MAAM,CAAC,OAAO,KAAK,SAAS,EAAE;gBAC9B,aAAa,GAAG,MAAM,CAAC,OAAO,CAAC;aAClC;YACL,MAAM;KACT;IAED,IAAI,MAAM,CAAC,IAAI,KAAK,OAAO,EAAC;QACxB,IAAG,MAAM,CAAC,KAAK,EAAE;YACb,aAAa,GAAG,kBAAkB,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC;SACpD;aAAM;YACH,aAAa,GAAG,EAAE,CAAC;SACtB;KAEJ;IAED,IAAI,MAAM,CAAC,IAAI,KAAK,QAAQ,EAAC;QACzB,aAAa,GAAG,EAAE,CAAC;QACnB,IAAI,MAAM,CAAC,UAAU,EAAC;YAClB,MAAM,CAAC,IAAI,CAAC,MAAM,CAAC,UAAU,CAAC,CAAC,OAAO,CAAC,CAAC,GAAU,EAAE,EAAE;gBAClD,MAAM,WAAW,GAAG,MAAM,CAAC,UAAU,CAAC,GAAG,CAAC,CAAC;gBAC3C,aAAa,CAAC,GAAG,CAAC,GAAG,kBAAkB,CAAC,WAAW,CAAC,CAAC;YACzD,CAAC,CAAC,CAAC;SACN;KACJ;IACD,OAAO,aAAa,CAAC;AACzB,CAAC,CAAC;AAEF,kBAAe,kBAAkB,CAAC"} -------------------------------------------------------------------------------- /packages/kodyfire-core/lib/package.d.ts: -------------------------------------------------------------------------------- 1 | import { IKody } from '../typings/kody'; 2 | import { IPackage } from '../typings/package'; 3 | export declare class Package { 4 | registery: string[]; 5 | kody: IKody; 6 | registeredKodies: Map; 7 | constructor(kody: IKody); 8 | registerPackages(): Promise; 9 | static getInstalledKodiesName(dirname?: string): any; 10 | static getInstalledKodies(dirname?: string): Promise; 11 | static getInstalledKodiesFromPath(dirname: string): Promise; 12 | getRegistredPackages(): string[]; 13 | static getPackageJson(dirname?: string): any; 14 | registerKodyPackage(_package: any): Promise; 15 | private static getPackageInfo; 16 | registerPackage(_package: any): Promise; 17 | registerListeners(_package: IPackage): void; 18 | getRecipeSchema(dependency: string, dirname?: string): Promise; 19 | } 20 | //# sourceMappingURL=package.d.ts.map -------------------------------------------------------------------------------- /packages/kodyfire-core/lib/package.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"package.d.ts","sourceRoot":"","sources":["package.ts"],"names":[],"mappings":"AAAA,OAAO,EAAY,KAAK,EAAE,MAAM,iBAAiB,CAAC;AAClD,OAAO,EAAE,QAAQ,EAAE,MAAM,oBAAoB,CAAC;AAI9C,qBAAa,OAAO;IAClB,SAAS,EAAE,MAAM,EAAE,CAAM;IACzB,IAAI,EAAE,KAAK,CAAC;IACZ,gBAAgB,EAAE,GAAG,CAAC,MAAM,EAAE,KAAK,CAAC,CAAC;gBACzB,IAAI,EAAE,KAAK;IAKjB,gBAAgB;IAOtB,MAAM,CAAC,sBAAsB,CAAC,OAAO,SAAgB;WAiBxC,kBAAkB,CAAC,OAAO,SAAgB;WAS1C,0BAA0B,CAAC,OAAO,EAAE,MAAM;IAavD,oBAAoB;IAGpB,MAAM,CAAC,cAAc,CAAC,OAAO,SAAgB;IAGvC,mBAAmB,CAAC,QAAQ,EAAE,GAAG;mBAsBlB,cAAc;IAY7B,eAAe,CAAC,QAAQ,EAAE,GAAG;IAQnC,iBAAiB,CAAC,QAAQ,EAAE,QAAQ;IAmB9B,eAAe,CAAC,UAAU,EAAE,MAAM,EAAE,OAAO,SAAgB;CAMlE"} -------------------------------------------------------------------------------- /packages/kodyfire-core/lib/runner.d.ts: -------------------------------------------------------------------------------- 1 | import { IKody, IKodyWorkflow } from '..'; 2 | export declare class Runner implements IKodyWorkflow { 3 | options: any; 4 | input: any; 5 | constructor(options: any); 6 | run(_options: any): Promise; 7 | postExecute(kody: IKody): Promise; 8 | getSchemaDefinition(dependency: string, rootDir?: string): any; 9 | preExecute(dependency: string, kody: IKody, data: any[]): Promise; 10 | handleKodyNotFound(name: any): void; 11 | getKody(name: any): Promise; 12 | handleSourceNotValid(errors: any): void; 13 | handleKodySuccess(): void; 14 | handleKodyError(message: any): void; 15 | } 16 | //# sourceMappingURL=runner.d.ts.map -------------------------------------------------------------------------------- /packages/kodyfire-core/lib/runner.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"runner.d.ts","sourceRoot":"","sources":["runner.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,aAAa,EAAW,MAAM,IAAI,CAAC;AAInD,qBAAa,MAAO,YAAW,aAAa;IAC1C,OAAO,EAAE,GAAG,CAAC;IACb,KAAK,EAAE,GAAG,CAAC;gBACC,OAAO,EAAE,GAAG;IAIlB,GAAG,CAAC,QAAQ,EAAE,GAAG;IAyCjB,WAAW,CAAC,IAAI,EAAE,KAAK;IA+B7B,mBAAmB,CAAC,UAAU,EAAE,MAAM,EAAE,OAAO,SAAgB;IAQzD,UAAU,CAAC,UAAU,EAAE,MAAM,EAAE,IAAI,EAAE,KAAK,EAAE,IAAI,EAAE,GAAG,EAAE;IAgC7D,kBAAkB,CAAC,IAAI,EAAE,GAAG;IAGtB,OAAO,CAAC,IAAI,EAAE,GAAG,GAAG,OAAO,CAAC,GAAG,CAAC;IAItC,oBAAoB,CAAC,MAAM,EAAE,GAAG;IAIhC,iBAAiB;IAIjB,eAAe,CAAC,OAAO,EAAE,GAAG;CAG7B"} -------------------------------------------------------------------------------- /packages/kodyfire-core/main.d.ts: -------------------------------------------------------------------------------- 1 | import { IKody } from './parser'; 2 | export { IKody }; 3 | -------------------------------------------------------------------------------- /packages/kodyfire-core/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "kodyfire-core", 3 | "version": "0.1.36", 4 | "description": "Common types used by kodyfire.", 5 | "main": "index.js", 6 | "repository": { 7 | "type": "git", 8 | "url": "https://github.com/nooqta/kodyfire.git", 9 | "directory": "packages/kodyfire-core" 10 | }, 11 | "bugs": { 12 | "url": "https://github.com/nooqta/kodyfire/issues" 13 | }, 14 | "scripts": { 15 | "watch": "tsc -w", 16 | "test": "echo \"Error: no test specified\" && exit 1", 17 | "build": "tsc -p tsconfig.json" 18 | }, 19 | "author": "NOQTA", 20 | "license": "ISC", 21 | "dependencies": { 22 | "@angular-devkit/schematics": "^12.2.3", 23 | "js-yaml": "^4.1.0", 24 | "lodash": "^4.17.21", 25 | "morphmorph": "^0.1.3", 26 | "typescript": "~4.5.5" 27 | }, 28 | "devDependencies": { 29 | "@types/node": "^17.0.14" 30 | }, 31 | "gitHead": "6a69e666b918d428502ce37fae8ccf17b884cbed" 32 | } 33 | -------------------------------------------------------------------------------- /packages/kodyfire-core/parser.d.ts: -------------------------------------------------------------------------------- 1 | import { IValidator } from './validator'; 2 | /** 3 | * The IParser interface 4 | * @alpha 5 | */ 6 | export interface IParser { 7 | data: any; 8 | requiresExtract: boolean; 9 | requiresTansform: boolean; 10 | requiresLoad: boolean; 11 | validator: IValidator; 12 | reader(filename: string): any; 13 | parse(data: any): any; 14 | } 15 | //# sourceMappingURL=parser.d.ts.map 16 | -------------------------------------------------------------------------------- /packages/kodyfire-core/parser.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"parser.d.ts","sourceRoot":"","sources":["parser.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,aAAa,CAAC;AACzC;;;GAGG;AACH,MAAM,WAAW,OAAO;IACpB,IAAI,EAAE,GAAG,CAAC;IACV,eAAe,EAAE,OAAO,CAAC;IACzB,gBAAgB,EAAE,OAAO,CAAC;IAC1B,YAAY,EAAE,OAAO,CAAC;IACtB,SAAS,EAAE,UAAU,CAAC;IACtB,MAAM,CAAC,QAAQ,EAAE,MAAM,GAAG,GAAG,CAAC;IAC9B,KAAK,CAAC,IAAI,EAAC,GAAG,GAAG,GAAG,CAAC;CACxB"} -------------------------------------------------------------------------------- /packages/kodyfire-core/parser.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"parser.js","sourceRoot":"","sources":["parser.ts"],"names":[],"mappings":""} -------------------------------------------------------------------------------- /packages/kodyfire-core/resolvers/yaml.d.ts: -------------------------------------------------------------------------------- 1 | export declare class Yaml { 2 | static resolve(source: string): any; 3 | } 4 | //# sourceMappingURL=yaml.d.ts.map -------------------------------------------------------------------------------- /packages/kodyfire-core/resolvers/yaml.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"yaml.d.ts","sourceRoot":"","sources":["yaml.ts"],"names":[],"mappings":"AAGA,qBAAa,IAAI;WACD,OAAO,CAAC,MAAM,EAAE,MAAM,GAAG,GAAG;CAI3C"} -------------------------------------------------------------------------------- /packages/kodyfire-core/resolvers/yaml.js: -------------------------------------------------------------------------------- 1 | "use strict"; 2 | Object.defineProperty(exports, "__esModule", { value: true }); 3 | exports.Yaml = void 0; 4 | const { load } = require('js-yaml'); 5 | const { readFileSync } = require('fs'); 6 | class Yaml { 7 | static resolve(source) { 8 | const data = readFileSync(source, 'utf8'); 9 | return load(data.toString()); 10 | } 11 | } 12 | exports.Yaml = Yaml; 13 | //# sourceMappingURL=yaml.js.map -------------------------------------------------------------------------------- /packages/kodyfire-core/resolvers/yaml.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"yaml.js","sourceRoot":"","sources":["yaml.ts"],"names":[],"mappings":";;;AAAA,MAAM,EAAE,IAAI,EAAE,GAAG,OAAO,CAAC,SAAS,CAAC,CAAC;AACpC,MAAM,EAAE,YAAY,EAAE,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;AAEvC,MAAa,IAAI;IACR,MAAM,CAAC,OAAO,CAAC,MAAc;QAClC,MAAM,IAAI,GAAG,YAAY,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;QAC1C,OAAO,IAAI,CAAC,IAAI,CAAC,QAAQ,EAAE,CAAC,CAAC;IAC/B,CAAC;CACF;AALD,oBAKC"} -------------------------------------------------------------------------------- /packages/kodyfire-core/resolvers/yaml.ts: -------------------------------------------------------------------------------- 1 | const { load } = require('js-yaml'); 2 | const { readFileSync } = require('fs'); 3 | 4 | export class Yaml { 5 | public static resolve(source: string): any { 6 | const data = readFileSync(source, 'utf8'); 7 | return load(data.toString()); 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /packages/kodyfire-core/schemas/action.json: -------------------------------------------------------------------------------- 1 | { 2 | "type": "object", 3 | "properties": { 4 | "kind": { "type": "string" }, 5 | "arguments": { 6 | "elements": { "$ref": "argument" }, 7 | "description": "The action definition." 8 | } 9 | }, 10 | "additionalProperties": false, 11 | "required": ["kind", "arguments"] 12 | } 13 | -------------------------------------------------------------------------------- /packages/kodyfire-core/schemas/argument.json: -------------------------------------------------------------------------------- 1 | { 2 | "type": "object", 3 | "properties": { 4 | "key": { 5 | "type": "string" 6 | }, 7 | "arguments": { 8 | "type": "string" 9 | } 10 | }, 11 | "additionalProperties": false, 12 | "required": ["key"] 13 | } 14 | -------------------------------------------------------------------------------- /packages/kodyfire-core/schemas/concept.json: -------------------------------------------------------------------------------- 1 | { 2 | "title": "Concept Schema", 3 | "type": "object", 4 | "properties": { 5 | "name": { "type": "string", "required": true }, 6 | "actions": { 7 | "elements": { "$ref": "action" }, 8 | "description": "The action definition." 9 | }, 10 | "defaultAction": { "type": "string" } 11 | }, 12 | "additionalProperties": false, 13 | "required": ["name", "actions"] 14 | } 15 | -------------------------------------------------------------------------------- /packages/kodyfire-core/template.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"template.d.ts","sourceRoot":"","sources":["template.ts"],"names":[],"mappings":"AACA,MAAM,WAAW,QAAQ;IACvB,EAAE,EAAE,GAAG,CAAC;IACR,IAAI,EAAE,GAAG,CAAC;IACV,IAAI,EAAE,GAAG,CAAC;IACV,OAAO,EAAE,GAAG,CAAC;IACb,OAAO,EAAE,GAAG,CAAC;CACd"} -------------------------------------------------------------------------------- /packages/kodyfire-core/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": "./", 4 | "lib": ["es2018", "dom"], 5 | "declaration": true, 6 | "declarationMap": true, 7 | "resolveJsonModule": true, 8 | "esModuleInterop": true, 9 | "allowJs": true, 10 | "module": "commonjs", 11 | "moduleResolution": "node", 12 | "noEmitOnError": true, 13 | "noFallthroughCasesInSwitch": true, 14 | "noImplicitAny": true, 15 | "noImplicitThis": true, 16 | "noUnusedParameters": true, 17 | "noUnusedLocals": true, 18 | "rootDir": "./", 19 | "skipDefaultLibCheck": true, 20 | "skipLibCheck": true, 21 | "sourceMap": true, 22 | "strictNullChecks": true, 23 | "target": "es6", 24 | "types": ["node"] 25 | }, 26 | "include": ["**/*"], 27 | "exclude": ["node_modules", "**/*.tsx"] 28 | } 29 | -------------------------------------------------------------------------------- /packages/kodyfire-core/typings/Template.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | Object.defineProperty(exports, "__esModule", { value: true }); 3 | //# sourceMappingURL=template.js.map -------------------------------------------------------------------------------- /packages/kodyfire-core/typings/action.d.ts: -------------------------------------------------------------------------------- 1 | import { ActionBase } from '@angular-devkit/schematics'; 2 | export type IAction = ActionBase 3 | //# sourceMappingURL=action.d.ts.map 4 | -------------------------------------------------------------------------------- /packages/kodyfire-core/typings/action.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"action.d.ts","sourceRoot":"","sources":["action.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,4BAA4B,CAAC;AAExD,MAAM,WAAW,OAAQ,SAAQ,UAAU;CAC1C"} -------------------------------------------------------------------------------- /packages/kodyfire-core/typings/action.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"action.js","sourceRoot":"","sources":["action.ts"],"names":[],"mappings":""} -------------------------------------------------------------------------------- /packages/kodyfire-core/typings/actionList.d.ts: -------------------------------------------------------------------------------- 1 | import { ActionList as BaseActionList } from '@angular-devkit/schematics'; 2 | export declare class ActionList extends BaseActionList { 3 | } 4 | //# sourceMappingURL=actionList.d.ts.map -------------------------------------------------------------------------------- /packages/kodyfire-core/typings/actionList.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"actionList.d.ts","sourceRoot":"","sources":["actionList.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,IAAI,cAAc,EAAE,MAAM,4BAA4B,CAAC;AAE1E,qBAAa,UAAW,SAAQ,cAAc;CAAG"} -------------------------------------------------------------------------------- /packages/kodyfire-core/typings/actionList.js: -------------------------------------------------------------------------------- 1 | "use strict"; 2 | Object.defineProperty(exports, "__esModule", { value: true }); 3 | exports.ActionList = void 0; 4 | const schematics_1 = require("@angular-devkit/schematics"); 5 | class ActionList extends schematics_1.ActionList { 6 | } 7 | exports.ActionList = ActionList; 8 | //# sourceMappingURL=actionList.js.map -------------------------------------------------------------------------------- /packages/kodyfire-core/typings/actionList.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"actionList.js","sourceRoot":"","sources":["actionList.ts"],"names":[],"mappings":";;;AAAA,2DAA0E;AAE1E,MAAa,UAAW,SAAQ,uBAAc;CAAG;AAAjD,gCAAiD"} -------------------------------------------------------------------------------- /packages/kodyfire-core/typings/actionList.ts: -------------------------------------------------------------------------------- 1 | import { ActionList as BaseActionList } from '@angular-devkit/schematics'; 2 | 3 | export class ActionList extends BaseActionList {} 4 | -------------------------------------------------------------------------------- /packages/kodyfire-core/typings/argument.d.ts: -------------------------------------------------------------------------------- 1 | export interface IArgument { 2 | name: string; 3 | value: string; 4 | } 5 | //# sourceMappingURL=argument.d.ts.map -------------------------------------------------------------------------------- /packages/kodyfire-core/typings/argument.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"argument.d.ts","sourceRoot":"","sources":["argument.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,SAAS;IACxB,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,MAAM,CAAC;CACf"} -------------------------------------------------------------------------------- /packages/kodyfire-core/typings/argument.js: -------------------------------------------------------------------------------- 1 | "use strict"; 2 | Object.defineProperty(exports, "__esModule", { value: true }); 3 | //# sourceMappingURL=argument.js.map -------------------------------------------------------------------------------- /packages/kodyfire-core/typings/argument.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"argument.js","sourceRoot":"","sources":["argument.ts"],"names":[],"mappings":""} -------------------------------------------------------------------------------- /packages/kodyfire-core/typings/argument.ts: -------------------------------------------------------------------------------- 1 | export interface IArgument { 2 | name: string; 3 | value: string; 4 | } 5 | -------------------------------------------------------------------------------- /packages/kodyfire-core/typings/artifact.d.ts: -------------------------------------------------------------------------------- 1 | export declare enum ArtifactType { 2 | file = 0 3 | } 4 | export interface IArtifact { 5 | name: string; 6 | type: ArtifactType; 7 | } 8 | //# sourceMappingURL=artifact.d.ts.map -------------------------------------------------------------------------------- /packages/kodyfire-core/typings/artifact.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"artifact.d.ts","sourceRoot":"","sources":["artifact.ts"],"names":[],"mappings":"AAAA,oBAAY,YAAY;IACtB,IAAI,IAAA;CACL;AACD,MAAM,WAAW,SAAS;IACxB,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,YAAY,CAAC;CACpB"} -------------------------------------------------------------------------------- /packages/kodyfire-core/typings/artifact.js: -------------------------------------------------------------------------------- 1 | "use strict"; 2 | Object.defineProperty(exports, "__esModule", { value: true }); 3 | exports.ArtifactType = void 0; 4 | var ArtifactType; 5 | (function (ArtifactType) { 6 | ArtifactType[ArtifactType["file"] = 0] = "file"; 7 | })(ArtifactType = exports.ArtifactType || (exports.ArtifactType = {})); 8 | //# sourceMappingURL=artifact.js.map -------------------------------------------------------------------------------- /packages/kodyfire-core/typings/artifact.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"artifact.js","sourceRoot":"","sources":["artifact.ts"],"names":[],"mappings":";;;AAAA,IAAY,YAEX;AAFD,WAAY,YAAY;IACtB,+CAAI,CAAA;AACN,CAAC,EAFW,YAAY,GAAZ,oBAAY,KAAZ,oBAAY,QAEvB"} -------------------------------------------------------------------------------- /packages/kodyfire-core/typings/artifact.ts: -------------------------------------------------------------------------------- 1 | export enum ArtifactType { 2 | file, 3 | } 4 | export interface IArtifact { 5 | name: string; 6 | type: ArtifactType; 7 | } 8 | -------------------------------------------------------------------------------- /packages/kodyfire-core/typings/concept.d.ts: -------------------------------------------------------------------------------- 1 | import { Technology } from '..'; 2 | export declare enum Source { 3 | Template = 0 4 | } 5 | export interface TemplateSchema { 6 | path: string; 7 | options: string[]; 8 | } 9 | export interface IConcept { 10 | name: string; 11 | templatesPath?: string; 12 | defaultAction: string; 13 | source?: Source; 14 | template: TemplateSchema; 15 | outputDir?: string; 16 | technology: Technology; 17 | generate(data: any): any; 18 | } 19 | //# sourceMappingURL=concept.d.ts.map -------------------------------------------------------------------------------- /packages/kodyfire-core/typings/concept.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"concept.d.ts","sourceRoot":"","sources":["concept.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,IAAI,CAAC;AAChC,oBAAY,MAAM;IAChB,QAAQ,IAAA;CACT;AACD,MAAM,WAAW,cAAc;IAC7B,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,EAAE,MAAM,EAAE,CAAC;CACnB;AACD,MAAM,WAAW,QAAQ;IACvB,IAAI,EAAE,MAAM,CAAC;IACb,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,aAAa,EAAE,MAAM,CAAC;IACtB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,QAAQ,EAAE,cAAc,CAAC;IACzB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,UAAU,EAAE,UAAU,CAAC;IACvB,QAAQ,CAAC,IAAI,EAAE,GAAG,GAAG,GAAG,CAAC;CAC1B"} -------------------------------------------------------------------------------- /packages/kodyfire-core/typings/concept.js: -------------------------------------------------------------------------------- 1 | "use strict"; 2 | Object.defineProperty(exports, "__esModule", { value: true }); 3 | exports.Source = void 0; 4 | var Source; 5 | (function (Source) { 6 | Source[Source["Template"] = 0] = "Template"; 7 | })(Source = exports.Source || (exports.Source = {})); 8 | //# sourceMappingURL=concept.js.map -------------------------------------------------------------------------------- /packages/kodyfire-core/typings/concept.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"concept.js","sourceRoot":"","sources":["concept.ts"],"names":[],"mappings":";;;AACA,IAAY,MAEX;AAFD,WAAY,MAAM;IAChB,2CAAQ,CAAA;AACV,CAAC,EAFW,MAAM,GAAN,cAAM,KAAN,cAAM,QAEjB"} -------------------------------------------------------------------------------- /packages/kodyfire-core/typings/concept.ts: -------------------------------------------------------------------------------- 1 | import { Technology } from '..'; 2 | export enum Source { 3 | Template, 4 | } 5 | export interface TemplateSchema { 6 | path: string; 7 | options: string[]; 8 | } 9 | export interface IConcept { 10 | name: string; 11 | templatesPath?: string; 12 | defaultAction: string; 13 | source?: Source; 14 | template: TemplateSchema; 15 | outputDir?: string; 16 | technology: Technology; 17 | generate(data: any): any; 18 | } 19 | -------------------------------------------------------------------------------- /packages/kodyfire-core/typings/generator.d.ts: -------------------------------------------------------------------------------- 1 | import { Tree } from '@angular-devkit/schematics'; 2 | import { ITechnology } from '..'; 3 | export interface IGenerator { 4 | technology: ITechnology; 5 | generate(content: any, tree?: Tree): any; 6 | } 7 | //# sourceMappingURL=generator.d.ts.map -------------------------------------------------------------------------------- /packages/kodyfire-core/typings/generator.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"generator.d.ts","sourceRoot":"","sources":["generator.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,MAAM,4BAA4B,CAAC;AAClD,OAAO,EAAE,WAAW,EAAE,MAAM,IAAI,CAAC;AAEjC,MAAM,WAAW,UAAU;IACzB,UAAU,EAAE,WAAW,CAAC;IACxB,QAAQ,CAAC,OAAO,EAAE,GAAG,EAAE,IAAI,CAAC,EAAE,IAAI,GAAG,GAAG,CAAC;CAC1C"} -------------------------------------------------------------------------------- /packages/kodyfire-core/typings/generator.js: -------------------------------------------------------------------------------- 1 | "use strict"; 2 | Object.defineProperty(exports, "__esModule", { value: true }); 3 | //# sourceMappingURL=generator.js.map -------------------------------------------------------------------------------- /packages/kodyfire-core/typings/generator.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"generator.js","sourceRoot":"","sources":["generator.ts"],"names":[],"mappings":""} -------------------------------------------------------------------------------- /packages/kodyfire-core/typings/generator.ts: -------------------------------------------------------------------------------- 1 | import { Tree } from '@angular-devkit/schematics'; 2 | import { ITechnology } from '..'; 3 | 4 | export interface IGenerator { 5 | technology: ITechnology; 6 | generate(content: any, tree?: Tree): any; 7 | } 8 | -------------------------------------------------------------------------------- /packages/kodyfire-core/typings/kody.js: -------------------------------------------------------------------------------- 1 | "use strict"; 2 | Object.defineProperty(exports, "__esModule", { value: true }); 3 | exports.BaseKody = void 0; 4 | class BaseKody { 5 | get data() { 6 | throw new Error('Method not implemented.'); 7 | } 8 | get errors() { 9 | throw new Error('Method not implemented.'); 10 | } 11 | parse(_content) { 12 | throw new Error('Method not implemented.'); 13 | } 14 | read(_source) { 15 | throw new Error('Method not implemented.'); 16 | } 17 | write(_source, _content) { 18 | throw new Error('Method not implemented.'); 19 | } 20 | generate(_content) { 21 | throw new Error('Method not implemented.'); 22 | } 23 | whereami() { 24 | throw new Error('Method not implemented.'); 25 | } 26 | whoami() { 27 | throw new Error('Method not implemented.'); 28 | } 29 | } 30 | exports.BaseKody = BaseKody; 31 | //# sourceMappingURL=kody.js.map -------------------------------------------------------------------------------- /packages/kodyfire-core/typings/kody.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"kody.js","sourceRoot":"","sources":["kody.ts"],"names":[],"mappings":";;;AAwBA,MAAsB,QAAQ;IAO5B,IAAI,IAAI;QACN,MAAM,IAAI,KAAK,CAAC,yBAAyB,CAAC,CAAC;IAC7C,CAAC;IACD,IAAI,MAAM;QACR,MAAM,IAAI,KAAK,CAAC,yBAAyB,CAAC,CAAC;IAC7C,CAAC;IACD,KAAK,CAAC,QAAa;QACjB,MAAM,IAAI,KAAK,CAAC,yBAAyB,CAAC,CAAC;IAC7C,CAAC;IACD,IAAI,CAAC,OAAe;QAClB,MAAM,IAAI,KAAK,CAAC,yBAAyB,CAAC,CAAC;IAC7C,CAAC;IACD,KAAK,CAAC,OAAe,EAAE,QAAa;QAClC,MAAM,IAAI,KAAK,CAAC,yBAAyB,CAAC,CAAC;IAC7C,CAAC;IACD,QAAQ,CAAC,QAAa;QACpB,MAAM,IAAI,KAAK,CAAC,yBAAyB,CAAC,CAAC;IAC7C,CAAC;IACD,QAAQ;QACN,MAAM,IAAI,KAAK,CAAC,yBAAyB,CAAC,CAAC;IAC7C,CAAC;IACD,MAAM;QACJ,MAAM,IAAI,KAAK,CAAC,yBAAyB,CAAC,CAAC;IAC7C,CAAC;CACF;AA/BD,4BA+BC"} -------------------------------------------------------------------------------- /packages/kodyfire-core/typings/package.d.ts: -------------------------------------------------------------------------------- 1 | export interface IPackage { 2 | id: string; 3 | name?: string; 4 | type: string; 5 | version: string; 6 | } 7 | //# sourceMappingURL=package.d.ts.map -------------------------------------------------------------------------------- /packages/kodyfire-core/typings/package.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"package.d.ts","sourceRoot":"","sources":["package.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,QAAQ;IACvB,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,EAAE,MAAM,CAAC;CACjB"} -------------------------------------------------------------------------------- /packages/kodyfire-core/typings/package.js: -------------------------------------------------------------------------------- 1 | "use strict"; 2 | Object.defineProperty(exports, "__esModule", { value: true }); 3 | //# sourceMappingURL=package.js.map -------------------------------------------------------------------------------- /packages/kodyfire-core/typings/package.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"package.js","sourceRoot":"","sources":["package.ts"],"names":[],"mappings":""} -------------------------------------------------------------------------------- /packages/kodyfire-core/typings/package.ts: -------------------------------------------------------------------------------- 1 | export interface IPackage { 2 | id: string; 3 | name?: string; 4 | type: string; 5 | version: string; 6 | } 7 | -------------------------------------------------------------------------------- /packages/kodyfire-core/typings/parser.d.ts: -------------------------------------------------------------------------------- 1 | import { IValidator } from './validator'; 2 | /** 3 | * The IParser interface 4 | * @alpha 5 | */ 6 | export interface IParser { 7 | data: any; 8 | requiresExtract: boolean; 9 | requiresTansform: boolean; 10 | requiresLoad: boolean; 11 | validator: IValidator; 12 | reader(filename: string): any; 13 | write(filename: string, data: any): any; 14 | parse(data: any): any; 15 | } 16 | //# sourceMappingURL=parser.d.ts.map -------------------------------------------------------------------------------- /packages/kodyfire-core/typings/parser.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"parser.d.ts","sourceRoot":"","sources":["parser.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,aAAa,CAAC;AACzC;;;GAGG;AACH,MAAM,WAAW,OAAO;IACtB,IAAI,EAAE,GAAG,CAAC;IACV,eAAe,EAAE,OAAO,CAAC;IACzB,gBAAgB,EAAE,OAAO,CAAC;IAC1B,YAAY,EAAE,OAAO,CAAC;IACtB,SAAS,EAAE,UAAU,CAAC;IACtB,MAAM,CAAC,QAAQ,EAAE,MAAM,GAAG,GAAG,CAAC;IAC9B,KAAK,CAAC,QAAQ,EAAE,MAAM,EAAE,IAAI,EAAE,GAAG,GAAG,GAAG,CAAC;IACxC,KAAK,CAAC,IAAI,EAAE,GAAG,GAAG,GAAG,CAAC;CACvB"} -------------------------------------------------------------------------------- /packages/kodyfire-core/typings/parser.js: -------------------------------------------------------------------------------- 1 | "use strict"; 2 | Object.defineProperty(exports, "__esModule", { value: true }); 3 | //# sourceMappingURL=parser.js.map -------------------------------------------------------------------------------- /packages/kodyfire-core/typings/parser.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"parser.js","sourceRoot":"","sources":["parser.ts"],"names":[],"mappings":""} -------------------------------------------------------------------------------- /packages/kodyfire-core/typings/parser.ts: -------------------------------------------------------------------------------- 1 | import { IValidator } from './validator'; 2 | /** 3 | * The IParser interface 4 | * @alpha 5 | */ 6 | export interface IParser { 7 | data: any; 8 | requiresExtract: boolean; 9 | requiresTansform: boolean; 10 | requiresLoad: boolean; 11 | validator: IValidator; 12 | reader(filename: string): any; 13 | write(filename: string, data: any): any; 14 | parse(data: any): any; 15 | } 16 | -------------------------------------------------------------------------------- /packages/kodyfire-core/typings/service.d.ts: -------------------------------------------------------------------------------- 1 | export interface Service { 2 | new (param: string): T; 3 | } 4 | export declare class ServiceFactory { 5 | createService(ctor: Service, param: string): T; 6 | } 7 | //# sourceMappingURL=service.d.ts.map 8 | -------------------------------------------------------------------------------- /packages/kodyfire-core/typings/service.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"service.d.ts","sourceRoot":"","sources":["service.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,OAAO,CAAC,CAAC;IACtB,KAAK,KAAK,EAAE,MAAM,GAAG,CAAC,CAAC;CACxB;AAED,qBAAa,cAAc,CAAC,CAAC;IAEpB,aAAa,CAAC,IAAI,EAAE,OAAO,CAAC,CAAC,CAAC,EAAE,KAAK,EAAE,MAAM;CAIrD"} -------------------------------------------------------------------------------- /packages/kodyfire-core/typings/technology.d.ts: -------------------------------------------------------------------------------- 1 | import { ActionList } from './actionList'; 2 | import { IConcept } from './concept'; 3 | export interface ITechnology { 4 | id: string; 5 | name: string; 6 | version: string; 7 | rootDir: string; 8 | input?: any; 9 | concepts: Map; 10 | assets: any; 11 | actions: ActionList; 12 | params: any; 13 | prepareConcept(dependency: string, conceptName: string, data: any): any; 14 | } 15 | export declare class Technology implements ITechnology { 16 | id: string; 17 | name: string; 18 | version: string; 19 | rootDir: string; 20 | input?: any; 21 | concepts: Map; 22 | assets: any; 23 | actions: ActionList; 24 | params: any; 25 | constructor(); 26 | prepareConcept(dependency: string, conceptName: string, preparedConcept: any): Promise; 27 | } 28 | //# sourceMappingURL=technology.d.ts.map -------------------------------------------------------------------------------- /packages/kodyfire-core/typings/technology.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"technology.d.ts","sourceRoot":"","sources":["technology.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAC1C,OAAO,EAAE,QAAQ,EAAE,MAAM,WAAW,CAAC;AAErC,MAAM,WAAW,WAAW;IAC1B,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,EAAE,MAAM,CAAC;IAChB,OAAO,EAAE,MAAM,CAAC;IAChB,KAAK,CAAC,EAAE,GAAG,CAAC;IACZ,QAAQ,EAAE,GAAG,CAAC,MAAM,EAAE,QAAQ,CAAC,CAAC;IAChC,MAAM,EAAE,GAAG,CAAC;IACZ,OAAO,EAAE,UAAU,CAAC;IACpB,MAAM,EAAE,GAAG,CAAC;IACZ,cAAc,CAAC,UAAU,EAAE,MAAM,EAAE,WAAW,EAAE,MAAM,EAAE,IAAI,EAAE,GAAG,GAAG,GAAG,CAAC;CACzE;AAED,qBAAa,UAAW,YAAW,WAAW;IAC5C,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,EAAE,MAAM,CAAC;IAChB,OAAO,EAAE,MAAM,CAAC;IAChB,KAAK,CAAC,EAAE,GAAG,CAAC;IACZ,QAAQ,EAAE,GAAG,CAAC,MAAM,EAAE,QAAQ,CAAC,CAAC;IAChC,MAAM,EAAE,GAAG,CAAC;IACZ,OAAO,EAAE,UAAU,CAAC;IACpB,MAAM,EAAE,GAAG,CAAC;;IAKN,cAAc,CAClB,UAAU,EAAE,MAAM,EAClB,WAAW,EAAE,MAAM,EACnB,eAAe,EAAE,GAAG;CAiBvB"} -------------------------------------------------------------------------------- /packages/kodyfire-core/typings/technology.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"technology.js","sourceRoot":"","sources":["technology.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,6CAA0C;AAgB1C,MAAa,UAAU;IAUrB;QACE,IAAI,CAAC,OAAO,GAAG,IAAI,uBAAU,EAAE,CAAC;QAChC,IAAI,CAAC,QAAQ,GAAG,IAAI,GAAG,EAAE,CAAC;IAC5B,CAAC;IACK,cAAc,CAClB,UAAkB,EAClB,WAAmB,EACnB,eAAoB;;YAEpB,MAAM,EAAE,MAAM,EAAE,GAAG,wDAAa,GAAG,UAAU,EAAE,GAAC,CAAC;YACjD,MAAM,aAAa,GAAG,MAAM,CAAC,UAAU,CAAC,WAAW,CAAC,CAAC;YACrD,MAAM,YAAY,GAAa,MAAM,CAAC,QAAQ,CAAC;YAC/C,KAAK,MAAM,WAAW,IAAI,YAAY,EAAE;gBACtC,0EAA0E;gBAC1E,+DAA+D;gBAC/D,IAAI;gBACJ,eAAe,mCACV,eAAe,KAClB,CAAC,WAAW,CAAC,EAAE,aAAa,CAAC,WAAW,CAAC,CAAC,OAAO,IAAI,EAAE,GACxD,CAAC;aACH;YAED,OAAO,eAAe,CAAC;QACzB,CAAC;KAAA;CACF;AAlCD,gCAkCC"} -------------------------------------------------------------------------------- /packages/kodyfire-core/typings/template.d.ts: -------------------------------------------------------------------------------- 1 | export interface Template { 2 | id: any; 3 | name: any; 4 | type: any; 5 | version: any; 6 | enabled: any; 7 | } 8 | //# sourceMappingURL=template.d.ts.map -------------------------------------------------------------------------------- /packages/kodyfire-core/typings/template.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"template.d.ts","sourceRoot":"","sources":["template.ts"],"names":[],"mappings":"AACA,MAAM,WAAW,QAAQ;IACvB,EAAE,EAAE,GAAG,CAAC;IACR,IAAI,EAAE,GAAG,CAAC;IACV,IAAI,EAAE,GAAG,CAAC;IACV,OAAO,EAAE,GAAG,CAAC;IACb,OAAO,EAAE,GAAG,CAAC;CACd"} -------------------------------------------------------------------------------- /packages/kodyfire-core/typings/template.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"template.js","sourceRoot":"","sources":["template.ts"],"names":[],"mappings":"AAAA,YAAY,CAAC"} -------------------------------------------------------------------------------- /packages/kodyfire-core/typings/template.ts: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | export interface Template { 3 | id: any; 4 | name: any; 5 | type: any; 6 | version: any; 7 | enabled: any; 8 | } 9 | -------------------------------------------------------------------------------- /packages/kodyfire-core/typings/validator.d.ts: -------------------------------------------------------------------------------- 1 | export interface IValidator { 2 | rules: any; 3 | errors: any; 4 | validate(data: any): boolean; 5 | } 6 | //# sourceMappingURL=validator.d.ts.map -------------------------------------------------------------------------------- /packages/kodyfire-core/typings/validator.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"validator.d.ts","sourceRoot":"","sources":["validator.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,UAAU;IACzB,KAAK,EAAE,GAAG,CAAC;IACX,MAAM,EAAE,GAAG,CAAC;IACZ,QAAQ,CAAC,IAAI,EAAE,GAAG,GAAG,OAAO,CAAC;CAC9B"} -------------------------------------------------------------------------------- /packages/kodyfire-core/typings/validator.js: -------------------------------------------------------------------------------- 1 | "use strict"; 2 | Object.defineProperty(exports, "__esModule", { value: true }); 3 | //# sourceMappingURL=validator.js.map -------------------------------------------------------------------------------- /packages/kodyfire-core/typings/validator.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"validator.js","sourceRoot":"","sources":["validator.ts"],"names":[],"mappings":""} -------------------------------------------------------------------------------- /packages/kodyfire-core/typings/validator.ts: -------------------------------------------------------------------------------- 1 | export interface IValidator { 2 | rules: any; 3 | errors: any; 4 | validate(data: any): boolean; 5 | } 6 | -------------------------------------------------------------------------------- /packages/kodyfire-core/typings/workflow.d.ts: -------------------------------------------------------------------------------- 1 | export interface IKodyWorkflow { 2 | input: any; 3 | getKody(name: string): any; 4 | handleKodyNotFound(name: string): any; 5 | handleSourceNotValid(name: string): any; 6 | handleKodySuccess(name: string): any; 7 | handleKodyError(name: string): any; 8 | } 9 | export declare class KodyWorkflow implements IKodyWorkflow { 10 | handleKodyError(message: string): void; 11 | input: any; 12 | getKody: (_name: string) => Promise; 13 | handleKodyNotFound: (name: string) => any; 14 | handleSourceNotValid: (errors: any) => any; 15 | handleKodySuccess: (name: string) => any; 16 | } 17 | //# sourceMappingURL=workflow.d.ts.map -------------------------------------------------------------------------------- /packages/kodyfire-core/typings/workflow.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"workflow.d.ts","sourceRoot":"","sources":["workflow.ts"],"names":[],"mappings":"AAEA,MAAM,WAAW,aAAa;IAC5B,KAAK,EAAE,GAAG,CAAC;IACX,OAAO,CAAC,IAAI,EAAE,MAAM,GAAG,GAAG,CAAC;IAC3B,kBAAkB,CAAC,IAAI,EAAE,MAAM,GAAG,GAAG,CAAC;IACtC,oBAAoB,CAAC,IAAI,EAAE,MAAM,GAAG,GAAG,CAAC;IACxC,iBAAiB,CAAC,IAAI,EAAE,MAAM,GAAG,GAAG,CAAC;IACrC,eAAe,CAAC,IAAI,EAAE,MAAM,GAAG,GAAG,CAAC;CACpC;AAED,qBAAa,YAAa,YAAW,aAAa;IAChD,eAAe,CAAC,OAAO,EAAE,MAAM;IAG/B,KAAK,EAAE,GAAG,CAAC;IACJ,OAAO,UAAiB,MAAM,KAAG,QAAQ,GAAG,CAAC,CAGlD;IACK,kBAAkB,SAAU,MAAM,KAAG,GAAG,CAE7C;IAEK,oBAAoB,WAAY,GAAG,KAAG,GAAG,CAG9C;IAEK,iBAAiB,SAAU,MAAM,KAAG,GAAG,CAE5C;CACH"} -------------------------------------------------------------------------------- /packages/kodyfire-core/typings/workflow.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"workflow.js","sourceRoot":"","sources":["workflow.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,0BAA6B;AAW7B,MAAa,YAAY;IAAzB;QAKS,YAAO,GAAG,CAAO,KAAa,EAAgB,EAAE;YACrD,MAAM,QAAQ,GAAG,MAAM,WAAO,CAAC,kBAAkB,EAAE,CAAC;YACpD,OAAO,QAAQ,CAAC,IAAI,CAAC,CAAC,IAAS,EAAE,EAAE,CAAC,IAAI,CAAC,EAAE,KAAK,KAAK,CAAC,CAAC;QACzD,CAAC,CAAA,CAAC;QACK,uBAAkB,GAAG,CAAC,IAAY,EAAO,EAAE;YAChD,OAAO,CAAC,GAAG,CAAC,QAAQ,IAAI,aAAa,CAAC,CAAC;QACzC,CAAC,CAAC;QAEK,yBAAoB,GAAG,CAAC,MAAW,EAAO,EAAE;YACjD,OAAO,CAAC,GAAG,CAAC,wBAAwB,CAAC,CAAC;YACtC,OAAO,CAAC,GAAG,CAAC,MAAM,CAAC,CAAC;QACtB,CAAC,CAAC;QAEK,sBAAiB,GAAG,CAAC,IAAY,EAAO,EAAE;YAC/C,OAAO,CAAC,GAAG,CAAC,QAAQ,IAAI,WAAW,CAAC,CAAC;QACvC,CAAC,CAAC;IACJ,CAAC;IApBC,eAAe,CAAC,OAAe;QAC7B,OAAO,CAAC,GAAG,CAAC,GAAG,OAAO,EAAE,CAAC,CAAC;IAC5B,CAAC;CAkBF;AArBD,oCAqBC"} -------------------------------------------------------------------------------- /packages/kodyfire-core/typings/workflow.ts: -------------------------------------------------------------------------------- 1 | import { Package } from '..'; 2 | 3 | export interface IKodyWorkflow { 4 | input: any; 5 | getKody(name: string): any; 6 | handleKodyNotFound(name: string): any; 7 | handleSourceNotValid(name: string): any; 8 | handleKodySuccess(name: string): any; 9 | handleKodyError(name: string): any; 10 | } 11 | 12 | export class KodyWorkflow implements IKodyWorkflow { 13 | handleKodyError(message: string) { 14 | console.log(`${message}`); 15 | } 16 | input: any; 17 | public getKody = async (_name: string): Promise => { 18 | const packages = await Package.getInstalledKodies(); 19 | return packages.find((kody: any) => kody.id === _name); 20 | }; 21 | public handleKodyNotFound = (name: string): any => { 22 | console.log(`Kody ${name} not found.`); 23 | }; 24 | 25 | public handleSourceNotValid = (errors: any): any => { 26 | console.log(`Kody source not valid.`); 27 | console.log(errors); 28 | }; 29 | 30 | public handleKodySuccess = (name: string): any => { 31 | console.log(`Kody ${name} success.`); 32 | }; 33 | } 34 | -------------------------------------------------------------------------------- /packages/kodyfire-core/utils/jsonSchemaToObject.d.ts: -------------------------------------------------------------------------------- 1 | export interface ISchema { 2 | type: string; 3 | default?: string; 4 | properties?: any; 5 | items?: ISchema; 6 | } 7 | declare const jsonSchemaToObject: (key: string, schema: ISchema, data: any) => any; 8 | export default jsonSchemaToObject; 9 | //# sourceMappingURL=jsonSchemaToObject.d.ts.map -------------------------------------------------------------------------------- /packages/kodyfire-core/utils/jsonSchemaToObject.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"jsonSchemaToObject.d.ts","sourceRoot":"","sources":["jsonSchemaToObject.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,OAAO;IACtB,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,UAAU,CAAC,EAAE,GAAG,CAAC;IACjB,KAAK,CAAC,EAAE,OAAO,CAAC;CACjB;AACD,QAAA,MAAM,kBAAkB,QAAS,MAAM,UAAU,OAAO,QAAQ,GAAG,QA0ClE,CAAC;AAEF,eAAe,kBAAkB,CAAC"} -------------------------------------------------------------------------------- /packages/kodyfire-core/validator.d.ts: -------------------------------------------------------------------------------- 1 | export interface IValidator { 2 | rules: any; 3 | errors: any; 4 | validate(data: any): boolean; 5 | } 6 | //# sourceMappingURL=validator.d.ts.map 7 | -------------------------------------------------------------------------------- /packages/kodyfire-core/validator.d.ts.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"validator.d.ts","sourceRoot":"","sources":["validator.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,UAAU;IACvB,KAAK,EAAE,GAAG,CAAC;IACX,MAAM,EAAE,GAAG,CAAC;IACZ,QAAQ,CAAC,IAAI,EAAE,GAAG,GAAG,OAAO,CAAC;CAChC"} -------------------------------------------------------------------------------- /packages/kodyfire-core/validator.js.map: -------------------------------------------------------------------------------- 1 | {"version":3,"file":"validator.js","sourceRoot":"","sources":["validator.ts"],"names":[],"mappings":""} -------------------------------------------------------------------------------- /scripts/gum/commit.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | TYPE=$(gum choose "fix" "feat" "docs" "style" "refactor" "test" "chore" "revert") 3 | SCOPE=$(gum input --placeholder "scope") 4 | 5 | # Since the scope is optional, wrap it in parentheses if it has a value. 6 | test -n "$SCOPE" && SCOPE="($SCOPE)" 7 | 8 | # Pre-populate the input with the type(scope): so that the user may change it 9 | SUMMARY=$(gum input --value "$TYPE$SCOPE: " --placeholder "Summary of this change") 10 | # DESCRIPTION=$(gum write --placeholder "Details of this change") 11 | 12 | # Commit these changes 13 | # gum confirm "Commit changes?" && git commit -m "$SUMMARY" -m "$DESCRIPTION" 14 | gum confirm "Commit changes?" && git commit -m "$SUMMARY" -------------------------------------------------------------------------------- /scripts/kodyfire/postpublish.mjs: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env zx 2 | 3 | 4 | /* 5 | We check the latest lerna version 6 | We update the package.json version 7 | and git commit and push 8 | */ 9 | /*jshint esversion: 6 */ 10 | import { $, fs, cd } from 'zx'; 11 | const { 12 | execSync 13 | } = require('child_process'); 14 | const path = require('path'); 15 | const packageJsonPath = path.resolve(__dirname, '../../package.json'); 16 | const lernaJsonPath = path.resolve(__dirname, '../../lerna.json'); 17 | 18 | // read lerna.json version 19 | let {version} = await fs.readJson(lernaJsonPath); 20 | let packageJson = await fs.readJson(packageJsonPath); 21 | packageJson.version = version; 22 | // write package.json 23 | fs.writeJson(packageJsonPath, packageJson, { 24 | spaces: 2 25 | }); 26 | // access root folder 27 | cd(`${process.cwd()}`); 28 | // commmit and push 29 | await $`git status`; 30 | await $`git add .`; 31 | await $`git commit -m "chore: update version to ${version}"`; 32 | await $`git push`; 33 | await $`git push github main`; 34 | await $`npm publish`; 35 | -------------------------------------------------------------------------------- /test/index.test.js: -------------------------------------------------------------------------------- 1 | const { beforeAll, afterAll, describe, it, expect } = require('@jest/globals'); 2 | 3 | /** this code is called once before any test is called */ 4 | beforeAll(async () => { 5 | Object.defineProperty(global, 'document', {}); 6 | }); 7 | 8 | /** this code is called once before all the tested are finished */ 9 | // eslint-disable-next-line @typescript-eslint/no-empty-function 10 | afterAll(async () => {}); 11 | 12 | describe('Kodyfire in general', () => { 13 | it('test kodyfire is running', async () => { 14 | expect(true).toBe(true); 15 | }); 16 | }); 17 | 18 | require('./packages/kodyfire-cli'); 19 | -------------------------------------------------------------------------------- /test/jest.config.js: -------------------------------------------------------------------------------- 1 | 'use strict'; 2 | 3 | module.exports = { 4 | testEnvironment: 'jsdom', 5 | globals: { 6 | 'ts-jest': { 7 | tsConfig: 'tsconfig.json', 8 | isolatedModules: true, 9 | diagnostics: false, 10 | }, 11 | }, 12 | testMatch: ['/**/*.test.js'], 13 | testPathIgnorePatterns: ['/src/', 'node_modules'], 14 | // Jest transformations -- this adds support for TypeScript 15 | // using ts-jest 16 | preset: 'ts-jest', 17 | transform: { 18 | '^.+\\.[t|j]sx?$': 'ts-jest', 19 | }, 20 | }; 21 | -------------------------------------------------------------------------------- /test/packages/kodyfire-cli/index.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nooqta/kodyfire/82d1cb624cfc5dacade7a92fc274f1ca589cc37e/test/packages/kodyfire-cli/index.js -------------------------------------------------------------------------------- /tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": "tsconfig", 4 | "lib": ["es2018"], 5 | "declaration": true, 6 | "declarationMap": true, 7 | "resolveJsonModule": true, 8 | "esModuleInterop": true, 9 | "module": "commonjs", 10 | "moduleResolution": "node", 11 | "noEmitOnError": true, 12 | "noFallthroughCasesInSwitch": true, 13 | "noImplicitAny": true, 14 | "noImplicitThis": true, 15 | "noUnusedParameters": true, 16 | "noUnusedLocals": true, 17 | "rootDir": "", 18 | "skipDefaultLibCheck": true, 19 | "skipLibCheck": true, 20 | "sourceMap": true, 21 | "strictNullChecks": true, 22 | "target": "es6", 23 | "types": ["node"] 24 | }, 25 | "include": [ 26 | "packages/*/src/**/*", 27 | "packages/*/commands/**/*", 28 | "packages/*/lib/**/*" 29 | ], 30 | "exclude": [ 31 | "src/*/files/**/*", 32 | "packages/*/src/concepts/templates/**/*", 33 | "packages/kodyfire-cli/dist/**/*", 34 | "packages/kodyfire-builder/**/*", 35 | "packages/*/dist", 36 | "**/*.tsx" 37 | ] 38 | } 39 | --------------------------------------------------------------------------------