projen 0.70.2 → 0.70.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.jsii +108 -90
- package/docs/api/API.md +2 -0
- package/lib/.types-compat/ts3.9/lib/_resolve.d.ts +2 -0
- package/lib/.types-compat/ts3.9/lib/awscdk/auto-discover.d.ts +129 -0
- package/lib/.types-compat/ts3.9/lib/awscdk/awscdk-app-java.d.ts +53 -0
- package/lib/.types-compat/ts3.9/lib/awscdk/awscdk-app-py.d.ts +49 -0
- package/lib/.types-compat/ts3.9/lib/awscdk/awscdk-app-ts.d.ts +81 -0
- package/lib/.types-compat/ts3.9/lib/awscdk/awscdk-construct.d.ts +89 -0
- package/lib/.types-compat/ts3.9/lib/awscdk/awscdk-deps-java.d.ts +7 -0
- package/lib/.types-compat/ts3.9/lib/awscdk/awscdk-deps-js.d.ts +7 -0
- package/lib/.types-compat/ts3.9/lib/awscdk/awscdk-deps-py.d.ts +7 -0
- package/lib/.types-compat/ts3.9/lib/awscdk/awscdk-deps.d.ts +168 -0
- package/lib/.types-compat/ts3.9/lib/awscdk/awscdk-pytest-sample.d.ts +5 -0
- package/lib/.types-compat/ts3.9/lib/awscdk/cdk-config.d.ts +122 -0
- package/lib/.types-compat/ts3.9/lib/awscdk/cdk-tasks.d.ts +33 -0
- package/lib/.types-compat/ts3.9/lib/awscdk/index.d.ts +14 -0
- package/lib/.types-compat/ts3.9/lib/awscdk/integration-test.d.ts +46 -0
- package/lib/.types-compat/ts3.9/lib/awscdk/internal.d.ts +20 -0
- package/lib/.types-compat/ts3.9/lib/awscdk/lambda-extension.d.ts +68 -0
- package/lib/.types-compat/ts3.9/lib/awscdk/lambda-function.d.ts +171 -0
- package/lib/.types-compat/ts3.9/lib/build/build-workflow.d.ts +180 -0
- package/lib/.types-compat/ts3.9/lib/build/index.d.ts +1 -0
- package/lib/.types-compat/ts3.9/lib/builtin-example.task.d.ts +0 -0
- package/lib/.types-compat/ts3.9/lib/cdk/auto-discover-base.d.ts +45 -0
- package/lib/.types-compat/ts3.9/lib/cdk/construct-lib.d.ts +38 -0
- package/lib/.types-compat/ts3.9/lib/cdk/consts.d.ts +6 -0
- package/lib/.types-compat/ts3.9/lib/cdk/index.d.ts +5 -0
- package/lib/.types-compat/ts3.9/lib/cdk/integration-test-base.d.ts +53 -0
- package/lib/.types-compat/ts3.9/lib/cdk/internal.d.ts +4 -0
- package/lib/.types-compat/ts3.9/lib/cdk/jsii-docgen.d.ts +20 -0
- package/lib/.types-compat/ts3.9/lib/cdk/jsii-project.d.ts +153 -0
- package/lib/.types-compat/ts3.9/lib/cdk8s/auto-discover.d.ts +33 -0
- package/lib/.types-compat/ts3.9/lib/cdk8s/cdk8s-app-py.d.ts +39 -0
- package/lib/.types-compat/ts3.9/lib/cdk8s/cdk8s-app-ts.d.ts +45 -0
- package/lib/.types-compat/ts3.9/lib/cdk8s/cdk8s-construct.d.ts +71 -0
- package/lib/.types-compat/ts3.9/lib/cdk8s/cdk8s-deps-js.d.ts +4 -0
- package/lib/.types-compat/ts3.9/lib/cdk8s/cdk8s-deps-py.d.ts +4 -0
- package/lib/.types-compat/ts3.9/lib/cdk8s/cdk8s-deps.d.ts +144 -0
- package/lib/.types-compat/ts3.9/lib/cdk8s/index.d.ts +7 -0
- package/lib/.types-compat/ts3.9/lib/cdk8s/integration-test.d.ts +13 -0
- package/lib/.types-compat/ts3.9/lib/cdktf/cdktf-construct.d.ts +26 -0
- package/lib/.types-compat/ts3.9/lib/cdktf/index.d.ts +1 -0
- package/lib/.types-compat/ts3.9/lib/circleci/circleci.d.ts +132 -0
- package/lib/.types-compat/ts3.9/lib/circleci/constant.d.ts +5 -0
- package/lib/.types-compat/ts3.9/lib/circleci/index.d.ts +3 -0
- package/lib/.types-compat/ts3.9/lib/circleci/model.d.ts +260 -0
- package/lib/.types-compat/ts3.9/lib/cleanup.d.ts +2 -0
- package/lib/.types-compat/ts3.9/lib/cli/cmds/new.d.ts +9 -0
- package/lib/.types-compat/ts3.9/lib/cli/index.d.ts +1 -0
- package/lib/.types-compat/ts3.9/lib/cli/macros.d.ts +1 -0
- package/lib/.types-compat/ts3.9/lib/cli/synth.d.ts +19 -0
- package/lib/.types-compat/ts3.9/lib/cli/tasks.d.ts +7 -0
- package/lib/.types-compat/ts3.9/lib/cli/util.d.ts +19 -0
- package/lib/.types-compat/ts3.9/lib/clobber.d.ts +5 -0
- package/lib/.types-compat/ts3.9/lib/common.d.ts +5 -0
- package/lib/.types-compat/ts3.9/lib/component.d.ts +20 -0
- package/lib/.types-compat/ts3.9/lib/dependencies.d.ts +160 -0
- package/lib/.types-compat/ts3.9/lib/dev-env.d.ts +80 -0
- package/lib/.types-compat/ts3.9/lib/docker-compose/docker-compose-network.d.ts +103 -0
- package/lib/.types-compat/ts3.9/lib/docker-compose/docker-compose-port.d.ts +44 -0
- package/lib/.types-compat/ts3.9/lib/docker-compose/docker-compose-render.d.ts +2 -0
- package/lib/.types-compat/ts3.9/lib/docker-compose/docker-compose-service.d.ts +155 -0
- package/lib/.types-compat/ts3.9/lib/docker-compose/docker-compose-volume.d.ts +64 -0
- package/lib/.types-compat/ts3.9/lib/docker-compose/docker-compose.d.ts +99 -0
- package/lib/.types-compat/ts3.9/lib/docker-compose/index.d.ts +5 -0
- package/lib/.types-compat/ts3.9/lib/file.d.ts +119 -0
- package/lib/.types-compat/ts3.9/lib/gitattributes.d.ts +26 -0
- package/lib/.types-compat/ts3.9/lib/github/actions-provider.d.ts +28 -0
- package/lib/.types-compat/ts3.9/lib/github/auto-approve.d.ts +44 -0
- package/lib/.types-compat/ts3.9/lib/github/auto-merge.d.ts +41 -0
- package/lib/.types-compat/ts3.9/lib/github/constants.d.ts +20 -0
- package/lib/.types-compat/ts3.9/lib/github/dependabot.d.ts +247 -0
- package/lib/.types-compat/ts3.9/lib/github/github-credentials.d.ts +58 -0
- package/lib/.types-compat/ts3.9/lib/github/github-project.d.ts +177 -0
- package/lib/.types-compat/ts3.9/lib/github/github.d.ts +110 -0
- package/lib/.types-compat/ts3.9/lib/github/index.d.ts +15 -0
- package/lib/.types-compat/ts3.9/lib/github/mergify.d.ts +81 -0
- package/lib/.types-compat/ts3.9/lib/github/pr-template.d.ts +19 -0
- package/lib/.types-compat/ts3.9/lib/github/pull-request-lint.d.ts +48 -0
- package/lib/.types-compat/ts3.9/lib/github/stale-util.d.ts +8 -0
- package/lib/.types-compat/ts3.9/lib/github/stale.d.ts +85 -0
- package/lib/.types-compat/ts3.9/lib/github/task-workflow.d.ts +119 -0
- package/lib/.types-compat/ts3.9/lib/github/util.d.ts +1 -0
- package/lib/.types-compat/ts3.9/lib/github/workflow-actions.d.ts +78 -0
- package/lib/.types-compat/ts3.9/lib/github/workflows-model.d.ts +1031 -0
- package/lib/.types-compat/ts3.9/lib/github/workflows.d.ts +108 -0
- package/lib/.types-compat/ts3.9/lib/gitlab/configuration-model.d.ts +536 -0
- package/lib/.types-compat/ts3.9/lib/gitlab/configuration.d.ts +170 -0
- package/lib/.types-compat/ts3.9/lib/gitlab/gitlab-configuration.d.ts +19 -0
- package/lib/.types-compat/ts3.9/lib/gitlab/index.d.ts +4 -0
- package/lib/.types-compat/ts3.9/lib/gitlab/nested-configuration.d.ts +11 -0
- package/lib/.types-compat/ts3.9/lib/gitpod.d.ts +301 -0
- package/lib/.types-compat/ts3.9/lib/ignore-file.d.ts +59 -0
- package/lib/.types-compat/ts3.9/lib/index.d.ts +51 -0
- package/lib/.types-compat/ts3.9/lib/ini.d.ts +15 -0
- package/lib/.types-compat/ts3.9/lib/inventory.d.ts +46 -0
- package/lib/.types-compat/ts3.9/lib/java/index.d.ts +7 -0
- package/lib/.types-compat/ts3.9/lib/java/java-project.d.ts +141 -0
- package/lib/.types-compat/ts3.9/lib/java/junit.d.ts +29 -0
- package/lib/.types-compat/ts3.9/lib/java/maven-compile.d.ts +26 -0
- package/lib/.types-compat/ts3.9/lib/java/maven-packaging.d.ts +34 -0
- package/lib/.types-compat/ts3.9/lib/java/maven-sample.d.ts +14 -0
- package/lib/.types-compat/ts3.9/lib/java/pom.d.ts +214 -0
- package/lib/.types-compat/ts3.9/lib/java/projenrc.d.ts +59 -0
- package/lib/.types-compat/ts3.9/lib/javascript/bundler.d.ts +174 -0
- package/lib/.types-compat/ts3.9/lib/javascript/eslint.d.ts +175 -0
- package/lib/.types-compat/ts3.9/lib/javascript/index.d.ts +10 -0
- package/lib/.types-compat/ts3.9/lib/javascript/jest.d.ts +599 -0
- package/lib/.types-compat/ts3.9/lib/javascript/node-package.d.ts +605 -0
- package/lib/.types-compat/ts3.9/lib/javascript/node-project.d.ts +464 -0
- package/lib/.types-compat/ts3.9/lib/javascript/npm-config.d.ts +40 -0
- package/lib/.types-compat/ts3.9/lib/javascript/prettier.d.ts +358 -0
- package/lib/.types-compat/ts3.9/lib/javascript/projenrc.d.ts +18 -0
- package/lib/.types-compat/ts3.9/lib/javascript/render-options.d.ts +88 -0
- package/lib/.types-compat/ts3.9/lib/javascript/typescript-config.d.ts +403 -0
- package/lib/.types-compat/ts3.9/lib/javascript/upgrade-dependencies.d.ts +188 -0
- package/lib/.types-compat/ts3.9/lib/javascript/util.d.ts +21 -0
- package/lib/.types-compat/ts3.9/lib/json-patch.d.ts +75 -0
- package/lib/.types-compat/ts3.9/lib/json.d.ts +27 -0
- package/lib/.types-compat/ts3.9/lib/license.d.ts +31 -0
- package/lib/.types-compat/ts3.9/lib/logger.d.ts +73 -0
- package/lib/.types-compat/ts3.9/lib/logging.d.ts +8 -0
- package/lib/.types-compat/ts3.9/lib/makefile.d.ts +77 -0
- package/lib/.types-compat/ts3.9/lib/object-file.d.ts +155 -0
- package/lib/.types-compat/ts3.9/lib/option-hints.d.ts +18 -0
- package/lib/.types-compat/ts3.9/lib/project-build.d.ts +41 -0
- package/lib/.types-compat/ts3.9/lib/project.d.ts +374 -0
- package/lib/.types-compat/ts3.9/lib/projects.d.ts +63 -0
- package/lib/.types-compat/ts3.9/lib/projenrc-json.d.ts +27 -0
- package/lib/.types-compat/ts3.9/lib/projenrc.d.ts +18 -0
- package/lib/.types-compat/ts3.9/lib/python/index.d.ts +14 -0
- package/lib/.types-compat/ts3.9/lib/python/pip.d.ts +32 -0
- package/lib/.types-compat/ts3.9/lib/python/poetry.d.ts +177 -0
- package/lib/.types-compat/ts3.9/lib/python/projenrc.d.ts +32 -0
- package/lib/.types-compat/ts3.9/lib/python/pytest-sample.d.ts +21 -0
- package/lib/.types-compat/ts3.9/lib/python/pytest.d.ts +24 -0
- package/lib/.types-compat/ts3.9/lib/python/python-deps.d.ts +30 -0
- package/lib/.types-compat/ts3.9/lib/python/python-env.d.ts +6 -0
- package/lib/.types-compat/ts3.9/lib/python/python-packaging.d.ts +62 -0
- package/lib/.types-compat/ts3.9/lib/python/python-project.d.ts +190 -0
- package/lib/.types-compat/ts3.9/lib/python/python-sample.d.ts +17 -0
- package/lib/.types-compat/ts3.9/lib/python/requirements-file.d.ts +29 -0
- package/lib/.types-compat/ts3.9/lib/python/setuppy.d.ts +70 -0
- package/lib/.types-compat/ts3.9/lib/python/setuptools.d.ts +15 -0
- package/lib/.types-compat/ts3.9/lib/python/venv.d.ts +28 -0
- package/lib/.types-compat/ts3.9/lib/readme.d.ts +28 -0
- package/lib/.types-compat/ts3.9/lib/release/bump-version.d.ts +72 -0
- package/lib/.types-compat/ts3.9/lib/release/bump-version.task.d.ts +1 -0
- package/lib/.types-compat/ts3.9/lib/release/index.d.ts +3 -0
- package/lib/.types-compat/ts3.9/lib/release/publisher.d.ts +533 -0
- package/lib/.types-compat/ts3.9/lib/release/release-trigger.d.ts +97 -0
- package/lib/.types-compat/ts3.9/lib/release/release.d.ts +338 -0
- package/lib/.types-compat/ts3.9/lib/release/reset-version.task.d.ts +1 -0
- package/lib/.types-compat/ts3.9/lib/release/tag-version.d.ts +31 -0
- package/lib/.types-compat/ts3.9/lib/release/tag-version.task.d.ts +1 -0
- package/lib/.types-compat/ts3.9/lib/release/update-changelog.d.ts +36 -0
- package/lib/.types-compat/ts3.9/lib/release/update-changelog.task.d.ts +1 -0
- package/lib/.types-compat/ts3.9/lib/renovatebot.d.ts +99 -0
- package/lib/.types-compat/ts3.9/lib/run-projenrc-json.task.d.ts +1 -0
- package/lib/.types-compat/ts3.9/lib/sample-file.d.ts +88 -0
- package/lib/.types-compat/ts3.9/lib/semver.d.ts +34 -0
- package/lib/.types-compat/ts3.9/lib/smithy/smithy-build.d.ts +156 -0
- package/lib/.types-compat/ts3.9/lib/source-code.d.ts +46 -0
- package/lib/.types-compat/ts3.9/lib/task-model.d.ts +130 -0
- package/lib/.types-compat/ts3.9/lib/task-runtime.d.ts +32 -0
- package/lib/.types-compat/ts3.9/lib/task.d.ts +129 -0
- package/lib/.types-compat/ts3.9/lib/tasks.d.ts +51 -0
- package/lib/.types-compat/ts3.9/lib/testing.d.ts +18 -0
- package/lib/.types-compat/ts3.9/lib/textfile.d.ts +33 -0
- package/lib/.types-compat/ts3.9/lib/toml.d.ts +15 -0
- package/lib/.types-compat/ts3.9/lib/typescript/index.d.ts +4 -0
- package/lib/.types-compat/ts3.9/lib/typescript/projenrc-ts.d.ts +43 -0
- package/lib/.types-compat/ts3.9/lib/typescript/projenrc.d.ts +27 -0
- package/lib/.types-compat/ts3.9/lib/typescript/typescript-typedoc.d.ts +7 -0
- package/lib/.types-compat/ts3.9/lib/typescript/typescript.d.ts +163 -0
- package/lib/.types-compat/ts3.9/lib/util/semver.d.ts +43 -0
- package/lib/.types-compat/ts3.9/lib/util/synth.d.ts +42 -0
- package/lib/.types-compat/ts3.9/lib/util.d.ts +131 -0
- package/lib/.types-compat/ts3.9/lib/version.d.ts +45 -0
- package/lib/.types-compat/ts3.9/lib/vscode/devcontainer.d.ts +86 -0
- package/lib/.types-compat/ts3.9/lib/vscode/extensions.d.ts +36 -0
- package/lib/.types-compat/ts3.9/lib/vscode/index.d.ts +5 -0
- package/lib/.types-compat/ts3.9/lib/vscode/launch-config.d.ts +90 -0
- package/lib/.types-compat/ts3.9/lib/vscode/settings.d.ts +24 -0
- package/lib/.types-compat/ts3.9/lib/vscode/vscode.d.ts +14 -0
- package/lib/.types-compat/ts3.9/lib/web/index.d.ts +4 -0
- package/lib/.types-compat/ts3.9/lib/web/next.d.ts +100 -0
- package/lib/.types-compat/ts3.9/lib/web/postcss.d.ts +28 -0
- package/lib/.types-compat/ts3.9/lib/web/react.d.ts +105 -0
- package/lib/.types-compat/ts3.9/lib/web/tailwind.d.ts +21 -0
- package/lib/.types-compat/ts3.9/lib/xmlfile.d.ts +18 -0
- package/lib/.types-compat/ts3.9/lib/yaml.d.ts +25 -0
- package/lib/awscdk/auto-discover.js +5 -5
- package/lib/awscdk/awscdk-app-java.js +1 -1
- package/lib/awscdk/awscdk-app-py.js +1 -1
- package/lib/awscdk/awscdk-app-ts.js +1 -1
- package/lib/awscdk/awscdk-construct.js +2 -2
- package/lib/awscdk/awscdk-deps-java.js +1 -1
- package/lib/awscdk/awscdk-deps-js.js +1 -1
- package/lib/awscdk/awscdk-deps-py.js +1 -1
- package/lib/awscdk/awscdk-deps.js +1 -1
- package/lib/awscdk/cdk-config.js +1 -1
- package/lib/awscdk/cdk-tasks.js +1 -1
- package/lib/awscdk/integration-test.js +1 -1
- package/lib/awscdk/lambda-extension.js +1 -1
- package/lib/awscdk/lambda-function.js +2 -2
- package/lib/build/build-workflow.js +1 -1
- package/lib/cdk/auto-discover-base.js +2 -2
- package/lib/cdk/construct-lib.js +1 -1
- package/lib/cdk/integration-test-base.js +1 -1
- package/lib/cdk/jsii-docgen.js +1 -1
- package/lib/cdk/jsii-project.js +8 -5
- package/lib/cdk8s/auto-discover.js +2 -2
- package/lib/cdk8s/cdk8s-app-py.js +1 -1
- package/lib/cdk8s/cdk8s-app-ts.js +1 -1
- package/lib/cdk8s/cdk8s-construct.js +1 -1
- package/lib/cdk8s/cdk8s-deps-py.js +1 -1
- package/lib/cdk8s/cdk8s-deps.js +1 -1
- package/lib/cdk8s/integration-test.js +1 -1
- package/lib/cdktf/cdktf-construct.js +1 -1
- package/lib/circleci/circleci.js +1 -1
- package/lib/cli/index.js +2 -18
- package/lib/component.js +1 -1
- package/lib/dependencies.js +1 -1
- package/lib/dev-env.js +1 -1
- package/lib/docker-compose/docker-compose-service.js +1 -1
- package/lib/docker-compose/docker-compose.js +1 -1
- package/lib/file.js +1 -1
- package/lib/gitattributes.js +1 -1
- package/lib/github/actions-provider.js +1 -1
- package/lib/github/auto-approve.js +1 -1
- package/lib/github/auto-merge.js +1 -1
- package/lib/github/dependabot.js +1 -1
- package/lib/github/github-credentials.js +1 -1
- package/lib/github/github-project.js +1 -1
- package/lib/github/github.js +1 -1
- package/lib/github/mergify.js +1 -1
- package/lib/github/pr-template.js +1 -1
- package/lib/github/pull-request-lint.js +1 -1
- package/lib/github/stale.js +1 -1
- package/lib/github/task-workflow.js +1 -1
- package/lib/github/workflows.js +1 -1
- package/lib/gitlab/configuration.js +1 -1
- package/lib/gitlab/gitlab-configuration.js +1 -1
- package/lib/gitlab/nested-configuration.js +1 -1
- package/lib/gitpod.js +1 -1
- package/lib/ignore-file.js +1 -1
- package/lib/ini.js +1 -1
- package/lib/java/java-project.js +1 -1
- package/lib/java/junit.js +1 -1
- package/lib/java/maven-compile.js +1 -1
- package/lib/java/maven-packaging.js +1 -1
- package/lib/java/maven-sample.js +1 -1
- package/lib/java/pom.js +1 -1
- package/lib/java/projenrc.js +1 -1
- package/lib/javascript/bundler.js +1 -1
- package/lib/javascript/eslint.js +1 -1
- package/lib/javascript/jest.js +4 -4
- package/lib/javascript/node-package.js +1 -1
- package/lib/javascript/node-project.js +1 -1
- package/lib/javascript/npm-config.js +1 -1
- package/lib/javascript/prettier.js +1 -1
- package/lib/javascript/projenrc.js +1 -1
- package/lib/javascript/typescript-config.js +1 -1
- package/lib/javascript/upgrade-dependencies.js +2 -2
- package/lib/json-patch.js +1 -1
- package/lib/json.js +1 -1
- package/lib/license.js +1 -1
- package/lib/logger.js +1 -1
- package/lib/makefile.js +1 -1
- package/lib/object-file.js +1 -1
- package/lib/project-build.js +1 -1
- package/lib/project.js +1 -1
- package/lib/projects.js +1 -1
- package/lib/projenrc-json.js +2 -2
- package/lib/projenrc.js +1 -1
- package/lib/python/pip.js +1 -1
- package/lib/python/poetry.js +2 -2
- package/lib/python/projenrc.js +1 -1
- package/lib/python/pytest-sample.js +1 -1
- package/lib/python/pytest.js +1 -1
- package/lib/python/python-project.js +1 -1
- package/lib/python/python-sample.js +1 -1
- package/lib/python/requirements-file.js +1 -1
- package/lib/python/setuppy.js +1 -1
- package/lib/python/setuptools.js +1 -1
- package/lib/python/venv.js +1 -1
- package/lib/readme.js +1 -1
- package/lib/release/publisher.d.ts +7 -0
- package/lib/release/publisher.js +9 -2
- package/lib/release/release-trigger.js +1 -1
- package/lib/release/release.js +3 -2
- package/lib/renovatebot.js +1 -1
- package/lib/sample-file.js +2 -2
- package/lib/semver.js +1 -1
- package/lib/source-code.js +1 -1
- package/lib/task-runtime.js +1 -1
- package/lib/task.js +1 -1
- package/lib/tasks.js +1 -1
- package/lib/testing.js +1 -1
- package/lib/textfile.js +1 -1
- package/lib/toml.js +1 -1
- package/lib/typescript/projenrc-ts.js +1 -1
- package/lib/typescript/projenrc.js +1 -1
- package/lib/typescript/typescript-typedoc.js +1 -1
- package/lib/typescript/typescript.js +3 -3
- package/lib/util.d.ts +19 -0
- package/lib/util.js +33 -2
- package/lib/version.js +1 -1
- package/lib/vscode/devcontainer.js +1 -1
- package/lib/vscode/extensions.js +1 -1
- package/lib/vscode/launch-config.js +1 -1
- package/lib/vscode/settings.js +1 -1
- package/lib/vscode/vscode.js +1 -1
- package/lib/web/next.js +3 -3
- package/lib/web/postcss.js +1 -1
- package/lib/web/react.js +4 -4
- package/lib/web/tailwind.js +1 -1
- package/lib/xmlfile.js +1 -1
- package/lib/yaml.js +1 -1
- package/package.json +1 -1
|
@@ -0,0 +1,374 @@
|
|
|
1
|
+
import { Component } from "./component";
|
|
2
|
+
import { Dependencies } from "./dependencies";
|
|
3
|
+
import { FileBase } from "./file";
|
|
4
|
+
import { GitAttributesFile } from "./gitattributes";
|
|
5
|
+
import { IgnoreFile, IgnoreFileOptions } from "./ignore-file";
|
|
6
|
+
import * as inventory from "./inventory";
|
|
7
|
+
import { JsonFile } from "./json";
|
|
8
|
+
import { Logger, LoggerOptions } from "./logger";
|
|
9
|
+
import { ObjectFile } from "./object-file";
|
|
10
|
+
import { InitProjectOptionHints } from "./option-hints";
|
|
11
|
+
import { ProjectBuild as ProjectBuild } from "./project-build";
|
|
12
|
+
import { ProjenrcJsonOptions } from "./projenrc-json";
|
|
13
|
+
import { RenovatebotOptions } from "./renovatebot";
|
|
14
|
+
import { Task, TaskOptions } from "./task";
|
|
15
|
+
import { Tasks } from "./tasks";
|
|
16
|
+
/**
|
|
17
|
+
* Options for `Project`.
|
|
18
|
+
*/
|
|
19
|
+
export interface ProjectOptions {
|
|
20
|
+
/**
|
|
21
|
+
* This is the name of your project.
|
|
22
|
+
*
|
|
23
|
+
* @default $BASEDIR
|
|
24
|
+
* @featured
|
|
25
|
+
*/
|
|
26
|
+
readonly name: string;
|
|
27
|
+
/**
|
|
28
|
+
* The parent project, if this project is part of a bigger project.
|
|
29
|
+
*/
|
|
30
|
+
readonly parent?: Project;
|
|
31
|
+
/**
|
|
32
|
+
* The root directory of the project.
|
|
33
|
+
*
|
|
34
|
+
* Relative to this directory, all files are synthesized.
|
|
35
|
+
*
|
|
36
|
+
* If this project has a parent, this directory is relative to the parent
|
|
37
|
+
* directory and it cannot be the same as the parent or any of it's other
|
|
38
|
+
* sub-projects.
|
|
39
|
+
*
|
|
40
|
+
* @default "."
|
|
41
|
+
*/
|
|
42
|
+
readonly outdir?: string;
|
|
43
|
+
/**
|
|
44
|
+
* Configure logging options such as verbosity.
|
|
45
|
+
* @default {}
|
|
46
|
+
*/
|
|
47
|
+
readonly logging?: LoggerOptions;
|
|
48
|
+
/**
|
|
49
|
+
* Generate (once) .projenrc.json (in JSON). Set to `false` in order to disable
|
|
50
|
+
* .projenrc.json generation.
|
|
51
|
+
*
|
|
52
|
+
* @default false
|
|
53
|
+
*/
|
|
54
|
+
readonly projenrcJson?: boolean;
|
|
55
|
+
/**
|
|
56
|
+
* Options for .projenrc.json
|
|
57
|
+
* @default - default options
|
|
58
|
+
*/
|
|
59
|
+
readonly projenrcJsonOptions?: ProjenrcJsonOptions;
|
|
60
|
+
/**
|
|
61
|
+
* The shell command to use in order to run the projen CLI.
|
|
62
|
+
*
|
|
63
|
+
* Can be used to customize in special environments.
|
|
64
|
+
*
|
|
65
|
+
* @default "npx projen"
|
|
66
|
+
*/
|
|
67
|
+
readonly projenCommand?: string;
|
|
68
|
+
/**
|
|
69
|
+
* Use renovatebot to handle dependency upgrades.
|
|
70
|
+
*
|
|
71
|
+
* @default false
|
|
72
|
+
*/
|
|
73
|
+
readonly renovatebot?: boolean;
|
|
74
|
+
/**
|
|
75
|
+
* Options for renovatebot.
|
|
76
|
+
*
|
|
77
|
+
* @default - default options
|
|
78
|
+
*/
|
|
79
|
+
readonly renovatebotOptions?: RenovatebotOptions;
|
|
80
|
+
/**
|
|
81
|
+
* Whether to commit the managed files by default.
|
|
82
|
+
*
|
|
83
|
+
* @default true
|
|
84
|
+
*/
|
|
85
|
+
readonly commitGenerated?: boolean;
|
|
86
|
+
/**
|
|
87
|
+
* Configuration options for git
|
|
88
|
+
*/
|
|
89
|
+
readonly gitOptions?: GitOptions;
|
|
90
|
+
/**
|
|
91
|
+
* Configuration options for .gitignore file
|
|
92
|
+
*/
|
|
93
|
+
readonly gitIgnoreOptions?: IgnoreFileOptions;
|
|
94
|
+
}
|
|
95
|
+
/**
|
|
96
|
+
* Git configuration options
|
|
97
|
+
*/
|
|
98
|
+
export interface GitOptions {
|
|
99
|
+
/**
|
|
100
|
+
* File patterns to mark as stored in Git LFS
|
|
101
|
+
*
|
|
102
|
+
* @default - No files stored in LFS
|
|
103
|
+
*/
|
|
104
|
+
readonly lfsPatterns?: string[];
|
|
105
|
+
}
|
|
106
|
+
/**
|
|
107
|
+
* Base project
|
|
108
|
+
*/
|
|
109
|
+
export declare class Project {
|
|
110
|
+
/**
|
|
111
|
+
* The name of the default task (the task executed when `projen` is run without arguments). Normally
|
|
112
|
+
* this task should synthesize the project files.
|
|
113
|
+
*/
|
|
114
|
+
static readonly DEFAULT_TASK = "default";
|
|
115
|
+
/**
|
|
116
|
+
* Project name.
|
|
117
|
+
*/
|
|
118
|
+
readonly name: string;
|
|
119
|
+
/**
|
|
120
|
+
* .gitignore
|
|
121
|
+
*/
|
|
122
|
+
readonly gitignore: IgnoreFile;
|
|
123
|
+
/**
|
|
124
|
+
* The .gitattributes file for this repository.
|
|
125
|
+
*/
|
|
126
|
+
readonly gitattributes: GitAttributesFile;
|
|
127
|
+
/**
|
|
128
|
+
* A parent project. If undefined, this is the root project.
|
|
129
|
+
*/
|
|
130
|
+
readonly parent?: Project;
|
|
131
|
+
/**
|
|
132
|
+
* Absolute output directory of this project.
|
|
133
|
+
*/
|
|
134
|
+
readonly outdir: string;
|
|
135
|
+
/**
|
|
136
|
+
* The root project.
|
|
137
|
+
**/
|
|
138
|
+
readonly root: Project;
|
|
139
|
+
/**
|
|
140
|
+
* Project tasks.
|
|
141
|
+
*/
|
|
142
|
+
readonly tasks: Tasks;
|
|
143
|
+
/**
|
|
144
|
+
* Project dependencies.
|
|
145
|
+
*/
|
|
146
|
+
readonly deps: Dependencies;
|
|
147
|
+
/**
|
|
148
|
+
* Logging utilities.
|
|
149
|
+
*/
|
|
150
|
+
readonly logger: Logger;
|
|
151
|
+
/**
|
|
152
|
+
* The options used when this project is bootstrapped via `projen new`. It
|
|
153
|
+
* includes the original set of options passed to the CLI and also the JSII
|
|
154
|
+
* FQN of the project type.
|
|
155
|
+
*/
|
|
156
|
+
readonly initProject?: InitProject;
|
|
157
|
+
/**
|
|
158
|
+
* The command to use in order to run the projen CLI.
|
|
159
|
+
*/
|
|
160
|
+
readonly projenCommand: string;
|
|
161
|
+
/**
|
|
162
|
+
* This is the "default" task, the one that executes "projen". Undefined if
|
|
163
|
+
* the project is being ejected.
|
|
164
|
+
*/
|
|
165
|
+
readonly defaultTask?: Task;
|
|
166
|
+
/**
|
|
167
|
+
* This task ejects the project from projen. This is undefined if the project
|
|
168
|
+
* it self is being ejected.
|
|
169
|
+
*
|
|
170
|
+
* See docs for more information.
|
|
171
|
+
*/
|
|
172
|
+
private readonly ejectTask?;
|
|
173
|
+
/**
|
|
174
|
+
* Manages the build process of the project.
|
|
175
|
+
*/
|
|
176
|
+
readonly projectBuild: ProjectBuild;
|
|
177
|
+
/**
|
|
178
|
+
* Whether to commit the managed files by default.
|
|
179
|
+
*/
|
|
180
|
+
readonly commitGenerated: boolean;
|
|
181
|
+
private readonly _components;
|
|
182
|
+
private readonly subprojects;
|
|
183
|
+
private readonly tips;
|
|
184
|
+
private readonly excludeFromCleanup;
|
|
185
|
+
private readonly _ejected;
|
|
186
|
+
constructor(options: ProjectOptions);
|
|
187
|
+
/**
|
|
188
|
+
* Returns all the components within this project.
|
|
189
|
+
*/
|
|
190
|
+
get components(): Component[];
|
|
191
|
+
/**
|
|
192
|
+
* All files in this project.
|
|
193
|
+
*/
|
|
194
|
+
get files(): FileBase[];
|
|
195
|
+
/**
|
|
196
|
+
* Adds a new task to this project. This will fail if the project already has
|
|
197
|
+
* a task with this name.
|
|
198
|
+
*
|
|
199
|
+
* @param name The task name to add
|
|
200
|
+
* @param props Task properties
|
|
201
|
+
*/
|
|
202
|
+
addTask(name: string, props?: TaskOptions): Task;
|
|
203
|
+
/**
|
|
204
|
+
* Removes a task from a project.
|
|
205
|
+
*
|
|
206
|
+
* @param name The name of the task to remove.
|
|
207
|
+
*
|
|
208
|
+
* @returns The `Task` that was removed, otherwise `undefined`.
|
|
209
|
+
*/
|
|
210
|
+
removeTask(name: string): Task | undefined;
|
|
211
|
+
get buildTask(): Task;
|
|
212
|
+
get compileTask(): Task;
|
|
213
|
+
get testTask(): Task;
|
|
214
|
+
get preCompileTask(): Task;
|
|
215
|
+
get postCompileTask(): Task;
|
|
216
|
+
get packageTask(): Task;
|
|
217
|
+
/**
|
|
218
|
+
* Finds a file at the specified relative path within this project and all
|
|
219
|
+
* its subprojects.
|
|
220
|
+
*
|
|
221
|
+
* @param filePath The file path. If this path is relative, it will be resolved
|
|
222
|
+
* from the root of _this_ project.
|
|
223
|
+
* @returns a `FileBase` or undefined if there is no file in that path
|
|
224
|
+
*/
|
|
225
|
+
tryFindFile(filePath: string): FileBase | undefined;
|
|
226
|
+
/**
|
|
227
|
+
* Finds a json file by name.
|
|
228
|
+
* @param filePath The file path.
|
|
229
|
+
* @deprecated use `tryFindObjectFile`
|
|
230
|
+
*/
|
|
231
|
+
tryFindJsonFile(filePath: string): JsonFile | undefined;
|
|
232
|
+
/**
|
|
233
|
+
* Finds an object file (like JsonFile, YamlFile, etc.) by name.
|
|
234
|
+
* @param filePath The file path.
|
|
235
|
+
*/
|
|
236
|
+
tryFindObjectFile(filePath: string): ObjectFile | undefined;
|
|
237
|
+
/**
|
|
238
|
+
* Finds a file at the specified relative path within this project and removes
|
|
239
|
+
* it.
|
|
240
|
+
*
|
|
241
|
+
* @param filePath The file path. If this path is relative, it will be
|
|
242
|
+
* resolved from the root of _this_ project.
|
|
243
|
+
* @returns a `FileBase` if the file was found and removed, or undefined if
|
|
244
|
+
* the file was not found.
|
|
245
|
+
*/
|
|
246
|
+
tryRemoveFile(filePath: string): FileBase | undefined;
|
|
247
|
+
/**
|
|
248
|
+
* Prints a "tip" message during synthesis.
|
|
249
|
+
* @param message The message
|
|
250
|
+
* @deprecated - use `project.logger.info(message)` to show messages during synthesis
|
|
251
|
+
*/
|
|
252
|
+
addTip(message: string): void;
|
|
253
|
+
/**
|
|
254
|
+
* Exclude the matching files from pre-synth cleanup. Can be used when, for example, some
|
|
255
|
+
* source files include the projen marker and we don't want them to be erased during synth.
|
|
256
|
+
*
|
|
257
|
+
* @param globs The glob patterns to match
|
|
258
|
+
*/
|
|
259
|
+
addExcludeFromCleanup(...globs: string[]): void;
|
|
260
|
+
/**
|
|
261
|
+
* Returns the shell command to execute in order to run a task.
|
|
262
|
+
*
|
|
263
|
+
* By default, this is `npx projen@<version> <task>`
|
|
264
|
+
*
|
|
265
|
+
* @param task The task for which the command is required
|
|
266
|
+
*/
|
|
267
|
+
runTaskCommand(task: Task): string;
|
|
268
|
+
/**
|
|
269
|
+
* Exclude these files from the bundled package. Implemented by project types based on the
|
|
270
|
+
* packaging mechanism. For example, `NodeProject` delegates this to `.npmignore`.
|
|
271
|
+
*
|
|
272
|
+
* @param _pattern The glob pattern to exclude
|
|
273
|
+
*/
|
|
274
|
+
addPackageIgnore(_pattern: string): void;
|
|
275
|
+
/**
|
|
276
|
+
* Adds a .gitignore pattern.
|
|
277
|
+
* @param pattern The glob pattern to ignore.
|
|
278
|
+
*/
|
|
279
|
+
addGitIgnore(pattern: string): void;
|
|
280
|
+
/**
|
|
281
|
+
* Consider a set of files as "generated". This method is implemented by
|
|
282
|
+
* derived classes and used for example, to add git attributes to tell GitHub
|
|
283
|
+
* that certain files are generated.
|
|
284
|
+
*
|
|
285
|
+
* @param _glob the glob pattern to match (could be a file path).
|
|
286
|
+
*/
|
|
287
|
+
annotateGenerated(_glob: string): void;
|
|
288
|
+
/**
|
|
289
|
+
* Synthesize all project files into `outdir`.
|
|
290
|
+
*
|
|
291
|
+
* 1. Call "this.preSynthesize()"
|
|
292
|
+
* 2. Delete all generated files
|
|
293
|
+
* 3. Synthesize all sub-projects
|
|
294
|
+
* 4. Synthesize all components of this project
|
|
295
|
+
* 5. Call "postSynthesize()" for all components of this project
|
|
296
|
+
* 6. Call "this.postSynthesize()"
|
|
297
|
+
*/
|
|
298
|
+
synth(): void;
|
|
299
|
+
/**
|
|
300
|
+
* Whether or not the project is being ejected.
|
|
301
|
+
*/
|
|
302
|
+
get ejected(): boolean;
|
|
303
|
+
/**
|
|
304
|
+
* Called before all components are synthesized.
|
|
305
|
+
*/
|
|
306
|
+
preSynthesize(): void;
|
|
307
|
+
/**
|
|
308
|
+
* Called after all components are synthesized. Order is *not* guaranteed.
|
|
309
|
+
*/
|
|
310
|
+
postSynthesize(): void;
|
|
311
|
+
/**
|
|
312
|
+
* Adds a component to the project.
|
|
313
|
+
* @internal
|
|
314
|
+
*/
|
|
315
|
+
_addComponent(component: Component): void;
|
|
316
|
+
/**
|
|
317
|
+
* Adds a sub-project to this project.
|
|
318
|
+
*
|
|
319
|
+
* This is automatically called when a new project is created with `parent`
|
|
320
|
+
* pointing to this project, so there is no real need to call this manually.
|
|
321
|
+
*
|
|
322
|
+
* @param sub-project The child project to add.
|
|
323
|
+
* @internal
|
|
324
|
+
*/
|
|
325
|
+
_addSubProject(subproject: Project): void;
|
|
326
|
+
/**
|
|
327
|
+
* Resolves the project's output directory.
|
|
328
|
+
*/
|
|
329
|
+
private determineOutdir;
|
|
330
|
+
}
|
|
331
|
+
/**
|
|
332
|
+
* Which type of project this is.
|
|
333
|
+
*
|
|
334
|
+
* @deprecated no longer supported at the base project level
|
|
335
|
+
*/
|
|
336
|
+
export declare enum ProjectType {
|
|
337
|
+
/**
|
|
338
|
+
* This module may be a either a library or an app.
|
|
339
|
+
*/
|
|
340
|
+
UNKNOWN = "unknown",
|
|
341
|
+
/**
|
|
342
|
+
* This is a library, intended to be published to a package manager and
|
|
343
|
+
* consumed by other projects.
|
|
344
|
+
*/
|
|
345
|
+
LIB = "lib",
|
|
346
|
+
/**
|
|
347
|
+
* This is an app (service, tool, website, etc). Its artifacts are intended to
|
|
348
|
+
* be deployed or published for end-user consumption.
|
|
349
|
+
*/
|
|
350
|
+
APP = "app"
|
|
351
|
+
}
|
|
352
|
+
/**
|
|
353
|
+
* Information passed from `projen new` to the project object when the project
|
|
354
|
+
* is first created. It is used to generate projenrc files in various languages.
|
|
355
|
+
*/
|
|
356
|
+
export interface InitProject {
|
|
357
|
+
/**
|
|
358
|
+
* The JSII FQN of the project type.
|
|
359
|
+
*/
|
|
360
|
+
readonly fqn: string;
|
|
361
|
+
/**
|
|
362
|
+
* Initial arguments passed to `projen new`.
|
|
363
|
+
*/
|
|
364
|
+
readonly args: Record<string, any>;
|
|
365
|
+
/**
|
|
366
|
+
* Project metadata.
|
|
367
|
+
*/
|
|
368
|
+
readonly type: inventory.ProjectType;
|
|
369
|
+
/**
|
|
370
|
+
* Include commented out options. Does not apply to projenrc.json files.
|
|
371
|
+
* @default InitProjectOptionHints.FEATURED
|
|
372
|
+
*/
|
|
373
|
+
readonly comments: InitProjectOptionHints;
|
|
374
|
+
}
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
import { InitProjectOptionHints } from "./option-hints";
|
|
2
|
+
export interface CreateProjectOptions {
|
|
3
|
+
/**
|
|
4
|
+
* Directory that the project will be generated in.
|
|
5
|
+
*/
|
|
6
|
+
readonly dir: string;
|
|
7
|
+
/**
|
|
8
|
+
* Fully-qualified name of the project type (usually formatted
|
|
9
|
+
* as `projen.module.ProjectType`).
|
|
10
|
+
* @example `projen.typescript.TypescriptProject`
|
|
11
|
+
*/
|
|
12
|
+
readonly projectFqn: string;
|
|
13
|
+
/**
|
|
14
|
+
* Project options. Only JSON-like values can be passed in (strings,
|
|
15
|
+
* booleans, numbers, enums, arrays, and objects that are not
|
|
16
|
+
* derived from classes).
|
|
17
|
+
*
|
|
18
|
+
* Consult the API reference of the project type you are generating for
|
|
19
|
+
* information about what fields and types are available.
|
|
20
|
+
*/
|
|
21
|
+
readonly projectOptions: Record<string, any>;
|
|
22
|
+
/**
|
|
23
|
+
* Should we render commented-out default options in the projenrc file?
|
|
24
|
+
* Does not apply to projenrc.json files.
|
|
25
|
+
*
|
|
26
|
+
* @default InitProjectOptionHints.FEATURED
|
|
27
|
+
*/
|
|
28
|
+
readonly optionHints?: InitProjectOptionHints;
|
|
29
|
+
/**
|
|
30
|
+
* Should we call `project.synth()` or instantiate the project (could still
|
|
31
|
+
* have side-effects) and render the .projenrc file.
|
|
32
|
+
*
|
|
33
|
+
* @default true
|
|
34
|
+
*/
|
|
35
|
+
readonly synth?: boolean;
|
|
36
|
+
/**
|
|
37
|
+
* Should we execute post synthesis hooks? (usually package manager install).
|
|
38
|
+
*
|
|
39
|
+
* @default true
|
|
40
|
+
*/
|
|
41
|
+
readonly post?: boolean;
|
|
42
|
+
}
|
|
43
|
+
/**
|
|
44
|
+
* Programmatic API for projen.
|
|
45
|
+
*/
|
|
46
|
+
export declare class Projects {
|
|
47
|
+
/**
|
|
48
|
+
* Creates a new project with defaults.
|
|
49
|
+
*
|
|
50
|
+
* This function creates the project type in-process (with in VM) and calls
|
|
51
|
+
* `.synth()` on it (if `options.synth` is not `false`).
|
|
52
|
+
*
|
|
53
|
+
* At the moment, it also generates a `.projenrc.js` file with the same code
|
|
54
|
+
* that was just executed. In the future, this will also be done by the project
|
|
55
|
+
* type, so we can easily support multiple languages of projenrc.
|
|
56
|
+
*
|
|
57
|
+
* An environment variable (PROJEN_CREATE_PROJECT=true) is set within the VM
|
|
58
|
+
* so that custom project types can detect whether the current synthesis is the
|
|
59
|
+
* result of a new project creation (and take additional steps accordingly)
|
|
60
|
+
*/
|
|
61
|
+
static createProject(options: CreateProjectOptions): void;
|
|
62
|
+
private constructor();
|
|
63
|
+
}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { Project } from "./project";
|
|
2
|
+
import { ProjenrcFile } from "./projenrc";
|
|
3
|
+
export interface ProjenrcJsonOptions {
|
|
4
|
+
/**
|
|
5
|
+
* The name of the projenrc file.
|
|
6
|
+
* @default ".projenrc.json"
|
|
7
|
+
*/
|
|
8
|
+
readonly filename?: string;
|
|
9
|
+
}
|
|
10
|
+
/**
|
|
11
|
+
* Sets up a project to use JSON for projenrc.
|
|
12
|
+
*/
|
|
13
|
+
export declare class ProjenrcJson extends ProjenrcFile {
|
|
14
|
+
readonly filePath: string;
|
|
15
|
+
constructor(project: Project, options?: ProjenrcJsonOptions);
|
|
16
|
+
private generateProjenrc;
|
|
17
|
+
}
|
|
18
|
+
/**
|
|
19
|
+
* @deprecated use `ProjenrcJsonOptions`
|
|
20
|
+
*/
|
|
21
|
+
export interface ProjenrcOptions extends ProjenrcJsonOptions {
|
|
22
|
+
}
|
|
23
|
+
/**
|
|
24
|
+
* @deprecated use `ProjenrcJson`
|
|
25
|
+
*/
|
|
26
|
+
export declare class Projenrc extends ProjenrcJson {
|
|
27
|
+
}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { Component } from "./component";
|
|
2
|
+
import { Project } from "./project";
|
|
3
|
+
/**
|
|
4
|
+
* A component representing the projen runtime configuration
|
|
5
|
+
*/
|
|
6
|
+
export declare abstract class ProjenrcFile extends Component {
|
|
7
|
+
/**
|
|
8
|
+
* Returns the `Projenrc` instance associated with a project or `undefined` if
|
|
9
|
+
* there is no Projenrc.
|
|
10
|
+
* @param project The project
|
|
11
|
+
* @returns A Projenrc
|
|
12
|
+
*/
|
|
13
|
+
static of(project: Project): ProjenrcFile | undefined;
|
|
14
|
+
/**
|
|
15
|
+
* The path of the projenrc file.
|
|
16
|
+
*/
|
|
17
|
+
abstract readonly filePath: string;
|
|
18
|
+
}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
export * from "./pip";
|
|
2
|
+
export * from "./poetry";
|
|
3
|
+
export * from "./projenrc";
|
|
4
|
+
export * from "./pytest";
|
|
5
|
+
export * from "./pytest-sample";
|
|
6
|
+
export * from "./python-env";
|
|
7
|
+
export * from "./python-deps";
|
|
8
|
+
export * from "./python-packaging";
|
|
9
|
+
export * from "./python-project";
|
|
10
|
+
export * from "./python-sample";
|
|
11
|
+
export * from "./requirements-file";
|
|
12
|
+
export * from "./setuppy";
|
|
13
|
+
export * from "./setuptools";
|
|
14
|
+
export * from "./venv";
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import { IPythonDeps } from "./python-deps";
|
|
2
|
+
import { Component } from "../component";
|
|
3
|
+
import { Project } from "../project";
|
|
4
|
+
import { Task } from "../task";
|
|
5
|
+
/**
|
|
6
|
+
* Options for pip
|
|
7
|
+
*/
|
|
8
|
+
export interface PipOptions {
|
|
9
|
+
}
|
|
10
|
+
/**
|
|
11
|
+
* Manages dependencies using a requirements.txt file and the pip CLI tool.
|
|
12
|
+
*/
|
|
13
|
+
export declare class Pip extends Component implements IPythonDeps {
|
|
14
|
+
readonly installTask: Task;
|
|
15
|
+
constructor(project: Project, _options?: PipOptions);
|
|
16
|
+
/**
|
|
17
|
+
* Adds a runtime dependency.
|
|
18
|
+
*
|
|
19
|
+
* @param spec Format `<module>@<semver>`
|
|
20
|
+
*/
|
|
21
|
+
addDependency(spec: string): void;
|
|
22
|
+
/**
|
|
23
|
+
* Adds a dev dependency.
|
|
24
|
+
*
|
|
25
|
+
* @param spec Format `<module>@<semver>`
|
|
26
|
+
*/
|
|
27
|
+
addDevDependency(spec: string): void;
|
|
28
|
+
/**
|
|
29
|
+
* Installs dependencies (called during post-synthesis).
|
|
30
|
+
*/
|
|
31
|
+
installDependencies(): void;
|
|
32
|
+
}
|
|
@@ -0,0 +1,177 @@
|
|
|
1
|
+
import { IPythonDeps } from "./python-deps";
|
|
2
|
+
import { IPythonEnv } from "./python-env";
|
|
3
|
+
import { IPythonPackaging, PythonPackagingOptions } from "./python-packaging";
|
|
4
|
+
import { Component } from "../component";
|
|
5
|
+
import { Project } from "../project";
|
|
6
|
+
import { Task } from "../task";
|
|
7
|
+
import { TomlFile } from "../toml";
|
|
8
|
+
/**
|
|
9
|
+
* Manage project dependencies, virtual environments, and packaging through the
|
|
10
|
+
* poetry CLI tool.
|
|
11
|
+
*/
|
|
12
|
+
export declare class Poetry extends Component implements IPythonDeps, IPythonEnv, IPythonPackaging {
|
|
13
|
+
readonly installTask: Task;
|
|
14
|
+
readonly publishTask: Task;
|
|
15
|
+
/**
|
|
16
|
+
* A task that uploads the package to the Test PyPI repository.
|
|
17
|
+
*/
|
|
18
|
+
readonly publishTestTask: Task;
|
|
19
|
+
constructor(project: Project, options: PythonPackagingOptions);
|
|
20
|
+
private synthDependencies;
|
|
21
|
+
private synthDevDependencies;
|
|
22
|
+
/**
|
|
23
|
+
* Adds a runtime dependency.
|
|
24
|
+
*
|
|
25
|
+
* @param spec Format `<module>@<semver>`
|
|
26
|
+
*/
|
|
27
|
+
addDependency(spec: string): void;
|
|
28
|
+
/**
|
|
29
|
+
* Adds a dev dependency.
|
|
30
|
+
*
|
|
31
|
+
* @param spec Format `<module>@<semver>`
|
|
32
|
+
*/
|
|
33
|
+
addDevDependency(spec: string): void;
|
|
34
|
+
/**
|
|
35
|
+
* Initializes the virtual environment if it doesn't exist (called during post-synthesis).
|
|
36
|
+
*/
|
|
37
|
+
setupEnvironment(): void;
|
|
38
|
+
/**
|
|
39
|
+
* Installs dependencies (called during post-synthesis).
|
|
40
|
+
*/
|
|
41
|
+
installDependencies(): void;
|
|
42
|
+
}
|
|
43
|
+
/**
|
|
44
|
+
* Poetry-specific options.
|
|
45
|
+
* @see https://python-poetry.org/docs/pyproject/
|
|
46
|
+
*/
|
|
47
|
+
export interface PoetryPyprojectOptionsWithoutDeps {
|
|
48
|
+
/**
|
|
49
|
+
* Name of the package (required).
|
|
50
|
+
*/
|
|
51
|
+
readonly name?: string;
|
|
52
|
+
/**
|
|
53
|
+
* Version of the package (required).
|
|
54
|
+
*/
|
|
55
|
+
readonly version?: string;
|
|
56
|
+
/**
|
|
57
|
+
* A short description of the package (required).
|
|
58
|
+
*/
|
|
59
|
+
readonly description?: string;
|
|
60
|
+
/**
|
|
61
|
+
* License of this package as an SPDX identifier.
|
|
62
|
+
*
|
|
63
|
+
* If the project is proprietary and does not use a specific license, you
|
|
64
|
+
* can set this value as "Proprietary".
|
|
65
|
+
*/
|
|
66
|
+
readonly license?: string;
|
|
67
|
+
/**
|
|
68
|
+
* The authors of the package. Must be in the form "name <email>"
|
|
69
|
+
*/
|
|
70
|
+
readonly authors?: string[];
|
|
71
|
+
/**
|
|
72
|
+
* the maintainers of the package. Must be in the form "name <email>"
|
|
73
|
+
*/
|
|
74
|
+
readonly maintainers?: string[];
|
|
75
|
+
/**
|
|
76
|
+
* The name of the readme file of the package.
|
|
77
|
+
*/
|
|
78
|
+
readonly readme?: string;
|
|
79
|
+
/**
|
|
80
|
+
* A URL to the website of the project.
|
|
81
|
+
*/
|
|
82
|
+
readonly homepage?: string;
|
|
83
|
+
/**
|
|
84
|
+
* A URL to the repository of the project.
|
|
85
|
+
*/
|
|
86
|
+
readonly repository?: string;
|
|
87
|
+
/**
|
|
88
|
+
* A URL to the documentation of the project.
|
|
89
|
+
*/
|
|
90
|
+
readonly documentation?: string;
|
|
91
|
+
/**
|
|
92
|
+
* A list of keywords (max: 5) that the package is related to.
|
|
93
|
+
*/
|
|
94
|
+
readonly keywords?: string[];
|
|
95
|
+
/**
|
|
96
|
+
* A list of PyPI trove classifiers that describe the project.
|
|
97
|
+
*
|
|
98
|
+
* @see https://pypi.org/classifiers/
|
|
99
|
+
*/
|
|
100
|
+
readonly classifiers?: string[];
|
|
101
|
+
/**
|
|
102
|
+
* A list of packages and modules to include in the final distribution.
|
|
103
|
+
*/
|
|
104
|
+
readonly packages?: any[];
|
|
105
|
+
/**
|
|
106
|
+
* A list of patterns that will be included in the final package.
|
|
107
|
+
*/
|
|
108
|
+
readonly include?: string[];
|
|
109
|
+
/**
|
|
110
|
+
* A list of patterns that will be excluded in the final package.
|
|
111
|
+
*
|
|
112
|
+
* If a VCS is being used for a package, the exclude field will be seeded with
|
|
113
|
+
* the VCS’ ignore settings (.gitignore for git for example).
|
|
114
|
+
*/
|
|
115
|
+
readonly exclude?: string[];
|
|
116
|
+
/**
|
|
117
|
+
* The scripts or executables that will be installed when installing the package.
|
|
118
|
+
*/
|
|
119
|
+
readonly scripts?: {
|
|
120
|
+
[key: string]: any;
|
|
121
|
+
};
|
|
122
|
+
/**
|
|
123
|
+
* Source registries from which packages are retrieved.
|
|
124
|
+
*/
|
|
125
|
+
readonly source?: any[];
|
|
126
|
+
/**
|
|
127
|
+
* Package extras
|
|
128
|
+
*/
|
|
129
|
+
readonly extras?: {
|
|
130
|
+
[key: string]: string[];
|
|
131
|
+
};
|
|
132
|
+
/**
|
|
133
|
+
* Plugins. Must be specified as a table.
|
|
134
|
+
* @see https://toml.io/en/v1.0.0#table
|
|
135
|
+
*/
|
|
136
|
+
readonly plugins?: any;
|
|
137
|
+
/**
|
|
138
|
+
* Project custom URLs, in addition to homepage, repository and documentation.
|
|
139
|
+
* E.g. "Bug Tracker"
|
|
140
|
+
*/
|
|
141
|
+
readonly urls?: {
|
|
142
|
+
[key: string]: string;
|
|
143
|
+
};
|
|
144
|
+
}
|
|
145
|
+
/**
|
|
146
|
+
* Poetry-specific options.
|
|
147
|
+
* @see https://python-poetry.org/docs/pyproject/
|
|
148
|
+
*/
|
|
149
|
+
export interface PoetryPyprojectOptions extends PoetryPyprojectOptionsWithoutDeps {
|
|
150
|
+
/**
|
|
151
|
+
* A list of dependencies for the project.
|
|
152
|
+
*
|
|
153
|
+
* The python version for which your package is compatible is also required.
|
|
154
|
+
*
|
|
155
|
+
* @example { requests: "^2.13.0" }
|
|
156
|
+
*/
|
|
157
|
+
readonly dependencies?: {
|
|
158
|
+
[key: string]: any;
|
|
159
|
+
};
|
|
160
|
+
/**
|
|
161
|
+
* A list of development dependencies for the project.
|
|
162
|
+
*
|
|
163
|
+
* @example { requests: "^2.13.0" }
|
|
164
|
+
*/
|
|
165
|
+
readonly devDependencies?: {
|
|
166
|
+
[key: string]: any;
|
|
167
|
+
};
|
|
168
|
+
}
|
|
169
|
+
/**
|
|
170
|
+
* Represents configuration of a pyproject.toml file for a Poetry project.
|
|
171
|
+
*
|
|
172
|
+
* @see https://python-poetry.org/docs/pyproject/
|
|
173
|
+
*/
|
|
174
|
+
export declare class PoetryPyproject extends Component {
|
|
175
|
+
readonly file: TomlFile;
|
|
176
|
+
constructor(project: Project, options: PoetryPyprojectOptions);
|
|
177
|
+
}
|