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,605 @@
|
|
|
1
|
+
import { Component } from "../component";
|
|
2
|
+
import { Project } from "../project";
|
|
3
|
+
import { Task } from "../task";
|
|
4
|
+
export interface NodePackageOptions {
|
|
5
|
+
/**
|
|
6
|
+
* The "name" in package.json
|
|
7
|
+
* @default - defaults to project name
|
|
8
|
+
* @featured
|
|
9
|
+
*/
|
|
10
|
+
readonly packageName?: string;
|
|
11
|
+
/**
|
|
12
|
+
* The description is just a string that helps people understand the purpose of the package.
|
|
13
|
+
* It can be used when searching for packages in a package manager as well.
|
|
14
|
+
* See https://classic.yarnpkg.com/en/docs/package-json/#toc-description
|
|
15
|
+
* @featured
|
|
16
|
+
*/
|
|
17
|
+
readonly description?: string;
|
|
18
|
+
/**
|
|
19
|
+
* Runtime dependencies of this module.
|
|
20
|
+
*
|
|
21
|
+
* The recommendation is to only specify the module name here (e.g.
|
|
22
|
+
* `express`). This will behave similar to `yarn add` or `npm install` in the
|
|
23
|
+
* sense that it will add the module as a dependency to your `package.json`
|
|
24
|
+
* file with the latest version (`^`). You can specify semver requirements in
|
|
25
|
+
* the same syntax passed to `npm i` or `yarn add` (e.g. `express@^2`) and
|
|
26
|
+
* this will be what you `package.json` will eventually include.
|
|
27
|
+
*
|
|
28
|
+
* @example [ 'express', 'lodash', 'foo@^2' ]
|
|
29
|
+
* @default []
|
|
30
|
+
* @featured
|
|
31
|
+
*/
|
|
32
|
+
readonly deps?: string[];
|
|
33
|
+
/**
|
|
34
|
+
* Build dependencies for this module. These dependencies will only be
|
|
35
|
+
* available in your build environment but will not be fetched when this
|
|
36
|
+
* module is consumed.
|
|
37
|
+
*
|
|
38
|
+
* The recommendation is to only specify the module name here (e.g.
|
|
39
|
+
* `express`). This will behave similar to `yarn add` or `npm install` in the
|
|
40
|
+
* sense that it will add the module as a dependency to your `package.json`
|
|
41
|
+
* file with the latest version (`^`). You can specify semver requirements in
|
|
42
|
+
* the same syntax passed to `npm i` or `yarn add` (e.g. `express@^2`) and
|
|
43
|
+
* this will be what you `package.json` will eventually include.
|
|
44
|
+
*
|
|
45
|
+
* @example [ 'typescript', '@types/express' ]
|
|
46
|
+
* @default []
|
|
47
|
+
* @featured
|
|
48
|
+
*/
|
|
49
|
+
readonly devDeps?: string[];
|
|
50
|
+
/**
|
|
51
|
+
* Peer dependencies for this module. Dependencies listed here are required to
|
|
52
|
+
* be installed (and satisfied) by the _consumer_ of this library. Using peer
|
|
53
|
+
* dependencies allows you to ensure that only a single module of a certain
|
|
54
|
+
* library exists in the `node_modules` tree of your consumers.
|
|
55
|
+
*
|
|
56
|
+
* Note that prior to npm@7, peer dependencies are _not_ automatically
|
|
57
|
+
* installed, which means that adding peer dependencies to a library will be a
|
|
58
|
+
* breaking change for your customers.
|
|
59
|
+
*
|
|
60
|
+
* Unless `peerDependencyOptions.pinnedDevDependency` is disabled (it is
|
|
61
|
+
* enabled by default), projen will automatically add a dev dependency with a
|
|
62
|
+
* pinned version for each peer dependency. This will ensure that you build &
|
|
63
|
+
* test your module against the lowest peer version required.
|
|
64
|
+
*
|
|
65
|
+
* @default []
|
|
66
|
+
*/
|
|
67
|
+
readonly peerDeps?: string[];
|
|
68
|
+
/**
|
|
69
|
+
* List of dependencies to bundle into this module. These modules will be
|
|
70
|
+
* added both to the `dependencies` section and `bundledDependencies` section of
|
|
71
|
+
* your `package.json`.
|
|
72
|
+
*
|
|
73
|
+
* The recommendation is to only specify the module name here (e.g.
|
|
74
|
+
* `express`). This will behave similar to `yarn add` or `npm install` in the
|
|
75
|
+
* sense that it will add the module as a dependency to your `package.json`
|
|
76
|
+
* file with the latest version (`^`). You can specify semver requirements in
|
|
77
|
+
* the same syntax passed to `npm i` or `yarn add` (e.g. `express@^2`) and
|
|
78
|
+
* this will be what you `package.json` will eventually include.
|
|
79
|
+
*/
|
|
80
|
+
readonly bundledDeps?: string[];
|
|
81
|
+
/**
|
|
82
|
+
* Options for `peerDeps`.
|
|
83
|
+
*/
|
|
84
|
+
readonly peerDependencyOptions?: PeerDependencyOptions;
|
|
85
|
+
/**
|
|
86
|
+
* Allow the project to include `peerDependencies` and `bundledDependencies`.
|
|
87
|
+
* This is normally only allowed for libraries. For apps, there's no meaning
|
|
88
|
+
* for specifying these.
|
|
89
|
+
*
|
|
90
|
+
* @default true
|
|
91
|
+
*/
|
|
92
|
+
readonly allowLibraryDependencies?: boolean;
|
|
93
|
+
/**
|
|
94
|
+
* Keywords to include in `package.json`.
|
|
95
|
+
*/
|
|
96
|
+
readonly keywords?: string[];
|
|
97
|
+
/**
|
|
98
|
+
* Module entrypoint (`main` in `package.json`)
|
|
99
|
+
*
|
|
100
|
+
* Set to an empty string to not include `main` in your package.json
|
|
101
|
+
*
|
|
102
|
+
* @default "lib/index.js"
|
|
103
|
+
*/
|
|
104
|
+
readonly entrypoint?: string;
|
|
105
|
+
/**
|
|
106
|
+
* Binary programs vended with your module.
|
|
107
|
+
*
|
|
108
|
+
* You can use this option to add/customize how binaries are represented in
|
|
109
|
+
* your `package.json`, but unless `autoDetectBin` is `false`, every
|
|
110
|
+
* executable file under `bin` will automatically be added to this section.
|
|
111
|
+
*/
|
|
112
|
+
readonly bin?: Record<string, string>;
|
|
113
|
+
/**
|
|
114
|
+
* Automatically add all executables under the `bin` directory to your
|
|
115
|
+
* `package.json` file under the `bin` section.
|
|
116
|
+
*
|
|
117
|
+
* @default true
|
|
118
|
+
*/
|
|
119
|
+
readonly autoDetectBin?: boolean;
|
|
120
|
+
/**
|
|
121
|
+
* npm scripts to include. If a script has the same name as a standard script,
|
|
122
|
+
* the standard script will be overwritten.
|
|
123
|
+
*
|
|
124
|
+
* @default {}
|
|
125
|
+
*/
|
|
126
|
+
readonly scripts?: {
|
|
127
|
+
[name: string]: string;
|
|
128
|
+
};
|
|
129
|
+
/**
|
|
130
|
+
* The Node Package Manager used to execute scripts
|
|
131
|
+
*
|
|
132
|
+
* @default NodePackageManager.YARN
|
|
133
|
+
*/
|
|
134
|
+
readonly packageManager?: NodePackageManager;
|
|
135
|
+
/**
|
|
136
|
+
* The repository is the location where the actual code for your package lives.
|
|
137
|
+
* See https://classic.yarnpkg.com/en/docs/package-json/#toc-repository
|
|
138
|
+
*/
|
|
139
|
+
readonly repository?: string;
|
|
140
|
+
/**
|
|
141
|
+
* If the package.json for your package is not in the root directory (for example if it is part of a monorepo),
|
|
142
|
+
* you can specify the directory in which it lives.
|
|
143
|
+
*/
|
|
144
|
+
readonly repositoryDirectory?: string;
|
|
145
|
+
/**
|
|
146
|
+
* Author's name
|
|
147
|
+
*/
|
|
148
|
+
readonly authorName?: string;
|
|
149
|
+
/**
|
|
150
|
+
* Author's e-mail
|
|
151
|
+
*/
|
|
152
|
+
readonly authorEmail?: string;
|
|
153
|
+
/**
|
|
154
|
+
* Author's URL / Website
|
|
155
|
+
*/
|
|
156
|
+
readonly authorUrl?: string;
|
|
157
|
+
/**
|
|
158
|
+
* Is the author an organization
|
|
159
|
+
*/
|
|
160
|
+
readonly authorOrganization?: boolean;
|
|
161
|
+
/**
|
|
162
|
+
* Package's Homepage / Website
|
|
163
|
+
*/
|
|
164
|
+
readonly homepage?: string;
|
|
165
|
+
/**
|
|
166
|
+
* Package's Stability
|
|
167
|
+
*/
|
|
168
|
+
readonly stability?: string;
|
|
169
|
+
/**
|
|
170
|
+
* Minimum Node.js version to require via package.json `engines` (inclusive).
|
|
171
|
+
*
|
|
172
|
+
* @default - no "engines" specified
|
|
173
|
+
*/
|
|
174
|
+
readonly minNodeVersion?: string;
|
|
175
|
+
/**
|
|
176
|
+
* Minimum node.js version to require via `engines` (inclusive).
|
|
177
|
+
*
|
|
178
|
+
* @default - no max
|
|
179
|
+
*/
|
|
180
|
+
readonly maxNodeVersion?: string;
|
|
181
|
+
/**
|
|
182
|
+
* The version of PNPM to use if using PNPM as a package manager.
|
|
183
|
+
*
|
|
184
|
+
* @default "7"
|
|
185
|
+
*/
|
|
186
|
+
readonly pnpmVersion?: string;
|
|
187
|
+
/**
|
|
188
|
+
* License's SPDX identifier.
|
|
189
|
+
* See https://github.com/projen/projen/tree/main/license-text for a list of supported licenses.
|
|
190
|
+
* Use the `licensed` option if you want to no license to be specified.
|
|
191
|
+
*
|
|
192
|
+
* @default "Apache-2.0"
|
|
193
|
+
*/
|
|
194
|
+
readonly license?: string;
|
|
195
|
+
/**
|
|
196
|
+
* Indicates if a license should be added.
|
|
197
|
+
*
|
|
198
|
+
* @default true
|
|
199
|
+
*/
|
|
200
|
+
readonly licensed?: boolean;
|
|
201
|
+
/**
|
|
202
|
+
* The base URL of the npm package registry.
|
|
203
|
+
*
|
|
204
|
+
* Must be a URL (e.g. start with "https://" or "http://")
|
|
205
|
+
*
|
|
206
|
+
* @default "https://registry.npmjs.org"
|
|
207
|
+
*/
|
|
208
|
+
readonly npmRegistryUrl?: string;
|
|
209
|
+
/**
|
|
210
|
+
* The host name of the npm registry to publish to. Cannot be set together with `npmRegistryUrl`.
|
|
211
|
+
*
|
|
212
|
+
* @deprecated use `npmRegistryUrl` instead
|
|
213
|
+
*/
|
|
214
|
+
readonly npmRegistry?: string;
|
|
215
|
+
/**
|
|
216
|
+
* The url to your project's issue tracker.
|
|
217
|
+
*/
|
|
218
|
+
readonly bugsUrl?: string;
|
|
219
|
+
/**
|
|
220
|
+
* The email address to which issues should be reported.
|
|
221
|
+
*/
|
|
222
|
+
readonly bugsEmail?: string;
|
|
223
|
+
/**
|
|
224
|
+
* Access level of the npm package.
|
|
225
|
+
*
|
|
226
|
+
* @default - for scoped packages (e.g. `foo@bar`), the default is
|
|
227
|
+
* `NpmAccess.RESTRICTED`, for non-scoped packages, the default is
|
|
228
|
+
* `NpmAccess.PUBLIC`.
|
|
229
|
+
*/
|
|
230
|
+
readonly npmAccess?: NpmAccess;
|
|
231
|
+
/**
|
|
232
|
+
* GitHub secret which contains the NPM token to use when publishing packages.
|
|
233
|
+
*
|
|
234
|
+
* @default "NPM_TOKEN"
|
|
235
|
+
*/
|
|
236
|
+
readonly npmTokenSecret?: string;
|
|
237
|
+
/**
|
|
238
|
+
* Options for npm packages using AWS CodeArtifact.
|
|
239
|
+
* This is required if publishing packages to, or installing scoped packages from AWS CodeArtifact
|
|
240
|
+
*
|
|
241
|
+
* @default - undefined
|
|
242
|
+
*/
|
|
243
|
+
readonly codeArtifactOptions?: CodeArtifactOptions;
|
|
244
|
+
/**
|
|
245
|
+
* Options for privately hosted scoped packages
|
|
246
|
+
*
|
|
247
|
+
* @default - fetch all scoped packages from the public npm registry
|
|
248
|
+
*/
|
|
249
|
+
readonly scopedPackagesOptions?: ScopedPackagesOptions[];
|
|
250
|
+
}
|
|
251
|
+
/**
|
|
252
|
+
* Options for authorizing requests to a AWS CodeArtifact npm repository.
|
|
253
|
+
*/
|
|
254
|
+
export declare enum CodeArtifactAuthProvider {
|
|
255
|
+
/**
|
|
256
|
+
* Fixed credentials provided via Github secrets.
|
|
257
|
+
*/
|
|
258
|
+
ACCESS_AND_SECRET_KEY_PAIR = "ACCESS_AND_SECRET_KEY_PAIR",
|
|
259
|
+
/**
|
|
260
|
+
* Ephemeral credentials provided via Github's OIDC integration with an IAM role.
|
|
261
|
+
* See:
|
|
262
|
+
* https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_providers_create_oidc.html
|
|
263
|
+
* https://docs.github.com/en/actions/deployment/security-hardening-your-deployments/configuring-openid-connect-in-amazon-web-services
|
|
264
|
+
*/
|
|
265
|
+
GITHUB_OIDC = "GITHUB_OIDC"
|
|
266
|
+
}
|
|
267
|
+
/**
|
|
268
|
+
* Options for publishing npm packages to AWS CodeArtifact.
|
|
269
|
+
*/
|
|
270
|
+
export interface CodeArtifactOptions {
|
|
271
|
+
/**
|
|
272
|
+
* Provider to use for authorizing requests to AWS CodeArtifact.
|
|
273
|
+
*
|
|
274
|
+
* @default CodeArtifactAuthProvider.ACCESS_AND_SECRET_KEY_PAIR
|
|
275
|
+
*/
|
|
276
|
+
readonly authProvider?: CodeArtifactAuthProvider;
|
|
277
|
+
/**
|
|
278
|
+
* GitHub secret which contains the AWS access key ID to use when publishing packages to AWS CodeArtifact.
|
|
279
|
+
* This property must be specified only when publishing to AWS CodeArtifact (`npmRegistryUrl` contains AWS CodeArtifact URL).
|
|
280
|
+
*
|
|
281
|
+
* @default - When the `authProvider` value is set to
|
|
282
|
+
* `CodeArtifactAuthProvider.ACCESS_AND_SECRET_KEY_PAIR`, the default is
|
|
283
|
+
* "AWS_ACCESS_KEY_ID". For `CodeArtifactAuthProvider.GITHUB_OIDC`, this
|
|
284
|
+
* value must be left undefined.
|
|
285
|
+
*/
|
|
286
|
+
readonly accessKeyIdSecret?: string;
|
|
287
|
+
/**
|
|
288
|
+
* GitHub secret which contains the AWS secret access key to use when publishing packages to AWS CodeArtifact.
|
|
289
|
+
* This property must be specified only when publishing to AWS CodeArtifact (`npmRegistryUrl` contains AWS CodeArtifact URL).
|
|
290
|
+
*
|
|
291
|
+
* @default - When the `authProvider` value is set to
|
|
292
|
+
* `CodeArtifactAuthProvider.ACCESS_AND_SECRET_KEY_PAIR`, the default is
|
|
293
|
+
* "AWS_SECRET_ACCESS_KEY". For `CodeArtifactAuthProvider.GITHUB_OIDC`, this
|
|
294
|
+
* value must be left undefined.
|
|
295
|
+
*/
|
|
296
|
+
readonly secretAccessKeySecret?: string;
|
|
297
|
+
/**
|
|
298
|
+
* ARN of AWS role to be assumed prior to get authorization token from AWS CodeArtifact
|
|
299
|
+
* This property must be specified only when publishing to AWS CodeArtifact (`registry` contains AWS CodeArtifact URL).
|
|
300
|
+
* When using the `CodeArtifactAuthProvider.GITHUB_OIDC` auth provider, this value must be defined.
|
|
301
|
+
*
|
|
302
|
+
* @default undefined
|
|
303
|
+
*/
|
|
304
|
+
readonly roleToAssume?: string;
|
|
305
|
+
}
|
|
306
|
+
/**
|
|
307
|
+
* Options for scoped packages
|
|
308
|
+
*/
|
|
309
|
+
export interface ScopedPackagesOptions {
|
|
310
|
+
/**
|
|
311
|
+
* Scope of the packages
|
|
312
|
+
*
|
|
313
|
+
* @example "@angular"
|
|
314
|
+
*/
|
|
315
|
+
readonly scope: string;
|
|
316
|
+
/**
|
|
317
|
+
* URL of the registry for scoped packages
|
|
318
|
+
*/
|
|
319
|
+
readonly registryUrl: string;
|
|
320
|
+
}
|
|
321
|
+
/**
|
|
322
|
+
* Represents the npm `package.json` file.
|
|
323
|
+
*/
|
|
324
|
+
export declare class NodePackage extends Component {
|
|
325
|
+
/**
|
|
326
|
+
* The name of the npm package.
|
|
327
|
+
*/
|
|
328
|
+
readonly packageName: string;
|
|
329
|
+
/**
|
|
330
|
+
* The module's entrypoint (e.g. `lib/index.js`).
|
|
331
|
+
*/
|
|
332
|
+
readonly entrypoint: string;
|
|
333
|
+
/**
|
|
334
|
+
* Allow project to take library dependencies.
|
|
335
|
+
*/
|
|
336
|
+
readonly allowLibraryDependencies: boolean;
|
|
337
|
+
/**
|
|
338
|
+
* The package manager to use.
|
|
339
|
+
*/
|
|
340
|
+
readonly packageManager: NodePackageManager;
|
|
341
|
+
/**
|
|
342
|
+
* @deprecated use `addField(x, y)`
|
|
343
|
+
*/
|
|
344
|
+
readonly manifest: any;
|
|
345
|
+
/**
|
|
346
|
+
* Minimum node.js version required by this package.
|
|
347
|
+
* @default - no minimum
|
|
348
|
+
*/
|
|
349
|
+
readonly minNodeVersion?: string;
|
|
350
|
+
/**
|
|
351
|
+
* Maximum node version required by this package.
|
|
352
|
+
* @default - no maximum.
|
|
353
|
+
*/
|
|
354
|
+
readonly maxNodeVersion?: string;
|
|
355
|
+
/**
|
|
356
|
+
* The version of PNPM to use if using PNPM as a package manager.
|
|
357
|
+
*
|
|
358
|
+
* @default "7"
|
|
359
|
+
*/
|
|
360
|
+
readonly pnpmVersion?: string;
|
|
361
|
+
/**
|
|
362
|
+
* The SPDX license of this module. `undefined` if this package is not licensed.
|
|
363
|
+
*/
|
|
364
|
+
readonly license?: string;
|
|
365
|
+
/**
|
|
366
|
+
* npm registry (e.g. `https://registry.npmjs.org`). Use `npmRegistryHost` to get just the host name.
|
|
367
|
+
*/
|
|
368
|
+
readonly npmRegistryUrl: string;
|
|
369
|
+
/**
|
|
370
|
+
* The npm registry host (e.g. `registry.npmjs.org`).
|
|
371
|
+
*/
|
|
372
|
+
readonly npmRegistry: string;
|
|
373
|
+
/**
|
|
374
|
+
* GitHub secret which contains the NPM token to use when publishing packages.
|
|
375
|
+
*/
|
|
376
|
+
readonly npmTokenSecret?: string;
|
|
377
|
+
/**
|
|
378
|
+
* Options for npm packages using AWS CodeArtifact.
|
|
379
|
+
* This is required if publishing packages to, or installing scoped packages from AWS CodeArtifact
|
|
380
|
+
*
|
|
381
|
+
* @default - undefined
|
|
382
|
+
*/
|
|
383
|
+
readonly codeArtifactOptions?: CodeArtifactOptions;
|
|
384
|
+
/**
|
|
385
|
+
* Options for privately hosted scoped packages
|
|
386
|
+
*
|
|
387
|
+
* @default undefined
|
|
388
|
+
*/
|
|
389
|
+
readonly scopedPackagesOptions?: ScopedPackagesOptions[];
|
|
390
|
+
/**
|
|
391
|
+
* npm package access level.
|
|
392
|
+
*/
|
|
393
|
+
readonly npmAccess: NpmAccess;
|
|
394
|
+
/**
|
|
395
|
+
* The name of the lock file.
|
|
396
|
+
*/
|
|
397
|
+
readonly lockFile: string;
|
|
398
|
+
/**
|
|
399
|
+
* The task for installing project dependencies (non-frozen)
|
|
400
|
+
*/
|
|
401
|
+
readonly installTask: Task;
|
|
402
|
+
/**
|
|
403
|
+
* The task for installing project dependencies (frozen)
|
|
404
|
+
*/
|
|
405
|
+
readonly installCiTask: Task;
|
|
406
|
+
private readonly keywords;
|
|
407
|
+
private readonly bin;
|
|
408
|
+
private readonly engines;
|
|
409
|
+
private readonly peerDependencyOptions;
|
|
410
|
+
private readonly file;
|
|
411
|
+
private _renderedDeps?;
|
|
412
|
+
constructor(project: Project, options?: NodePackageOptions);
|
|
413
|
+
/**
|
|
414
|
+
* Defines normal dependencies.
|
|
415
|
+
*
|
|
416
|
+
* @param deps Names modules to install. By default, the the dependency will
|
|
417
|
+
* be installed in the next `npx projen` run and the version will be recorded
|
|
418
|
+
* in your `package.json` file. You can upgrade manually or using `yarn
|
|
419
|
+
* add/upgrade`. If you wish to specify a version range use this syntax:
|
|
420
|
+
* `module@^7`.
|
|
421
|
+
*/
|
|
422
|
+
addDeps(...deps: string[]): void;
|
|
423
|
+
/**
|
|
424
|
+
* Defines development/test dependencies.
|
|
425
|
+
*
|
|
426
|
+
* @param deps Names modules to install. By default, the the dependency will
|
|
427
|
+
* be installed in the next `npx projen` run and the version will be recorded
|
|
428
|
+
* in your `package.json` file. You can upgrade manually or using `yarn
|
|
429
|
+
* add/upgrade`. If you wish to specify a version range use this syntax:
|
|
430
|
+
* `module@^7`.
|
|
431
|
+
*/
|
|
432
|
+
addDevDeps(...deps: string[]): void;
|
|
433
|
+
/**
|
|
434
|
+
* Defines peer dependencies.
|
|
435
|
+
*
|
|
436
|
+
* When adding peer dependencies, a devDependency will also be added on the
|
|
437
|
+
* pinned version of the declared peer. This will ensure that you are testing
|
|
438
|
+
* your code against the minimum version required from your consumers.
|
|
439
|
+
*
|
|
440
|
+
* @param deps Names modules to install. By default, the the dependency will
|
|
441
|
+
* be installed in the next `npx projen` run and the version will be recorded
|
|
442
|
+
* in your `package.json` file. You can upgrade manually or using `yarn
|
|
443
|
+
* add/upgrade`. If you wish to specify a version range use this syntax:
|
|
444
|
+
* `module@^7`.
|
|
445
|
+
*/
|
|
446
|
+
addPeerDeps(...deps: string[]): void;
|
|
447
|
+
/**
|
|
448
|
+
* Defines bundled dependencies.
|
|
449
|
+
*
|
|
450
|
+
* Bundled dependencies will be added as normal dependencies as well as to the
|
|
451
|
+
* `bundledDependencies` section of your `package.json`.
|
|
452
|
+
*
|
|
453
|
+
* @param deps Names modules to install. By default, the the dependency will
|
|
454
|
+
* be installed in the next `npx projen` run and the version will be recorded
|
|
455
|
+
* in your `package.json` file. You can upgrade manually or using `yarn
|
|
456
|
+
* add/upgrade`. If you wish to specify a version range use this syntax:
|
|
457
|
+
* `module@^7`.
|
|
458
|
+
*/
|
|
459
|
+
addBundledDeps(...deps: string[]): void;
|
|
460
|
+
/**
|
|
461
|
+
* Adds an `engines` requirement to your package.
|
|
462
|
+
* @param engine The engine (e.g. `node`)
|
|
463
|
+
* @param version The semantic version requirement (e.g. `^10`)
|
|
464
|
+
*/
|
|
465
|
+
addEngine(engine: string, version: string): void;
|
|
466
|
+
/**
|
|
467
|
+
* Adds keywords to package.json (deduplicated)
|
|
468
|
+
* @param keywords The keywords to add
|
|
469
|
+
*/
|
|
470
|
+
addKeywords(...keywords: string[]): void;
|
|
471
|
+
addBin(bins: Record<string, string>): void;
|
|
472
|
+
/**
|
|
473
|
+
* Override the contents of an npm package.json script.
|
|
474
|
+
*
|
|
475
|
+
* @param name The script name
|
|
476
|
+
* @param command The command to execute
|
|
477
|
+
*/
|
|
478
|
+
setScript(name: string, command: string): void;
|
|
479
|
+
/**
|
|
480
|
+
* Removes the npm script (always successful).
|
|
481
|
+
* @param name The name of the script.
|
|
482
|
+
*/
|
|
483
|
+
removeScript(name: string): void;
|
|
484
|
+
/**
|
|
485
|
+
* Indicates if a script by the given name is defined.
|
|
486
|
+
* @param name The name of the script
|
|
487
|
+
* @deprecated Use `project.tasks.tryFind(name)`
|
|
488
|
+
*/
|
|
489
|
+
hasScript(name: string): boolean;
|
|
490
|
+
/**
|
|
491
|
+
* Directly set fields in `package.json`.
|
|
492
|
+
* @escape
|
|
493
|
+
* @param name field name
|
|
494
|
+
* @param value field value
|
|
495
|
+
*/
|
|
496
|
+
addField(name: string, value: any): void;
|
|
497
|
+
/**
|
|
498
|
+
* Sets the package version.
|
|
499
|
+
* @param version Package version.
|
|
500
|
+
*/
|
|
501
|
+
addVersion(version: string): void;
|
|
502
|
+
/**
|
|
503
|
+
* Defines resolutions for dependencies to change the normally resolved
|
|
504
|
+
* version of a dependency to something else.
|
|
505
|
+
*
|
|
506
|
+
* @param resolutions Names resolutions to be added. Specify a version or
|
|
507
|
+
* range with this syntax:
|
|
508
|
+
* `module@^7`.
|
|
509
|
+
*/
|
|
510
|
+
addPackageResolutions(...resolutions: string[]): void;
|
|
511
|
+
/**
|
|
512
|
+
* Returns the command to execute in order to install all dependencies (always frozen).
|
|
513
|
+
*/
|
|
514
|
+
get installCommand(): string;
|
|
515
|
+
/**
|
|
516
|
+
* Renders `yarn install` or `npm install` with lockfile update (not frozen)
|
|
517
|
+
*/
|
|
518
|
+
get installAndUpdateLockfileCommand(): string;
|
|
519
|
+
/**
|
|
520
|
+
* Render a package manager specific command to upgrade all requested dependencies.
|
|
521
|
+
*/
|
|
522
|
+
renderUpgradePackagesCommand(exclude: string[], include?: string[]): string;
|
|
523
|
+
preSynthesize(): void;
|
|
524
|
+
postSynthesize(): void;
|
|
525
|
+
/**
|
|
526
|
+
* The command which executes "projen".
|
|
527
|
+
*/
|
|
528
|
+
get projenCommand(): string;
|
|
529
|
+
/**
|
|
530
|
+
* Returns `true` if we are running within a CI build.
|
|
531
|
+
*/
|
|
532
|
+
private get isAutomatedBuild();
|
|
533
|
+
private determineVersion;
|
|
534
|
+
/**
|
|
535
|
+
* Returns `true` if this is a CI release build.
|
|
536
|
+
*/
|
|
537
|
+
private get isReleaseBuild();
|
|
538
|
+
private parseNpmOptions;
|
|
539
|
+
private parseScopedPackagesOptions;
|
|
540
|
+
private addCodeArtifactLoginScript;
|
|
541
|
+
private addNodeEngine;
|
|
542
|
+
private renderNpmRegistryPath;
|
|
543
|
+
private renderInstallCommand;
|
|
544
|
+
private processDeps;
|
|
545
|
+
private renderDependencies;
|
|
546
|
+
/**
|
|
547
|
+
* Resolves any deps that do not have a specified version (e.g. `*`) and
|
|
548
|
+
* update `package.json` if needed.
|
|
549
|
+
*
|
|
550
|
+
* @returns `true` if package.json was updated or `false` if not.
|
|
551
|
+
*/
|
|
552
|
+
private resolveDepsAndWritePackageJson;
|
|
553
|
+
private renderPublishConfig;
|
|
554
|
+
private renderKeywords;
|
|
555
|
+
private renderEngines;
|
|
556
|
+
private autoDiscoverBinaries;
|
|
557
|
+
private renderAuthor;
|
|
558
|
+
private renderBin;
|
|
559
|
+
private renderScripts;
|
|
560
|
+
private npmScriptForTask;
|
|
561
|
+
private readPackageJson;
|
|
562
|
+
private installDependencies;
|
|
563
|
+
}
|
|
564
|
+
export interface PeerDependencyOptions {
|
|
565
|
+
/**
|
|
566
|
+
* Automatically add a pinned dev dependency.
|
|
567
|
+
* @default true
|
|
568
|
+
*/
|
|
569
|
+
readonly pinnedDevDependency?: boolean;
|
|
570
|
+
}
|
|
571
|
+
/**
|
|
572
|
+
* The node package manager to use.
|
|
573
|
+
*/
|
|
574
|
+
export declare enum NodePackageManager {
|
|
575
|
+
/**
|
|
576
|
+
* Use `yarn` as the package manager.
|
|
577
|
+
*/
|
|
578
|
+
YARN = "yarn",
|
|
579
|
+
/**
|
|
580
|
+
* Use `yarn` versions >= 2 as the package manager.
|
|
581
|
+
*/
|
|
582
|
+
YARN2 = "yarn2",
|
|
583
|
+
/**
|
|
584
|
+
* Use `npm` as the package manager.
|
|
585
|
+
*/
|
|
586
|
+
NPM = "npm",
|
|
587
|
+
/**
|
|
588
|
+
* Use `pnpm` as the package manager.
|
|
589
|
+
*/
|
|
590
|
+
PNPM = "pnpm"
|
|
591
|
+
}
|
|
592
|
+
/**
|
|
593
|
+
* Npm package access level
|
|
594
|
+
*/
|
|
595
|
+
export declare enum NpmAccess {
|
|
596
|
+
/**
|
|
597
|
+
* Package is public.
|
|
598
|
+
*/
|
|
599
|
+
PUBLIC = "public",
|
|
600
|
+
/**
|
|
601
|
+
* Package can only be accessed with credentials.
|
|
602
|
+
*/
|
|
603
|
+
RESTRICTED = "restricted"
|
|
604
|
+
}
|
|
605
|
+
export declare function defaultNpmToken(npmToken: string | undefined, registry: string | undefined): string | undefined;
|