Classes
Name | Description |
---|---|
Component | Represents a project component. |
Dependencies | The Dependencies component is responsible to track the list of dependencies a project has, and then used by project types as the model for rendering project-specific dependency manifests such as the dependencies section package.json files. |
DevEnvironmentDockerImage | Options for specifying the Docker image of the container. |
DockerCompose | Create a docker-compose YAML file. |
DockerComposeService | A docker-compose service. |
FileBase | No description |
GitAttributesFile | Assign attributes to file names in a git repository. |
Gitpod | The Gitpod component which emits .gitpod.yml. |
IgnoreFile | No description |
IniFile | Represents an INI file. |
JsonFile | Represents a JSON file. |
JsonPatch | Utility for applying RFC-6902 JSON-Patch to a document. |
License | No description |
Logger | Project-level logging utilities. |
Makefile | Minimal Makefile. |
ObjectFile | Represents an Object file. |
Project | Base project. |
ProjectBuild | Manages a standard build process for all projects. |
Projects | Programmatic API for projen. |
Projenrc | No description |
ProjenrcFile | A component representing the projen runtime configuration. |
ProjenrcJson | Sets up a project to use JSON for projenrc. |
Renovatebot | Defines renovatebot configuration for projen project. |
SampleDir | Renders the given files into the directory if the directory does not exist. |
SampleFile | Produces a file with the given contents but only once, if the file doesn’t already exist. |
SampleReadme | Represents a README.md sample file. You are expected to manage this file after creation. |
Semver | No description |
SourceCode | Represents a source file. |
Task | A task that can be performed on the project. |
TaskRuntime | The runtime component of the tasks engine. |
Tasks | Defines project tasks. |
Testing | A Testing static class with a .synth helper for getting a snapshots of construct outputs. Useful for snapshot testing with Jest. |
TextFile | A text file. |
TomlFile | Represents a TOML file. |
Version | No description |
XmlFile | Represents an XML file. |
YamlFile | Represents a YAML file. |
awscdk.AutoDiscover | Discovers and creates integration tests and lambdas from code in the project’s source and test trees. |
awscdk.AwsCdkConstructLibrary | AWS CDK construct library project. |
awscdk.AwsCdkDeps | Manages dependencies on the AWS CDK. |
awscdk.AwsCdkDepsJava | Manages dependencies on the AWS CDK for Java projects. |
awscdk.AwsCdkDepsJs | Manages dependencies on the AWS CDK for Node.js projects. |
awscdk.AwsCdkDepsPy | Manages dependencies on the AWS CDK for Python projects. |
awscdk.AwsCdkJavaApp | AWS CDK app in Java. |
awscdk.AwsCdkPythonApp | AWS CDK app in Python. |
awscdk.AwsCdkTypeScriptApp | AWS CDK app in TypeScript. |
awscdk.CdkConfig | Represents cdk.json file. |
awscdk.CdkTasks | Adds standard AWS CDK tasks to your project. |
awscdk.ConstructLibraryAws | No description |
awscdk.EdgeLambdaAutoDiscover | Creates edge lambdas from entry points discovered in the project’s source tree. |
awscdk.IntegrationTest | Cloud integration tests. |
awscdk.IntegrationTestAutoDiscover | Creates integration tests from entry points discovered in the test tree. |
awscdk.LambdaAutoDiscover | Creates lambdas from entry points discovered in the project’s source tree. |
awscdk.LambdaExtension | Create a Lambda Extension. |
awscdk.LambdaExtensionAutoDiscover | Creates Lambda Extensions from entrypoints discovered in the project’s source tree. |
awscdk.LambdaFunction | Generates a pre-bundled AWS Lambda function construct from handler code. |
awscdk.LambdaRuntime | The runtime for the AWS Lambda function. |
build.BuildWorkflow | No description |
cdk.AutoDiscoverBase | Base class for auto-discovering and creating project subcomponents. |
cdk.ConstructLibrary | A multi-language library for CDK constructs. |
cdk.IntegrationTestAutoDiscoverBase | Base class for locating integration tests in the project’s test tree. |
cdk.IntegrationTestBase | No description |
cdk.JsiiDocgen | Creates a markdown file based on the jsii manifest: - Adds a docgen script to package.json - Runs jsii-docgen after compilation - Enforces that markdown file is checked in. |
cdk.JsiiProject | Multi-language jsii library project. |
cdk8s.AutoDiscover | Automatically discovers and creates IntegrationTest s from entry points found in the test tree. |
cdk8s.Cdk8sDeps | Manages dependencies on the CDK8s. |
cdk8s.Cdk8sDepsPy | No description |
cdk8s.Cdk8sPythonApp | CDK8s app in Python. |
cdk8s.Cdk8sTypeScriptApp | CDK8s app in TypeScript. |
cdk8s.ConstructLibraryCdk8s | CDK8s construct library project. |
cdk8s.IntegrationTest | CDK8S integration test. |
cdk8s.IntegrationTestAutoDiscover | Discovers and creates integration tests from files in the test root. |
cdktf.ConstructLibraryCdktf | CDKTF construct library project. |
circleci.Circleci | Circleci Class to manage .circleci/config.yml . Check projen’s docs for more information. |
github.AutoApprove | Auto approve pull requests that meet a criteria. |
github.AutoMerge | Sets up mergify to merging approved pull requests. |
github.Dependabot | Defines dependabot configuration for node projects. |
github.GitHub | No description |
github.GitHubActionsProvider | Manage the versions used for GitHub Actions used in steps. |
github.GitHubProject | GitHub-based project. |
github.GithubCredentials | Represents a method of providing GitHub API access for projen workflows. |
github.GithubWorkflow | Workflow for GitHub. |
github.Mergify | No description |
github.PullRequestLint | Configure validations to run on GitHub pull requests. |
github.PullRequestTemplate | Template for GitHub pull requests. |
github.Stale | Warns and then closes issues and PRs that have had no activity for a specified amount of time. |
github.TaskWorkflow | A GitHub workflow for common build tasks within a project. |
github.WorkflowActions | A set of utility functions for creating GitHub actions in workflows. |
github.WorkflowJobs | A set of utility functions for creating jobs in GitHub Workflows. |
gitlab.CiConfiguration | CI for GitLab. |
gitlab.GitlabConfiguration | A GitLab CI for the main .gitlab-ci.yml file. |
gitlab.NestedConfiguration | A GitLab CI for templates that are created and included in the .gitlab-ci.yml file. |
java.JavaProject | Java project. |
java.Junit | Implements JUnit-based testing. |
java.MavenCompile | Adds the maven-compiler plugin to a POM file and the compile task. |
java.MavenPackaging | Configures a maven project to produce a .jar archive with sources and javadocs. |
java.MavenSample | Java code sample. |
java.Pom | A Project Object Model or POM is the fundamental unit of work in Maven. |
java.Projenrc | Allows writing projenrc files in java. |
javascript.Bundler | Adds support for bundling JavaScript applications and dependencies into a single file. |
javascript.Eslint | Represents eslint configuration. |
javascript.Jest | Installs the following npm scripts:. |
javascript.JestReporter | No description |
javascript.NodePackage | Represents the npm package.json file. |
javascript.NodeProject | Node.js project. |
javascript.NpmConfig | File representing the local NPM config in .npmrc. |
javascript.Prettier | Represents prettier configuration. |
javascript.Projenrc | Sets up a javascript project to use TypeScript for projenrc. |
javascript.Transform | No description |
javascript.TypescriptConfig | No description |
javascript.TypescriptConfigExtends | Container for TypescriptConfig tsconfig.json base configuration(s). Extending from more than one base config file requires TypeScript 5.0+. |
javascript.UpgradeDependencies | Upgrade node project dependencies. |
javascript.UpgradeDependenciesSchedule | How often to check for new versions and raise pull requests for version upgrades. |
javascript.WatchPlugin | No description |
python.Pip | Manages dependencies using a requirements.txt file and the pip CLI tool. |
python.Poetry | Manage project dependencies, virtual environments, and packaging through the poetry CLI tool. |
python.PoetryPyproject | Represents configuration of a pyproject.toml file for a Poetry project. |
python.Projenrc | Allows writing projenrc files in python. |
python.Pytest | No description |
python.PytestSample | Python test code sample. |
python.PythonProject | Python project. |
python.PythonSample | Python code sample. |
python.RequirementsFile | Specifies a list of packages to be installed using pip. |
python.SetupPy | Python packaging script where package metadata can be placed. |
python.Setuptools | Manages packaging through setuptools with a setup.py script. |
python.Venv | Manages a virtual environment through the Python venv module. |
release.Publisher | Implements GitHub jobs for publishing modules to package managers. |
release.Release | Manages releases (currently through GitHub workflows). |
release.ReleaseTrigger | Used to manage release strategies. |
typescript.Projenrc | Sets up a typescript project to use TypeScript for projenrc. |
typescript.ProjenrcTs | A projenrc file written in TypeScript. |
typescript.TypeScriptAppProject | TypeScript app. |
typescript.TypeScriptLibraryProject | No description |
typescript.TypeScriptProject | TypeScript project. |
typescript.TypedocDocgen | Adds a simple Typescript documentation generator. |
vscode.DevContainer | A development environment running VSCode in a container; |
vscode.VsCode | No description |
vscode.VsCodeLaunchConfig | VSCode launch configuration file (launch.json), useful for enabling in-editor debugger. |
vscode.VsCodeRecommendedExtensions | VS Code Workspace recommended extensions Source: https://code.visualstudio.com/docs/editor/extension-marketplace#_workspace-recommended-extensions. |
vscode.VsCodeSettings | VS Code Workspace settings Source: https://code.visualstudio.com/docs/getstarted/settings#_workspace-settings. |
web.NextComponent | No description |
web.NextJsProject | Next.js project without TypeScript. |
web.NextJsTypeScriptProject | Next.js project with TypeScript. |
web.PostCss | Declares a PostCSS dependency with a default config file. |
web.ReactComponent | No description |
web.ReactProject | React project without TypeScript. |
web.ReactTypeDef | No description |
web.ReactTypeScriptProject | React project with TypeScript. |
web.TailwindConfig | Declares a Tailwind CSS configuration file. |
Structs
Name | Description |
---|---|
CreateProjectOptions | No description |
Dependency | Represents a project dependency. |
DependencyCoordinates | Coordinates of the dependency (name and version). |
DepsManifest | No description |
DevEnvironmentOptions | Base options for configuring a container-based development environment. |
DockerComposeBuild | Build arguments for creating a docker image. |
DockerComposeNetworkConfig | Network configuration. |
DockerComposeNetworkIpamConfig | IPAM configuration. |
DockerComposeNetworkIpamSubnetConfig | IPAM subnet configuration. |
DockerComposePortMappingOptions | Options for port mappings. |
DockerComposeProps | Props for DockerCompose. |
DockerComposeServiceDescription | Description of a docker-compose.yml service. |
DockerComposeServicePort | A service port mapping. |
DockerComposeVolumeConfig | Volume configuration. |
DockerComposeVolumeMount | Service volume mounting information. |
FileBaseOptions | No description |
GitOptions | Git configuration options. |
GitpodOptions | Constructor options for the Gitpod component. |
GitpodPort | Options for an exposed port on Gitpod. |
GitpodPrebuilds | Configure the Gitpod App for prebuilds. |
GitpodTask | Configure options for a task to be run when opening a Gitpod workspace (e.g. running tests, or starting a dev server). |
IgnoreFileOptions | No description |
IniFileOptions | Options for IniFile . |
InitProject | Information passed from projen new to the project object when the project is first created. |
JsonFileOptions | Options for JsonFile . |
LicenseOptions | No description |
LoggerOptions | Options for logging utilities. |
MakefileOptions | Options for Makefiles. |
ObjectFileOptions | Options for ObjectFile . |
ProjectOptions | Options for Project . |
ProjenrcJsonOptions | No description |
ProjenrcOptions | No description |
RenovatebotOptions | Options for Renovatebot. |
ResolveOptions | Resolve options. |
Rule | A Make rule. |
SampleDirOptions | SampleDir options. |
SampleFileOptions | Options for the SampleFile object. |
SampleReadmeProps | SampleReadme Properties. |
SnapshotOptions | Options for the Snapshot synthesis. |
SourceCodeOptions | Options for SourceCodeFile . |
TaskCommonOptions | No description |
TaskOptions | No description |
TaskSpec | Specification of a single task. |
TaskStep | A single step within a task. |
TaskStepOptions | Options for task steps. |
TasksManifest | Schema for tasks.json . |
TextFileOptions | Options for TextFile . |
TomlFileOptions | Options for TomlFile . |
VersionOptions | Options for Version . |
XmlFileOptions | Options for XmlFile . |
YamlFileOptions | Options for JsonFile . |
awscdk.AutoDiscoverCommonOptions | Common options for auto discovering project subcomponents. |
awscdk.AutoDiscoverOptions | Options for AutoDiscover . |
awscdk.AwsCdkConstructLibraryOptions | Options for AwsCdkConstructLibrary . |
awscdk.AwsCdkDepsCommonOptions | Options for AwsCdkDeps . |
awscdk.AwsCdkDepsOptions | No description |
awscdk.AwsCdkJavaAppOptions | No description |
awscdk.AwsCdkPackageNames | Language-specific AWS CDK package names. |
awscdk.AwsCdkPythonAppOptions | Options for AwsCdkPythonApp . |
awscdk.AwsCdkTypeScriptAppOptions | No description |
awscdk.CdkConfigCommonOptions | Common options for cdk.json . |
awscdk.CdkConfigOptions | Options for CdkJson . |
awscdk.ConstructLibraryAwsOptions | No description |
awscdk.EdgeLambdaAutoDiscoverOptions | Options for EdgeLambdaAutoDiscover . |
awscdk.IntegrationTestAutoDiscoverOptions | Options for IntegrationTestAutoDiscover . |
awscdk.IntegrationTestCommonOptions | No description |
awscdk.IntegrationTestOptions | Options for IntegrationTest . |
awscdk.LambdaAutoDiscoverOptions | Options for LambdaAutoDiscover . |
awscdk.LambdaExtensionAutoDiscoverOptions | Options for LambdaExtensionAutoDiscover . |
awscdk.LambdaExtensionCommonOptions | Common options for creating lambda extensions. |
awscdk.LambdaExtensionOptions | Options for creating lambda extensions. |
awscdk.LambdaFunctionCommonOptions | Common options for LambdaFunction . |
awscdk.LambdaFunctionOptions | Options for Function . |
awscdk.LambdaRuntimeOptions | Options for the AWS Lambda function runtime. |
build.AddPostBuildJobCommandsOptions | Options for BuildWorkflow.addPostBuildJobCommands . |
build.AddPostBuildJobTaskOptions | Options for BuildWorkflow.addPostBuildJobTask . |
build.BuildWorkflowOptions | No description |
cdk.AutoDiscoverBaseOptions | Options for AutoDiscoverBase . |
cdk.Catalog | No description |
cdk.ConstructLibraryOptions | No description |
cdk.IntegrationTestAutoDiscoverBaseOptions | Options for IntegrationTestAutoDiscoverBase . |
cdk.IntegrationTestBaseOptions | Options for IntegrationTest. |
cdk.JsiiDocgenOptions | Options for JsiiDocgen . |
cdk.JsiiDotNetTarget | No description |
cdk.JsiiGoTarget | Go target configuration. |
cdk.JsiiJavaTarget | No description |
cdk.JsiiProjectOptions | No description |
cdk.JsiiPythonTarget | No description |
cdk8s.AutoDiscoverOptions | Options for AutoDiscover . |
cdk8s.Cdk8sDepsCommonOptions | Options for Cdk8sDeps . |
cdk8s.Cdk8sDepsOptions | No description |
cdk8s.Cdk8sPackageNames | No description |
cdk8s.Cdk8sPythonOptions | Options for Cdk8sPythonApp . |
cdk8s.Cdk8sTypeScriptAppOptions | No description |
cdk8s.ConstructLibraryCdk8sOptions | No description |
cdk8s.IntegrationTestAutoDiscoverOptions | No description |
cdk8s.IntegrationTestOptions | Options for IntegrationTest. |
cdktf.ConstructLibraryCdktfOptions | No description |
circleci.CircleCiProps | Options for class {@link Circleci}. |
circleci.Docker | Options for docker executor. |
circleci.Filter | The branches key controls whether the current branch should have a schedule trigger created for it, where current branch is the branch containing the config.yml file with the trigger stanza. That is, a push on the main branch will only schedule a workflow for the main branch. |
circleci.FilterConfig | set an inclusive or exclusive filter. |
circleci.Job | A Workflow is comprised of one or more uniquely named jobs. |
circleci.Machine | No description |
circleci.Macos | CircleCI supports running jobs on macOS, to allow you to build, test, and deploy apps for macOS, iOS, tvOS and watchOS. |
circleci.Matrix | The matrix stanza allows you to run a parameterized job multiple times with different arguments. |
circleci.PipelineParameter | Parameters are declared by name under a job, command, or executor. |
circleci.Run | Used for invoking all command-line programs, taking either a map of configuration values, or, when called in its short-form, a string that will be used as both the command and name. |
circleci.Schedule | A workflow may have a schedule indicating it runs at a certain time. |
circleci.StepRun | Execution steps for Job. |
circleci.Triggers | Specifies which triggers will cause this workflow to be executed. |
circleci.Workflow | Used for orchestrating all jobs. |
circleci.WorkflowJob | A Job is part of Workflow. |
github.AutoApproveOptions | Options for ‘AutoApprove’. |
github.AutoMergeOptions | No description |
github.CheckoutWithPatchOptions | Options for checkoutWithPatch . |
github.CreatePullRequestOptions | No description |
github.DependabotIgnore | You can use the ignore option to customize which dependencies are updated. |
github.DependabotOptions | No description |
github.DependabotRegistry | Use to add private registry support for dependabot. |
github.GitHubOptions | No description |
github.GitHubProjectOptions | Options for GitHubProject . |
github.GitIdentity | Represents the git identity. |
github.GithubCredentialsAppOptions | Options for GithubCredentials.fromApp . |
github.GithubCredentialsPersonalAccessTokenOptions | Options for GithubCredentials.fromPersonalAccessToken . |
github.GithubWorkflowOptions | Options for GithubWorkflow . |
github.MergifyConditionalOperator | The Mergify conditional operators that can be used are: or and and . |
github.MergifyOptions | No description |
github.MergifyQueue | No description |
github.MergifyRule | No description |
github.PullRequestFromPatchOptions | No description |
github.PullRequestLintOptions | Options for PullRequestLint. |
github.PullRequestPatchSource | No description |
github.PullRequestTemplateOptions | Options for PullRequestTemplate . |
github.SemanticTitleOptions | Options for linting that PR titles follow Conventional Commits. |
github.StaleBehavior | Stale behavior. |
github.StaleOptions | Options for Stale . |
github.TaskWorkflowOptions | No description |
github.UploadGitPatchOptions | Options for uploadGitPatch . |
gitlab.AllowFailure | Exit code that are not considered failure. |
gitlab.Artifacts | Used to specify a list of files and directories that should be attached to the job if it succeeds. |
gitlab.Assets | Asset configuration for a release. |
gitlab.Cache | Cache Definition. |
gitlab.CacheKeyFiles | Use this construct to generate a new key when one or two specific files change. |
gitlab.CiConfigurationOptions | Options for CiConfiguration . |
gitlab.CoverageReport | Code coverage report interface. |
gitlab.Default | Default settings for the CI Configuration. |
gitlab.Engine | The engine configuration for a secret. |
gitlab.Environment | The environment that a job deploys to. |
gitlab.Filter | Filtering options for when a job will run. |
gitlab.Image | Specifies the docker image to use for the job or globally for all jobs. |
gitlab.Include | An included YAML file. |
gitlab.IncludeRule | Rules allows for an array of individual rule objects to be evaluated in order, until one matches and dynamically provides attributes to the job. |
gitlab.Inherit | Controls inheritance of globally-defined defaults and variables. |
gitlab.Job | Jobs are the most fundamental element of a .gitlab-ci.yml file. |
gitlab.KubernetesConfig | Used to configure the kubernetes deployment for this environment. |
gitlab.Link | Link configuration for an asset. |
gitlab.Need | A jobs in a previous stage whose sole completion is needed to start the current job. |
gitlab.Parallel | Used to run a job multiple times in parallel in a single pipeline. |
gitlab.Release | Indicates that the job creates a Release. |
gitlab.Reports | Reports will be uploaded as artifacts, and often displayed in the Gitlab UI, such as in Merge Requests. |
gitlab.Retry | How many times a job is retried if it fails. |
gitlab.Secret | A CI/CD secret. |
gitlab.Service | Used to specify an additional Docker image to run scripts in. |
gitlab.Trigger | Trigger a multi-project or a child pipeline. |
gitlab.TriggerInclude | References a local file or an artifact from another job to define the pipeline configuration. |
gitlab.VariableConfig | Explains what the global variable is used for, what the acceptable values are. |
gitlab.VaultConfig | Specification for a secret provided by a HashiCorp Vault. |
gitlab.Workflow | Used to control pipeline behavior. |
gitlab.WorkflowRule | Used to control whether or not a whole pipeline is created. |
java.JavaProjectCommonOptions | Options for JavaProject . |
java.JavaProjectOptions | Options for JavaProject . |
java.JunitOptions | Options for Junit . |
java.MavenCompileOptions | Options for MavenCompile . |
java.MavenPackagingOptions | Options for MavenPackage . |
java.MavenRepository | Represents a Maven repository. |
java.MavenSampleOptions | No description |
java.PluginExecution | Plugin execution definition. |
java.PluginOptions | Options for Maven plugins. |
java.PomOptions | Options for Pom . |
java.ProjenrcOptions | Options for Projenrc . |
javascript.AddBundleOptions | Options for addBundle() . |
javascript.Bundle | No description |
javascript.BundlerOptions | Options for Bundler . |
javascript.BundlingOptions | Options for bundling. |
javascript.CodeArtifactOptions | Options for publishing npm packages to AWS CodeArtifact. |
javascript.CoverageThreshold | No description |
javascript.EslintOptions | No description |
javascript.EslintOverride | eslint rules override. |
javascript.HasteConfig | No description |
javascript.JestConfigOptions | No description |
javascript.JestOptions | No description |
javascript.NodePackageOptions | No description |
javascript.NodeProjectOptions | No description |
javascript.NpmConfigOptions | Options to configure the local NPM config. |
javascript.PeerDependencyOptions | No description |
javascript.PrettierOptions | Options for Prettier. |
javascript.PrettierOverride | No description |
javascript.PrettierSettings | Options to set in Prettier directly or through overrides. |
javascript.ProjenrcOptions | No description |
javascript.RenderWorkflowSetupOptions | Options for renderInstallSteps() . |
javascript.ScopedPackagesOptions | Options for scoped packages. |
javascript.TypeScriptCompilerOptions | No description |
javascript.TypescriptConfigOptions | No description |
javascript.UpgradeDependenciesOptions | Options for UpgradeDependencies . |
javascript.UpgradeDependenciesWorkflowOptions | Options for UpgradeDependencies.workflowOptions . |
python.PipOptions | Options for pip. |
python.PoetryPyprojectOptions | Poetry-specific options. |
python.PoetryPyprojectOptionsWithoutDeps | Poetry-specific options. |
python.ProjenrcOptions | Options for Projenrc . |
python.PytestOptions | No description |
python.PytestSampleOptions | Options for python test code sample. |
python.PythonPackagingOptions | No description |
python.PythonProjectOptions | Options for PythonProject . |
python.PythonSampleOptions | Options for python sample code. |
python.RequirementsFileOptions | No description |
python.SetupPyOptions | Fields to pass in the setup() function of setup.py. |
python.VenvOptions | Options for venv. |
release.BranchOptions | Options for a release branch. |
release.CodeArtifactOptions | Options for publishing packages to AWS CodeArtifact. |
release.CommonPublishOptions | Common publishing options. |
release.GitHubReleasesPublishOptions | Publishing options for GitHub releases. |
release.GitPublishOptions | Publishing options for Git releases. |
release.GoPublishOptions | Options for Go releases. |
release.JsiiReleaseGo | No description |
release.JsiiReleaseMaven | No description |
release.JsiiReleaseNpm | No description |
release.JsiiReleaseNuget | No description |
release.JsiiReleasePyPi | No description |
release.ManualReleaseOptions | No description |
release.MavenPublishOptions | Options for Maven releases. |
release.NpmPublishOptions | Options for npm release. |
release.NugetPublishOptions | Options for NuGet releases. |
release.PublisherOptions | Options for Publisher . |
release.PyPiPublishOptions | Options for PyPI release. |
release.ReleaseOptions | Options for Release . |
release.ReleaseProjectOptions | Project options for release. |
release.ScheduledReleaseOptions | No description |
typescript.ProjenrcOptions | No description |
typescript.ProjenrcTsOptions | No description |
typescript.TypeScriptLibraryProjectOptions | No description |
typescript.TypeScriptProjectOptions | No description |
vscode.DevContainerFeature | devcontainer features options. |
vscode.DevContainerOptions | Constructor options for the DevContainer component. |
vscode.Presentation | VSCode launch configuration Presentation interface “using the order, group, and hidden attributes in the presentation object you can sort, group, and hide configurations and compounds in the Debug configuration dropdown and in the Debug quick pick.” Source: https://code.visualstudio.com/docs/editor/debugging#_launchjson-attributes. |
vscode.ServerReadyAction | VSCode launch configuration ServerReadyAction interface “if you want to open a URL in a web browser whenever the program under debugging outputs a specific message to the debug console or integrated terminal.” Source: https://code.visualstudio.com/docs/editor/debugging#_launchjson-attributes. |
vscode.VsCodeLaunchConfigurationEntry | Options for a ‘VsCodeLaunchConfigurationEntry’ Source: https://code.visualstudio.com/docs/editor/debugging#_launchjson-attributes. |
web.NextComponentOptions | No description |
web.NextJsCommonProjectOptions | No description |
web.NextJsProjectOptions | No description |
web.NextJsTypeScriptProjectOptions | No description |
web.PostCssOptions | No description |
web.ReactComponentOptions | No description |
web.ReactProjectOptions | No description |
web.ReactRewireOptions | No description |
web.ReactTypeDefOptions | No description |
web.ReactTypeScriptProjectOptions | No description |
web.TailwindConfigOptions | No description |
Interfaces
Name | Description |
---|---|
IDevEnvironment | Abstract interface for container-based development environments, such as Gitpod and GitHub Codespaces. |
IDockerComposeNetworkBinding | Network binding information. |
IDockerComposeNetworkConfig | Storage for network configuration. |
IDockerComposeServiceName | An interface providing the name of a docker compose service. |
IDockerComposeVolumeBinding | Volume binding information. |
IDockerComposeVolumeConfig | Storage for volume configuration. |
IResolvable | No description |
IResolver | API for resolving tokens when synthesizing file content. |
github.IAddConditionsLater | No description |
python.IPackageProvider | No description |
python.IPythonDeps | No description |
python.IPythonEnv | No description |
python.IPythonPackaging | No description |
vscode.IDevContainerEnvironment | No description |
Enums
Name | Description |
---|---|
DependencyType | Type of dependency. |
DockerComposeProtocol | Network protocol for port mapping. |
GitpodOnOpen | What to do when a service on a port is detected. |
GitpodOpenIn | Configure where in the IDE the terminal should be opened. |
GitpodOpenMode | Configure how the terminal should be opened relative to the previous task. |
GitpodPortVisibility | Whether the port visibility should be private or public. |
InitProjectOptionHints | Choices for how to display commented out options in projenrc files. |
LogLevel | Logging verbosity. |
ProjectType | Which type of project this is. |
RenovatebotScheduleInterval | How often to check for new versions and raise pull requests for version updates. |
awscdk.ApprovalLevel | Which approval is required when deploying CDK apps. |
cdk.Stability | No description |
circleci.JobType | A job may have a type of approval indicating it must be manually approved before downstream jobs may proceed. |
circleci.JobWhen | Specify when to enable or disable the step. |
circleci.PipelineParameterType | Pipeline parameter types. |
circleci.ResourceClass | The resource_class feature allows configuring CPU and RAM resources for each job. |
github.DependabotRegistryType | Each configuration type requires you to provide particular settings. |
github.DependabotScheduleInterval | How often to check for new versions and raise pull requests for version updates. |
github.VersioningStrategy | The strategy to use when edits manifest and lock files. |
gitlab.Action | Specifies what this job will do. |
gitlab.CachePolicy | Configure the upload and download behaviour of a cache. |
gitlab.CacheWhen | Configure when artifacts are uploaded depended on job status. |
gitlab.DefaultElement | No description |
gitlab.DeploymentTier | Explicitly specifies the tier of the deployment environment if non-standard environment name is used. |
gitlab.JobWhen | Describes the conditions for when to run the job. |
gitlab.KubernetesEnum | Filter job based on if Kubernetes integration is active. |
gitlab.LinkType | The content kind of what users can download via url. |
gitlab.Strategy | You can mirror the pipeline status from the triggered pipeline to the source bridge job by using strategy: depend. |
gitlab.WorkflowWhen | Describes the conditions for when to run the job. |
javascript.ArrowParens | No description |
javascript.AutoRelease | Automatic bump modes. |
javascript.CodeArtifactAuthProvider | Options for authorizing requests to a AWS CodeArtifact npm repository. |
javascript.EmbeddedLanguageFormatting | No description |
javascript.EndOfLine | No description |
javascript.HTMLWhitespaceSensitivity | No description |
javascript.NodePackageManager | The node package manager to use. |
javascript.NpmAccess | Npm package access level. |
javascript.ProseWrap | No description |
javascript.QuoteProps | No description |
javascript.TrailingComma | No description |
javascript.TypeScriptImportsNotUsedAsValues | This flag controls how import works, there are 3 different options. |
javascript.TypeScriptJsxMode | Determines how JSX should get transformed into valid JavaScript. |
javascript.TypeScriptModuleResolution | Determines how modules get resolved. |
javascript.UpdateSnapshot | No description |
release.CodeArtifactAuthProvider | Options for authorizing requests to a AWS CodeArtifact npm repository. |
vscode.Console | Controls where to launch the debug target Source: https://code.visualstudio.com/docs/editor/debugging#_launchjson-attributes. |
vscode.InternalConsoleOptions | Controls the visibility of the VSCode Debug Console panel during a debugging session Source: https://code.visualstudio.com/docs/editor/debugging#_launchjson-attributes. |
Represents a project component.
new Component(project: Project)
[Project](#projen-project)
) No descriptionName | Type | Description |
---|---|---|
project🔹 | [Project](#projen-project) |
Called after synthesis.
Order is not guaranteed.
postSynthesize(): void
Called before synthesis.
preSynthesize(): void
Synthesizes files to the project output directory.
synthesize(): void
The Dependencies
component is responsible to track the list of dependencies a project has, and then used by project types as the model for rendering project-specific dependency manifests such as the dependencies section package.json
files.
To add a dependency you can use a project-type specific API such as
nodeProject.addDeps()
or use the generic API of project.deps
:
Extends: Component
Adds a dependencies component to the project.
new Dependencies(project: Project)
[Project](#projen-project)
) The parent project.Name | Type | Description |
---|---|---|
all🔹 | Array<[Dependency](#projen-dependency)> |
A copy of all dependencies recorded for this project. |
static MANIFEST_FILE🔹 | string |
The project-relative path of the deps manifest file. |
Adds a dependency to this project.
addDependency(spec: string, type: DependencyType, metadata?: Map<string, any>): Dependency
string
) The dependency spec in the format MODULE[@VERSION]
where MODULE
is the package-manager-specific module name and VERSION
is an optional semantic version requirement (e.g. ^3.4.0
).[DependencyType](#projen-dependencytype)
) The type of the dependency.Map<string, any>
) No descriptionReturns:
[Dependency](#projen-dependency)
Returns a dependency by name.
Fails if there is no dependency defined by that name or if type
is not
provided and there is more then one dependency type for this dependency.
getDependency(name: string, type?: DependencyType): Dependency
string
) The name of the dependency.[DependencyType](#projen-dependencytype)
) The dependency type.Returns:
[Dependency](#projen-dependency)
Removes a dependency.
removeDependency(name: string, type?: DependencyType): void
string
) The name of the module to remove (without the version).[DependencyType](#projen-dependencytype)
) The dependency type.Returns a dependency by name.
Returns undefined
if there is no dependency defined by that name or if
type
is not provided and there is more then one dependency type for this
dependency.
tryGetDependency(name: string, type?: DependencyType): Dependency
string
) The name of the dependency.[DependencyType](#projen-dependencytype)
) The dependency type.Returns:
[Dependency](#projen-dependency)
Returns the coordinates of a dependency spec.
Given foo@^3.4.0
returns { name: "foo", version: "^3.4.0" }
.
Given bar@npm:@bar/legacy
returns { name: "bar", version: "npm:@bar/legacy" }
.
static parseDependency(spec: string): DependencyCoordinates
string
) No descriptionReturns:
[DependencyCoordinates](#projen-dependencycoordinates)
Options for specifying the Docker image of the container.
Name | Type | Description |
---|---|---|
dockerFile?🔹 | string |
The relative path of a Dockerfile that defines the container contents. Optional |
image?🔹 | string |
A publicly available Docker image. Optional |
The relative path of a Dockerfile that defines the container contents.
static fromFile(dockerFile: string): DevEnvironmentDockerImage
string
) a relative path.Returns:
[DevEnvironmentDockerImage](#projen-devenvironmentdockerimage)
A publicly available Docker image.
static fromImage(image: string): DevEnvironmentDockerImage
string
) a Docker image.Returns:
[DevEnvironmentDockerImage](#projen-devenvironmentdockerimage)
Create a docker-compose YAML file.
Extends: Component
new DockerCompose(project: Project, props?: DockerComposeProps)
[Project](#projen-project)
) No description[DockerComposeProps](#projen-dockercomposeprops)
) No description
string
) A name to add to the docker-compose.yml filename. Default: no name is addedstring
) Docker Compose schema version do be used. Default: 3.3Map<string, [DockerComposeServiceDescription](#projen-dockercomposeservicedescription)>
) Service descriptions. OptionalAdd a service to the docker-compose file.
addService(serviceName: string, description: DockerComposeServiceDescription): DockerComposeService
string
) name of the service.[DockerComposeServiceDescription](#projen-dockercomposeservicedescription)
) a service description.
Array</code>) Provide a command to the docker container. __*Default*__: use the container's default command
Array<[IDockerComposeServiceName](#projen-idockercomposeservicename)>
) Names of other services this service depends on. Default: no dependenciesArray</code>) Entrypoint to run in the container. __*Optional*__
Map<string, string>
) Add environment variables. Default: no environment variables are providedstring
) Use a docker image. Optional[DockerComposeBuild](#projen-dockercomposebuild)
) Build a docker image. OptionalMap<string, string>
) Add labels. Default: no labels are providedArray<[IDockerComposeNetworkBinding](#projen-idockercomposenetworkbinding)>
) Add some networks to the service. OptionalArray<[DockerComposeServicePort](#projen-dockercomposeserviceport)>
) Map some ports. Default: no ports are mappedArray<[IDockerComposeVolumeBinding](#projen-idockercomposevolumebinding)>
) Mount some volumes into the service. OptionalReturns:
[DockerComposeService](#projen-dockercomposeservice)
Create a bind volume that binds a host path to the target path in the container.
static bindVolume(sourcePath: string, targetPath: string): IDockerComposeVolumeBinding
string
) Host path name.string
) Target path name.Returns:
[IDockerComposeVolumeBinding](#projen-idockercomposevolumebinding)
Create a named volume and mount it to the target path.
If you use this named volume in several services, the volume will be shared. In this case, the volume configuration of the first-provided options are used.
static namedVolume(volumeName: string, targetPath: string, options?: DockerComposeVolumeConfig): IDockerComposeVolumeBinding
string
) Name of the volume.string
) Target path.[DockerComposeVolumeConfig](#projen-dockercomposevolumeconfig)
) volume configuration (default: docker compose defaults).
string
) Driver to use for the volume. Default: value is not providedMap<string, string>
) Options to provide to the driver. Optionalboolean
) Set to true to indicate that the volume is externally created. Default: unset, indicating that docker-compose creates the volumestring
) Name of the volume for when the volume name isn’t going to work in YAML. Default: unset, indicating that docker-compose creates volumes as usualReturns:
[IDockerComposeVolumeBinding](#projen-idockercomposevolumebinding)
Create a named network and mount it to the target path.
If you use this named network in several services, the network will be shared. In this case, the network configuration of the first-provided options are used.
static network(networkName: string, options?: DockerComposeNetworkConfig): IDockerComposeNetworkBinding
string
) Name of the network.[DockerComposeNetworkConfig](#projen-dockercomposenetworkconfig)
) network configuration.
boolean
) Set to true to indicate that standalone containers can attach to this network, in addition to services. Default: unsetboolean
) Set to true to indicate that the network is a bridge network. Default: unsetstring
) Driver to use for the network. Default: value is not providedjson
) Options for the configured driver. Default: value is not providedboolean
) Set to true to indicate that the network is externally created. Default: unset, indicating that docker-compose creates the networkboolean
) Set to true to indicate that you want to create an externally isolated overlay network. Default: unset[DockerComposeNetworkIpamConfig](#projen-dockercomposenetworkipamconfig)
) Specify custom IPAM config. Default: unsetArray</code>) Attach labels to the network. __*Default*__: unset
string
) Name of the network for when the network name isn’t going to work in YAML. Default: unset, indicating that docker-compose creates networks as usualboolean
) Set to true to indicate that the network is an overlay network. Default: unsetReturns:
[IDockerComposeNetworkBinding](#projen-idockercomposenetworkbinding)
Create a port mapping.
static portMapping(publishedPort: number, targetPort: number, options?: DockerComposePortMappingOptions): DockerComposeServicePort
number
) Published port number.number
) Container’s port number.[DockerComposePortMappingOptions](#projen-dockercomposeportmappingoptions)
) Port mapping options.
[DockerComposeProtocol](#projen-dockercomposeprotocol)
) Port mapping protocol. Default: DockerComposeProtocol.TCPReturns:
[DockerComposeServicePort](#projen-dockercomposeserviceport)
Depends on a service name.
static serviceName(serviceName: string): IDockerComposeServiceName
string
) No descriptionReturns:
[IDockerComposeServiceName](#projen-idockercomposeservicename)
A docker-compose service.
Implements: IDockerComposeServiceName
new DockerComposeService(serviceName: string, serviceDescription: DockerComposeServiceDescription)
string
) The name of the docker compose service.[DockerComposeServiceDescription](#projen-dockercomposeservicedescription)
) No description
Array</code>) Provide a command to the docker container. __*Default*__: use the container's default command
Array<[IDockerComposeServiceName](#projen-idockercomposeservicename)>
) Names of other services this service depends on. Default: no dependenciesArray</code>) Entrypoint to run in the container. __*Optional*__
Map<string, string>
) Add environment variables. Default: no environment variables are providedstring
) Use a docker image. Optional[DockerComposeBuild](#projen-dockercomposebuild)
) Build a docker image. OptionalMap<string, string>
) Add labels. Default: no labels are providedArray<[IDockerComposeNetworkBinding](#projen-idockercomposenetworkbinding)>
) Add some networks to the service. OptionalArray<[DockerComposeServicePort](#projen-dockercomposeserviceport)>
) Map some ports. Default: no ports are mappedArray<[IDockerComposeVolumeBinding](#projen-idockercomposevolumebinding)>
) Mount some volumes into the service. OptionalName | Type | Description |
---|---|---|
dependsOn🔹 | Array<[IDockerComposeServiceName](#projen-idockercomposeservicename)> |
Other services that this service depends on. |
environment🔹 | Map<string, string> |
Environment variables. |
labels🔹 | Map<string, string> |
Attached labels. |
networks🔹 | Array<[IDockerComposeNetworkBinding](#projen-idockercomposenetworkbinding)> |
Networks mounted in the container. |
ports🔹 | Array<[DockerComposeServicePort](#projen-dockercomposeserviceport)> |
Published ports. |
serviceName🔹 | string |
Name of the service. |
volumes🔹 | Array<[IDockerComposeVolumeBinding](#projen-idockercomposevolumebinding)> |
Volumes mounted in the container. |
command?🔹 | Array |
Command to run in the container. Optional |
entrypoint?🔹 | Array |
Entrypoint to run in the container. Optional |
image?🔹 | string |
Docker image. Optional |
imageBuild?🔹 | [DockerComposeBuild](#projen-dockercomposebuild) |
Docker image build instructions. Optional |
Make the service depend on another service.
addDependsOn(serviceName: IDockerComposeServiceName): void
[IDockerComposeServiceName](#projen-idockercomposeservicename)
) No descriptionAdd an environment variable.
addEnvironment(name: string, value: string): void
string
) environment variable name.string
) value of the environment variable.Add a label.
addLabel(name: string, value: string): void
string
) environment variable name.string
) value of the environment variable.Add a network to the service.
addNetwork(network: IDockerComposeNetworkBinding): void
[IDockerComposeNetworkBinding](#projen-idockercomposenetworkbinding)
) No descriptionAdd a port mapping.
addPort(publishedPort: number, targetPort: number, options?: DockerComposePortMappingOptions): void
number
) Published port number.number
) Container’s port number.[DockerComposePortMappingOptions](#projen-dockercomposeportmappingoptions)
) Port mapping options.
[DockerComposeProtocol](#projen-dockercomposeprotocol)
) Port mapping protocol. Default: DockerComposeProtocol.TCPAdd a volume to the service.
addVolume(volume: IDockerComposeVolumeBinding): void
[IDockerComposeVolumeBinding](#projen-idockercomposevolumebinding)
) No descriptionExtends: Component Implemented by: github.PullRequestTemplate, python.RequirementsFile, python.SetupPy, web.ReactTypeDef, GitAttributesFile, IgnoreFile, IniFile, JsonFile, License, Makefile, TextFile, TomlFile, XmlFile, YamlFile Obtainable from: Project.tryFindFile(), Project.tryRemoveFile()
new FileBase(project: Project, filePath: string, options?: FileBaseOptions)
[Project](#projen-project)
) No descriptionstring
) No description[FileBaseOptions](#projen-filebaseoptions)
) No description
boolean
) Indicates whether this file should be committed to git or ignored. Default: trueboolean
) Update the project’s .gitignore file. Default: trueboolean
) Whether the generated file should be marked as executable. Default: falseboolean
) Adds the projen marker to the file. Default: marker will be included as long as the project is not ejectedboolean
) Whether the generated file should be readonly. Default: trueName | Type | Description |
---|---|---|
absolutePath🔹 | string |
The absolute path of this file. |
executable🔹 | boolean |
Indicates if the file should be marked as executable. |
path🔹 | string |
The file path, relative to the project root. |
readonly🔹 | boolean |
Indicates if the file should be read-only or read-write. |
changed?🔹 | boolean |
Indicates if the file has been changed during synthesis. Optional |
marker?🔹 | string |
The projen marker, used to identify files as projen-generated. Optional |
Writes the file to the project’s output directory.
synthesize(): void
Implemented by derived classes and returns the contents of the file to emit.
protected synthesizeContent(resolver: IResolver): string
[IResolver](#projen-iresolver)
) Call resolver.resolve(obj)
on any objects in order to resolve token functions.Returns:
string
Assign attributes to file names in a git repository.
Extends: FileBase
new GitAttributesFile(project: Project)
[Project](#projen-project)
) No descriptionName | Type | Description |
---|---|---|
hasLfsPatterns🔹 | boolean |
Whether the current gitattributes file has any LFS patterns. |
Maps a set of attributes to a set of files.
addAttributes(glob: string, ...attributes: string[]): void
string
) Glob pattern to match files in the repo.string
) Attributes to assign to these files.Add attributes necessary to mark these files as stored in LFS.
addLfsPattern(glob: string): void
string
) No descriptionImplemented by derived classes and returns the contents of the file to emit.
protected synthesizeContent(_: IResolver): string
[IResolver](#projen-iresolver)
) No descriptionReturns:
string
The Gitpod component which emits .gitpod.yml.
Implements: IDevEnvironment Extends: Component
new Gitpod(project: Project, options?: GitpodOptions)
[Project](#projen-project)
) No description[GitpodOptions](#projen-gitpodoptions)
) No description
[DevEnvironmentDockerImage](#projen-devenvironmentdockerimage)
) A Docker image or Dockerfile for the container. OptionalArray</code>) An array of ports that should be exposed from the container. __*Optional*__
Array<[Task](#projen-task)>
) An array of tasks that should be run when the container starts. OptionalArray</code>) An array of extension IDs that specify the extensions that should be installed inside the container when it is created. __*Optional*__
[GitpodPrebuilds](#projen-gitpodprebuilds)
) Optional Gitpod’s Github App integration for prebuilds If this is not set and Gitpod’s Github App is installed, then Gitpod will apply these defaults: https://www.gitpod.io/docs/prebuilds/#configure-the-github-app. Default: undefinedName | Type | Description |
---|---|---|
config🔹 | any |
Direct access to the gitpod configuration (escape hatch). |
Add a task with more granular options.
By default, all tasks will be run in parallel. To run tasks in sequence,
create a new Task
and set the other tasks as subtasks.
addCustomTask(options: GitpodTask): void
[GitpodTask](#projen-gitpodtask)
) The task parameters.
string
) Required.string
) In case you need to run something even before init, that is a requirement for both init and command, you can use the before property. Optionalstring
) The init property can be used to specify shell commands that should only be executed after a workspace was freshly cloned and needs to be initialized somehow. Optionalstring
) A name for this task. Default: task names are omitted when blank[GitpodOpenIn](#projen-gitpodopenin)
) You can configure where in the IDE the terminal should be opened. Default: GitpodOpenIn.BOTTOM[GitpodOpenMode](#projen-gitpodopenmode)
) You can configure how the terminal should be opened relative to the previous task. Default: GitpodOpenMode.TAB_AFTERstring
) The optional prebuild command will be executed during prebuilds. OptionalAdd a custom Docker image or Dockerfile for the container.
addDockerImage(image: DevEnvironmentDockerImage): void
[DevEnvironmentDockerImage](#projen-devenvironmentdockerimage)
) The Docker image.Add ports that should be exposed (forwarded) from the container.
addPorts(...ports: string[]): void
string
) The new ports.Add a prebuilds configuration for the Gitpod App.
addPrebuilds(config: GitpodPrebuilds): void
[GitpodPrebuilds](#projen-gitpodprebuilds)
) The configuration.
boolean
) Add a “Review in Gitpod” button to the pull request’s description. Default: falseboolean
) Add a check to pull requests. Default: trueboolean
) Add a “Review in Gitpod” button as a comment to pull requests. Default: falseboolean
) Add a label once the prebuild is ready to pull requests. Default: falseboolean
) Enable for all branches in this repo. Default: falseboolean
) Enable for the master/default branch. Default: trueboolean
) Enable for pull requests coming from this repo. Default: trueboolean
) Enable for pull requests coming from forks. Default: falseAdd tasks to run when gitpod starts.
By default, all tasks will be run in parallel. To run tasks in sequence,
create a new Task
and specify the other tasks as subtasks.
addTasks(...tasks: Task[]): void
[Task](#projen-task)
) The new tasks.Add a list of VSCode extensions that should be automatically installed in the container.
These must be in the format defined in the Open VSX registry.
addVscodeExtensions(...extensions: string[]): void
string
) The extension IDs.Extends: FileBase
new IgnoreFile(project: Project, filePath: string, options?: IgnoreFileOptions)
[Project](#projen-project)
) The project to tie this file to.string
) - the relative path in the project to put the file.[IgnoreFileOptions](#projen-ignorefileoptions)
) No description
boolean
) Filter out comment lines? Default: trueboolean
) Filter out blank/empty lines? Default: trueName | Type | Description |
---|---|---|
filterCommentLines🔹 | boolean |
|
filterEmptyLines🔹 | boolean |
Add ignore patterns.
Files that match this pattern will be ignored. If the
pattern starts with a negation mark !
, files that match will not be
ignored.
Comment lines (start with #
) and blank lines (“”) are filtered by default
but can be included using options specified when instantiating the component.
addPatterns(...patterns: string[]): void
string
) Ignore patterns.Ignore the files that match these patterns.
exclude(...patterns: string[]): void
string
) The patterns to match.Always include the specified file patterns.
include(...patterns: string[]): void
string
) Patterns to include in git commits.Removes patterns previously added from the ignore file.
If addPattern()
is called after this, the pattern will be added again.
removePatterns(...patterns: string[]): void
string
) patters to remove.Implemented by derived classes and returns the contents of the file to emit.
protected synthesizeContent(resolver: IResolver): string
[IResolver](#projen-iresolver)
) No descriptionReturns:
string
Represents an INI file.
Extends: ObjectFile
new IniFile(project: Project, filePath: string, options: IniFileOptions)
[Project](#projen-project)
) No descriptionstring
) No description[IniFileOptions](#projen-inifileoptions)
) No description
boolean
) Indicates whether this file should be committed to git or ignored. Default: trueboolean
) Update the project’s .gitignore file. Default: trueboolean
) Whether the generated file should be marked as executable. Default: falseboolean
) Adds the projen marker to the file. Default: marker will be included as long as the project is not ejectedboolean
) Whether the generated file should be readonly. Default: trueany
) The object that will be serialized. Default: {} an empty object (use file.obj
to mutate).boolean
) Omits empty objects and arrays. Default: falseImplemented by derived classes and returns the contents of the file to emit.
protected synthesizeContent(resolver: IResolver): string
[IResolver](#projen-iresolver)
) No descriptionReturns:
string
Represents a JSON file.
Extends: ObjectFile
new JsonFile(project: Project, filePath: string, options: JsonFileOptions)
[Project](#projen-project)
) No descriptionstring
) No description[JsonFileOptions](#projen-jsonfileoptions)
) No description
boolean
) Indicates whether this file should be committed to git or ignored. Default: trueboolean
) Update the project’s .gitignore file. Default: trueboolean
) Whether the generated file should be marked as executable. Default: falseboolean
) Adds the projen marker to the file. Default: marker will be included as long as the project is not ejectedboolean
) Whether the generated file should be readonly. Default: trueany
) The object that will be serialized. Default: {} an empty object (use file.obj
to mutate).boolean
) Omits empty objects and arrays. Default: falseboolean
) Allow the use of comments in this file. Default: false for .json files, true for .json5 and .jsonc filesboolean
) Adds a newline at the end of the file. Default: trueName | Type | Description |
---|---|---|
supportsComments🔹 | boolean |
Implemented by derived classes and returns the contents of the file to emit.
protected synthesizeContent(resolver: IResolver): string
[IResolver](#projen-iresolver)
) No descriptionReturns:
string
Utility for applying RFC-6902 JSON-Patch to a document.
Use the the JsonPatch.apply(doc, ...ops)
function to apply a set of
operations to a JSON document and return the result.
Operations can be created using the factory methods JsonPatch.add()
,
JsonPatch.remove()
, etc.
Adds a value to an object or inserts it into an array.
In the case of an array, the value is inserted before the given index. The - character can be used instead of an index to insert at the end of an array.
static add(path: string, value: any): JsonPatch
string
) No descriptionany
) No descriptionReturns:
[JsonPatch](#projen-jsonpatch)
Applies a set of JSON-Patch (RFC-6902) operations to document
and returns the result.
static apply(document: any, ...ops: JsonPatch[]): any
any
) The document to patch.[JsonPatch](#projen-jsonpatch)
) The operations to apply.Returns:
any
Copies a value from one location to another within the JSON document.
Both from and path are JSON Pointers.
static copy(from: string, path: string): JsonPatch
string
) No descriptionstring
) No descriptionReturns:
[JsonPatch](#projen-jsonpatch)
Moves a value from one location to the other.
Both from and path are JSON Pointers.
static move(from: string, path: string): JsonPatch
string
) No descriptionstring
) No descriptionReturns:
[JsonPatch](#projen-jsonpatch)
Removes a value from an object or array.
static remove(path: string): JsonPatch
string
) No descriptionReturns:
[JsonPatch](#projen-jsonpatch)
Replaces a value.
Equivalent to a “remove” followed by an “add”.
static replace(path: string, value: any): JsonPatch
string
) No descriptionany
) No descriptionReturns:
[JsonPatch](#projen-jsonpatch)
Tests that the specified value is set in the document.
If the test fails, then the patch as a whole should not apply.
static test(path: string, value: any): JsonPatch
string
) No descriptionany
) No descriptionReturns:
[JsonPatch](#projen-jsonpatch)
Extends: FileBase
new License(project: Project, options: LicenseOptions)
[Project](#projen-project)
) No description[LicenseOptions](#projen-licenseoptions)
) No description
string
) License type (SPDX).string
) Copyright owner. Default: -string
) Period of license (e.g. “1998-2023”). Default: current year (e.g. “2020”)Implemented by derived classes and returns the contents of the file to emit.
protected synthesizeContent(_: IResolver): string
[IResolver](#projen-iresolver)
) No descriptionReturns:
string
Project-level logging utilities.
Extends: Component
new Logger(project: Project, options?: LoggerOptions)
[Project](#projen-project)
) No description[LoggerOptions](#projen-loggeroptions)
) No description
[LogLevel](#projen-loglevel)
) The logging verbosity. Default: LogLevel.INFOboolean
) Include a prefix for all logging messages with the project name. Default: falseLog a message to stderr with DEBUG severity.
debug(...text: any[]): void
any
) strings or objects to print.Log a message to stderr with ERROR severity.
error(...text: any[]): void
any
) strings or objects to print.Log a message to stderr with INFO severity.
info(...text: any[]): void
any
) strings or objects to print.Log a message to stderr with a given logging level.
The message will be
printed as long as logger.level
is set to the message’s severity or higher.
log(level: LogLevel, ...text: any[]): void
[LogLevel](#projen-loglevel)
) Logging verbosity.any
) strings or objects to print.Log a message to stderr with VERBOSE severity.
verbose(...text: any[]): void
any
) strings or objects to print.Log a message to stderr with WARN severity.
warn(...text: any[]): void
any
) strings or objects to print.Minimal Makefile.
Extends: FileBase
new Makefile(project: Project, filePath: string, options?: MakefileOptions)
[Project](#projen-project)
) No descriptionstring
) No description[MakefileOptions](#projen-makefileoptions)
) No description
boolean
) Indicates whether this file should be committed to git or ignored. Default: trueboolean
) Update the project’s .gitignore file. Default: trueboolean
) Whether the generated file should be marked as executable. Default: falseboolean
) Adds the projen marker to the file. Default: marker will be included as long as the project is not ejectedboolean
) Whether the generated file should be readonly. Default: trueArray</code>) List of targets to build when Make is invoked without specifying any targets. __*Default*__: []
Array<[Rule](#projen-rule)>
) Rules to include in the Makefile. Default: []Name | Type | Description |
---|---|---|
rules🔹 | Array<[Rule](#projen-rule)> |
List of rule definitions. |
Add a target to all.
addAll(target: string): Makefile
string
) No descriptionReturns:
[Makefile](#projen-makefile)
Add multiple targets to all.
addAlls(...targets: string[]): Makefile
string
) No descriptionReturns:
[Makefile](#projen-makefile)
Add a rule to the Makefile.
addRule(rule: Rule): Makefile
[Rule](#projen-rule)
) No description
Array</code>) Files to be created or updated by this rule.
boolean
) Marks whether the target is phony. Default: falseArray</code>) Files that are used as inputs to create a target. __*Default*__: []
Array</code>) Commands that are run (using prerequisites as inputs) to create a target. __*Default*__: []
Returns:
[Makefile](#projen-makefile)
Add multiple rules to the Makefile.
addRules(...rules: Rule[]): Makefile
[Rule](#projen-rule)
) No description
Array</code>) Files to be created or updated by this rule.
boolean
) Marks whether the target is phony. Default: falseArray</code>) Files that are used as inputs to create a target. __*Default*__: []
Array</code>) Commands that are run (using prerequisites as inputs) to create a target. __*Default*__: []
Returns:
[Makefile](#projen-makefile)
Implemented by derived classes and returns the contents of the file to emit.
protected synthesizeContent(resolver: IResolver): string
[IResolver](#projen-iresolver)
) No descriptionReturns:
string
Represents an Object file.
Extends: FileBase Implemented by: IniFile, JsonFile, TomlFile, XmlFile, YamlFile Obtainable from: Project.tryFindObjectFile()
new ObjectFile(project: Project, filePath: string, options: ObjectFileOptions)
[Project](#projen-project)
) No descriptionstring
) No description[ObjectFileOptions](#projen-objectfileoptions)
) No description
boolean
) Indicates whether this file should be committed to git or ignored. Default: trueboolean
) Update the project’s .gitignore file. Default: trueboolean
) Whether the generated file should be marked as executable. Default: falseboolean
) Adds the projen marker to the file. Default: marker will be included as long as the project is not ejectedboolean
) Whether the generated file should be readonly. Default: trueany
) The object that will be serialized. Default: {} an empty object (use file.obj
to mutate).boolean
) Omits empty objects and arrays. Default: falseName | Type | Description |
---|---|---|
omitEmpty🔹 | boolean |
Indicates if empty objects and arrays are omitted from the output object. |
Syntactic sugar for addOverride(path, undefined)
.
addDeletionOverride(path: string): void
string
) The path of the value to delete.Adds an override to the synthesized object file.
If the override is nested, separate each nested level using a dot (.) in the path parameter. If there is an array as part of the nesting, specify the index in the path.
To include a literal .
in the property name, prefix with a \
. In most
programming languages you will need to write this as "\\."
because the
\
itself will need to be escaped.
For example,
project.tsconfig.file.addOverride('compilerOptions.alwaysStrict', true);
project.tsconfig.file.addOverride('compilerOptions.lib', ['dom', 'dom.iterable', 'esnext']);
would add the overrides
"compilerOptions": {
"alwaysStrict": true,
"lib": [
"dom",
"dom.iterable",
"esnext"
]
...
}
...
addOverride(path: string, value: any): void
string
) - The path of the property, you can use dot notation to override values in complex types.any
) - The value.Adds to an array in the synthesized object file.
If the array is nested, separate each nested level using a dot (.) in the path parameter. If there is an array as part of the nesting, specify the index in the path.
To include a literal .
in the property name, prefix with a \
. In most
programming languages you will need to write this as "\\."
because the
\
itself will need to be escaped.
For example, with the following object file
"compilerOptions": {
"exclude": ["node_modules"],
"lib": ["es2019"]
...
}
...
project.tsconfig.file.addToArray('compilerOptions.exclude', 'coverage');
project.tsconfig.file.addToArray('compilerOptions.lib', 'dom', 'dom.iterable', 'esnext');
would result in the following object file
"compilerOptions": {
"exclude": ["node_modules", "coverage"],
"lib": ["es2019", "dom", "dom.iterable", "esnext"]
...
}
...
addToArray(path: string, ...values: any[]): void
string
) - The path of the property, you can use dot notation to att to arrays in complex types.any
) - The values to add.Applies an RFC 6902 JSON-patch to the synthesized object file. See https://datatracker.ietf.org/doc/html/rfc6902 for more information.
For example, with the following object file
"compilerOptions": {
"exclude": ["node_modules"],
"lib": ["es2019"]
...
}
...
project.tsconfig.file.patch(JsonPatch.add("/compilerOptions/exclude/-", "coverage"));
project.tsconfig.file.patch(JsonPatch.replace("/compilerOptions/lib", ["dom", "dom.iterable", "esnext"]));
would result in the following object file
"compilerOptions": {
"exclude": ["node_modules", "coverage"],
"lib": ["dom", "dom.iterable", "esnext"]
...
}
...
patch(...patches: JsonPatch[]): void
[JsonPatch](#projen-jsonpatch)
) - The patch operations to apply.Implemented by derived classes and returns the contents of the file to emit.
protected synthesizeContent(resolver: IResolver): string
[IResolver](#projen-iresolver)
) No descriptionReturns:
string
Base project.
new Project(options: ProjectOptions)
[ProjectOptions](#projen-projectoptions)
) No description
string
) This is the name of your project.boolean
) Whether to commit the managed files by default. Default: true[IgnoreFileOptions](#projen-ignorefileoptions)
) Configuration options for .gitignore file. Optional[GitOptions](#projen-gitoptions)
) Configuration options for git. Optional[LoggerOptions](#projen-loggeroptions)
) Configure logging options such as verbosity. Default: {}string
) The root directory of the project. Default: “.”[Project](#projen-project)
) The parent project, if this project is part of a bigger project. Optionalstring
) The shell command to use in order to run the projen CLI. Default: “npx projen”boolean
) Generate (once) .projenrc.json (in JSON). Set to false
in order to disable .projenrc.json generation. Default: false[ProjenrcJsonOptions](#projen-projenrcjsonoptions)
) Options for .projenrc.json. Default: default optionsboolean
) Use renovatebot to handle dependency upgrades. Default: false[RenovatebotOptions](#projen-renovatebotoptions)
) Options for renovatebot. Default: default optionsName | Type | Description |
---|---|---|
buildTask🔹 | [Task](#projen-task) |
|
commitGenerated🔹 | boolean |
Whether to commit the managed files by default. |
compileTask🔹 | [Task](#projen-task) |
|
components🔹 | Array<[Component](#projen-component)> |
Returns all the components within this project. |
deps🔹 | [Dependencies](#projen-dependencies) |
Project dependencies. |
ejected🔹 | boolean |
Whether or not the project is being ejected. |
files🔹 | Array<[FileBase](#projen-filebase)> |
All files in this project. |
gitattributes🔹 | [GitAttributesFile](#projen-gitattributesfile) |
The .gitattributes file for this repository. |
gitignore🔹 | [IgnoreFile](#projen-ignorefile) |
.gitignore. |
logger🔹 | [Logger](#projen-logger) |
Logging utilities. |
name🔹 | string |
Project name. |
outdir🔹 | string |
Absolute output directory of this project. |
packageTask🔹 | [Task](#projen-task) |
|
postCompileTask🔹 | [Task](#projen-task) |
|
preCompileTask🔹 | [Task](#projen-task) |
|
projectBuild🔹 | [ProjectBuild](#projen-projectbuild) |
Manages the build process of the project. |
projenCommand🔹 | string |
The command to use in order to run the projen CLI. |
root🔹 | [Project](#projen-project) |
The root project. |
subprojects🔹 | Array<[Project](#projen-project)> |
Returns all the subprojects within this project. |
tasks🔹 | [Tasks](#projen-tasks) |
Project tasks. |
testTask🔹 | [Task](#projen-task) |
|
defaultTask?🔹 | [Task](#projen-task) |
This is the “default” task, the one that executes “projen”. Optional |
initProject?🔹 | [InitProject](#projen-initproject) |
The options used when this project is bootstrapped via projen new .Optional |
parent?🔹 | [Project](#projen-project) |
A parent project. Optional |
static DEFAULT_TASK🔹 | string |
The name of the default task (the task executed when projen is run without arguments). |
Exclude the matching files from pre-synth cleanup.
Can be used when, for example, some source files include the projen marker and we don’t want them to be erased during synth.
addExcludeFromCleanup(...globs: string[]): void
string
) The glob patterns to match.Adds a .gitignore pattern.
addGitIgnore(pattern: string): void
string
) The glob pattern to ignore.Exclude these files from the bundled package.
Implemented by project types based on the
packaging mechanism. For example, NodeProject
delegates this to .npmignore
.
addPackageIgnore(_pattern: string): void
string
) The glob pattern to exclude.Adds a new task to this project.
This will fail if the project already has a task with this name.
addTask(name: string, props?: TaskOptions): Task
string
) The task name to add.[TaskOptions](#projen-taskoptions)
) Task properties.
string
) A shell command which determines if the this task should be executed. Optionalstring
) The working directory for all steps in this task (unless overridden by the step). Default: process.cwd()string
) The description of this build command. Default: the task nameMap<string, string>
) Defines environment variables for the execution of this task. Default: {}Array</code>) A set of environment variables that must be defined in order to execute this task. __*Optional*__
Array</code>) Should the provided `exec` shell command receive fixed args. __*Default*__: no arguments are passed to the step
string
) Shell command to execute as the first command of the task. Default: add steps using task.exec(command)
or task.spawn(subtask)
boolean
) Should the provided exec
shell command receive args passed to the task. Default: falseArray<[TaskStep](#projen-taskstep)>
) List of task steps to run. OptionalReturns:
[Task](#projen-task)
Prints a “tip” message during synthesis.
addTip(message: string): void
string
) The message.Consider a set of files as “generated”.
This method is implemented by derived classes and used for example, to add git attributes to tell GitHub that certain files are generated.
annotateGenerated(_glob: string): void
string
) the glob pattern to match (could be a file path).Called after all components are synthesized.
Order is not guaranteed.
postSynthesize(): void
Called before all components are synthesized.
preSynthesize(): void
Removes a task from a project.
removeTask(name: string): Task
string
) The name of the task to remove.Returns:
[Task](#projen-task)
Returns the shell command to execute in order to run a task.
By default, this is npx projen@<version> <task>
runTaskCommand(task: Task): string
[Task](#projen-task)
) The task for which the command is required.Returns:
string
Synthesize all project files into outdir
.
synth(): void
Finds a file at the specified relative path within this project and all its subprojects.
tryFindFile(filePath: string): FileBase
string
) The file path.Returns:
[FileBase](#projen-filebase)
Finds a json file by name.
tryFindJsonFile(filePath: string): JsonFile
string
) The file path.Returns:
[JsonFile](#projen-jsonfile)
Finds an object file (like JsonFile, YamlFile, etc.) by name.
tryFindObjectFile(filePath: string): ObjectFile
string
) The file path.Returns:
[ObjectFile](#projen-objectfile)
Finds a file at the specified relative path within this project and removes it.
tryRemoveFile(filePath: string): FileBase
string
) The file path.Returns:
[FileBase](#projen-filebase)
Manages a standard build process for all projects.
Build spawns these tasks in order:
Extends: Component
new ProjectBuild(project: Project)
[Project](#projen-project)
) No descriptionName | Type | Description |
---|---|---|
buildTask🔹 | [Task](#projen-task) |
The task responsible for a full release build. |
compileTask🔹 | [Task](#projen-task) |
Compiles the code. |
packageTask🔹 | [Task](#projen-task) |
The “package” task. |
postCompileTask🔹 | [Task](#projen-task) |
Post-compile task. |
preCompileTask🔹 | [Task](#projen-task) |
Pre-compile task. |
testTask🔹 | [Task](#projen-task) |
Tests the code. |
Programmatic API for projen.
Creates a new project with defaults.
This function creates the project type in-process (with in VM) and calls
.synth()
on it (if options.synth
is not false
).
At the moment, it also generates a .projenrc.js
file with the same code
that was just executed. In the future, this will also be done by the project
type, so we can easily support multiple languages of projenrc.
An environment variable (PROJEN_CREATE_PROJECT=true) is set within the VM so that custom project types can detect whether the current synthesis is the result of a new project creation (and take additional steps accordingly)
static createProject(options: CreateProjectOptions): void
[CreateProjectOptions](#projen-createprojectoptions)
) No description
string
) Directory that the project will be generated in.string
) Fully-qualified name of the project type (usually formatted as projen.module.ProjectType
).Map<string, any>
) Project options.[InitProjectOptionHints](#projen-initprojectoptionhints)
) Should we render commented-out default options in the projenrc file? Default: InitProjectOptionHints.FEATUREDboolean
) Should we execute post synthesis hooks? Default: trueboolean
) Should we call project.synth()
or instantiate the project (could still have side-effects) and render the .projenrc file. Default: trueExtends: ProjenrcJson
new Projenrc(project: Project, options?: ProjenrcJsonOptions)
[Project](#projen-project)
) No description[ProjenrcJsonOptions](#projen-projenrcjsonoptions)
) No description
string
) The name of the projenrc file. Default: “.projenrc.json”A component representing the projen runtime configuration.
Extends: Component Implemented by: java.Projenrc, javascript.Projenrc, python.Projenrc, typescript.Projenrc, typescript.ProjenrcTs, Projenrc, ProjenrcJson
new ProjenrcFile(project: Project)
[Project](#projen-project)
) No descriptionName | Type | Description |
---|---|---|
filePath🔹 | string |
The path of the projenrc file. |
Returns the Projenrc
instance associated with a project or undefined
if there is no Projenrc.
static of(project: Project): ProjenrcFile
[Project](#projen-project)
) The project.Returns:
[ProjenrcFile](#projen-projenrcfile)
Sets up a project to use JSON for projenrc.
Extends: ProjenrcFile
new ProjenrcJson(project: Project, options?: ProjenrcJsonOptions)
[Project](#projen-project)
) No description[ProjenrcJsonOptions](#projen-projenrcjsonoptions)
) No description
string
) The name of the projenrc file. Default: “.projenrc.json”Name | Type | Description |
---|---|---|
filePath🔹 | string |
The path of the projenrc file. |
Defines renovatebot configuration for projen project.
Ignores the versions controlled by Projen.
Extends: Component
new Renovatebot(project: Project, options?: RenovatebotOptions)
[Project](#projen-project)
) No description[RenovatebotOptions](#projen-renovatebotoptions)
) No description
Array</code>) You can use the `ignore` option to customize which dependencies are updated. __*Default*__: []
boolean
) Ignores updates to projen
. Default: trueArray</code>) List of labels to apply to the created PR's. __*Optional*__
boolean
) No description Optionalany
) No description OptionalArray</code>) How often to check for new versions and raise pull requests. __*Default*__: ["at any time"]
Called before synthesis.
preSynthesize(): void
Renders the given files into the directory if the directory does not exist.
Use this to create sample code files
Extends: Component
Create sample files in the given directory if the given directory does not exist.
new SampleDir(project: Project, dir: string, options: SampleDirOptions)
[Project](#projen-project)
) Parent project to add files to.string
) directory to add files to.[SampleDirOptions](#projen-samplediroptions)
) options for which files to create.
Map<string, string>
) The files to render into the directory. Optionalstring
) Absolute path to a directory to copy files from (does not need to be text files). OptionalSynthesizes files to the project output directory.
synthesize(): void
Produces a file with the given contents but only once, if the file doesn’t already exist.
Use this for creating example code files or other resources.
Extends: Component
Creates a new SampleFile object.
new SampleFile(project: Project, filePath: string, options: SampleFileOptions)
[Project](#projen-project)
) - the project to tie this file to.string
) - the relative path in the project to put the file.[SampleFileOptions](#projen-samplefileoptions)
) - the options for the file.
string
) The contents of the file to write. Optionalstring
) Absolute path to a file to copy the contents from (does not need to be a text file). OptionalSynthesizes files to the project output directory.
synthesize(): void
Represents a README.md sample file. You are expected to manage this file after creation.
Extends: SampleFile
new SampleReadme(project: Project, props?: SampleReadmeProps)
[Project](#projen-project)
) No description[SampleReadmeProps](#projen-samplereadmeprops)
) No description
string
) The contents. Default: “# replace this”string
) The name of the README.md file. Default: “README.md”Name | Type | Description |
---|---|---|
spec⚠️ | string |
|
mode?⚠️ | string |
Optional |
version?⚠️ | string |
Optional |
Accept any minor version.
= version < next major version
static caret(version: string): Semver
string
) No descriptionReturns:
[Semver](#projen-semver)
Latest version.
static latest(): Semver
Returns:
[Semver](#projen-semver)
static of(spec: string): Semver
string
) No descriptionReturns:
[Semver](#projen-semver)
Accept only an exact version.
static pinned(version: string): Semver
string
) No descriptionReturns:
[Semver](#projen-semver)
Accept patches.
= version < next minor version
static tilde(version: string): Semver
string
) No descriptionReturns:
[Semver](#projen-semver)
Represents a source file.
Extends: Component
new SourceCode(project: Project, filePath: string, options?: SourceCodeOptions)
[Project](#projen-project)
) No descriptionstring
) No description[SourceCodeOptions](#projen-sourcecodeoptions)
) No description
number
) Indentation size. Default: 2boolean
) Whether the generated file should be readonly. Default: trueName | Type | Description |
---|---|---|
filePath🔹 | string |
|
marker?🔹 | string |
Optional |
Decreases the indentation level and closes a code block.
close(code?: string): void
string
) The code after the block is closed (e.g. }
).Emit a line of code.
line(code?: string): void
string
) The contents, if not specified, just adds a newline.Opens a code block and increases the indentation level.
open(code?: string): void
string
) The code before the block starts (e.g. export class {
).A task that can be performed on the project.
Modeled as a series of shell commands and subtasks.
new Task(name: string, props?: TaskOptions)
string
) No description[TaskOptions](#projen-taskoptions)
) No description
string
) A shell command which determines if the this task should be executed. Optionalstring
) The working directory for all steps in this task (unless overridden by the step). Default: process.cwd()string
) The description of this build command. Default: the task nameMap<string, string>
) Defines environment variables for the execution of this task. Default: {}Array</code>) A set of environment variables that must be defined in order to execute this task. __*Optional*__
Array</code>) Should the provided `exec` shell command receive fixed args. __*Default*__: no arguments are passed to the step
string
) Shell command to execute as the first command of the task. Default: add steps using task.exec(command)
or task.spawn(subtask)
boolean
) Should the provided exec
shell command receive args passed to the task. Default: falseArray<[TaskStep](#projen-taskstep)>
) List of task steps to run. OptionalName | Type | Description |
---|---|---|
name🔹 | string |
Task name. |
steps🔹 | Array<[TaskStep](#projen-taskstep)> |
Returns an immutable copy of all the step specifications of the task. |
condition?🔹 | string |
A command to execute which determines if the task should be skipped. Optional |
description?🔹 | string |
Returns the description of this task. Optional |
Add a command to execute which determines if the task should be skipped.
If a condition already exists, the new condition will be appended with ` && ` delimiter.
addCondition(...condition: string[]): void
string
) The command to execute.Execute a builtin task.
Builtin tasks are programs bundled as part of projen itself and used as helpers for various components.
In the future we should support built-in tasks from external modules.
builtin(name: string): void
string
) The name of the builtin task to execute (e.g. release/resolve-version
).Adds an environment variable to this task.
env(name: string, value: string): void
string
) The name of the variable.string
) The value.Executes a shell command.
exec(command: string, options?: TaskStepOptions): void
string
) Shell command.[TaskStepOptions](#projen-taskstepoptions)
) Options.
Array</code>) A list of fixed arguments always passed to the step. __*Default*__: no arguments are passed to the step
string
) A shell command which determines if the this step should be executed. Optionalstring
) The working directory for this step. Default: determined by the taskMap<string, string>
) Defines environment variables for the execution of this step (exec
and builtin
only). Default: no environment variables defined in stepstring
) Step name. Default: no nameboolean
) Should this step receive args passed to the task. Default: falseForbid additional changes to this task.
lock(): void
Adds a command at the beginning of the task.
prepend(shell: string, options?: TaskStepOptions): void
string
) The command to add.[TaskStepOptions](#projen-taskstepoptions)
) No description
Array</code>) A list of fixed arguments always passed to the step. __*Default*__: no arguments are passed to the step
string
) A shell command which determines if the this step should be executed. Optionalstring
) The working directory for this step. Default: determined by the taskMap<string, string>
) Defines environment variables for the execution of this step (exec
and builtin
only). Default: no environment variables defined in stepstring
) Step name. Default: no nameboolean
) Should this step receive args passed to the task. Default: falseAdds a command at the beginning of the task.
prependExec(shell: string, options?: TaskStepOptions): void
string
) The command to add.[TaskStepOptions](#projen-taskstepoptions)
) No description
Array</code>) A list of fixed arguments always passed to the step. __*Default*__: no arguments are passed to the step
string
) A shell command which determines if the this step should be executed. Optionalstring
) The working directory for this step. Default: determined by the taskMap<string, string>
) Defines environment variables for the execution of this step (exec
and builtin
only). Default: no environment variables defined in stepstring
) Step name. Default: no nameboolean
) Should this step receive args passed to the task. Default: falseSays something at the beginning of the task.
prependSay(message: string, options?: TaskStepOptions): void
string
) Your message.[TaskStepOptions](#projen-taskstepoptions)
) No description
Array</code>) A list of fixed arguments always passed to the step. __*Default*__: no arguments are passed to the step
string
) A shell command which determines if the this step should be executed. Optionalstring
) The working directory for this step. Default: determined by the taskMap<string, string>
) Defines environment variables for the execution of this step (exec
and builtin
only). Default: no environment variables defined in stepstring
) Step name. Default: no nameboolean
) Should this step receive args passed to the task. Default: falseAdds a spawn instruction at the beginning of the task.
prependSpawn(subtask: Task, options?: TaskStepOptions): void
[Task](#projen-task)
) The subtask to execute.[TaskStepOptions](#projen-taskstepoptions)
) No description
Array</code>) A list of fixed arguments always passed to the step. __*Default*__: no arguments are passed to the step
string
) A shell command which determines if the this step should be executed. Optionalstring
) The working directory for this step. Default: determined by the taskMap<string, string>
) Defines environment variables for the execution of this step (exec
and builtin
only). Default: no environment variables defined in stepstring
) Step name. Default: no nameboolean
) Should this step receive args passed to the task. Default: falseReset the task so it no longer has any commands.
reset(command?: string, options?: TaskStepOptions): void
string
) the first command to add to the task after it was cleared.[TaskStepOptions](#projen-taskstepoptions)
) No description
Array</code>) A list of fixed arguments always passed to the step. __*Default*__: no arguments are passed to the step
string
) A shell command which determines if the this step should be executed. Optionalstring
) The working directory for this step. Default: determined by the taskMap<string, string>
) Defines environment variables for the execution of this step (exec
and builtin
only). Default: no environment variables defined in stepstring
) Step name. Default: no nameboolean
) Should this step receive args passed to the task. Default: falseSay something.
say(message: string, options?: TaskStepOptions): void
string
) Your message.[TaskStepOptions](#projen-taskstepoptions)
) Options.
Array</code>) A list of fixed arguments always passed to the step. __*Default*__: no arguments are passed to the step
string
) A shell command which determines if the this step should be executed. Optionalstring
) The working directory for this step. Default: determined by the taskMap<string, string>
) Defines environment variables for the execution of this step (exec
and builtin
only). Default: no environment variables defined in stepstring
) Step name. Default: no nameboolean
) Should this step receive args passed to the task. Default: falseSpawns a sub-task.
spawn(subtask: Task, options?: TaskStepOptions): void
[Task](#projen-task)
) The subtask to execute.[TaskStepOptions](#projen-taskstepoptions)
) No description
Array</code>) A list of fixed arguments always passed to the step. __*Default*__: no arguments are passed to the step
string
) A shell command which determines if the this step should be executed. Optionalstring
) The working directory for this step. Default: determined by the taskMap<string, string>
) Defines environment variables for the execution of this step (exec
and builtin
only). Default: no environment variables defined in stepstring
) Step name. Default: no nameboolean
) Should this step receive args passed to the task. Default: falseThe runtime component of the tasks engine.
new TaskRuntime(workdir: string)
string
) No descriptionName | Type | Description |
---|---|---|
manifest🔹 | [TasksManifest](#projen-tasksmanifest) |
The contents of tasks.json. |
tasks🔹 | Array<[TaskSpec](#projen-taskspec)> |
The tasks in this project. |
workdir🔹 | string |
The root directory of the project and the cwd for executing tasks. |
static MANIFEST_FILE🔹 | string |
The project-relative path of the tasks manifest file. |
Runs the task.
runTask(name: string, parents?: Array<string>, args?: Array<string | number>): void
string
) The task name.Array</code>) *No description*
Array<string | number>
) No descriptionFind a task by name, or undefined
if not found.
tryFindTask(name: string): TaskSpec
string
) No descriptionReturns:
[TaskSpec](#projen-taskspec)
Defines project tasks.
Tasks extend the projen CLI by adding subcommands to it. Task definitions are
synthesized into .projen/tasks.json
.
Extends: Component
new Tasks(project: Project)
[Project](#projen-project)
) No descriptionName | Type | Description |
---|---|---|
all🔹 | Array<[Task](#projen-task)> |
All tasks. |
env🔹 | Map<string, string> |
Returns a copy of the currently global environment for this project. |
Adds global environment.
addEnvironment(name: string, value: string): void
string
) Environment variable name.string
) Value.Adds a task to a project.
addTask(name: string, options?: TaskOptions): Task
string
) The name of the task.[TaskOptions](#projen-taskoptions)
) Task options.
string
) A shell command which determines if the this task should be executed. Optionalstring
) The working directory for all steps in this task (unless overridden by the step). Default: process.cwd()string
) The description of this build command. Default: the task nameMap<string, string>
) Defines environment variables for the execution of this task. Default: {}Array</code>) A set of environment variables that must be defined in order to execute this task. __*Optional*__
Array</code>) Should the provided `exec` shell command receive fixed args. __*Default*__: no arguments are passed to the step
string
) Shell command to execute as the first command of the task. Default: add steps using task.exec(command)
or task.spawn(subtask)
boolean
) Should the provided exec
shell command receive args passed to the task. Default: falseArray<[TaskStep](#projen-taskstep)>
) List of task steps to run. OptionalReturns:
[Task](#projen-task)
Removes a task from a project.
removeTask(name: string): Task
string
) The name of the task to remove.Returns:
[Task](#projen-task)
Synthesizes files to the project output directory.
synthesize(): void
Finds a task by name.
Returns undefined
if the task cannot be found.
tryFind(name: string): Task
string
) The name of the task.Returns:
[Task](#projen-task)
A Testing static class with a .synth helper for getting a snapshots of construct outputs. Useful for snapshot testing with Jest.
Produces a simple JS object that represents the contents of the projects with field names being file paths.
static synth(project: Project, options?: SnapshotOptions): Map<string, any>
[Project](#projen-project)
) the project to produce a snapshot for.[SnapshotOptions](#projen-snapshotoptions)
) No description
boolean
) Parse .json files as a JS object for improved inspection. This will fail if the contents are invalid JSON. Default: true parse .json files into an objectReturns:
Map<string, any>
A text file.
Extends: FileBase
Defines a text file.
new TextFile(project: Project, filePath: string, options?: TextFileOptions)
[Project](#projen-project)
) The project.string
) File path.[TextFileOptions](#projen-textfileoptions)
) Options.
boolean
) Indicates whether this file should be committed to git or ignored. Default: trueboolean
) Update the project’s .gitignore file. Default: trueboolean
) Whether the generated file should be marked as executable. Default: falseboolean
) Adds the projen marker to the file. Default: marker will be included as long as the project is not ejectedboolean
) Whether the generated file should be readonly. Default: trueArray</code>) The contents of the text file. __*Default*__: [] empty file
Adds a line to the text file.
addLine(line: string): void
string
) the line to add (can use tokens).Implemented by derived classes and returns the contents of the file to emit.
protected synthesizeContent(_: IResolver): string
[IResolver](#projen-iresolver)
) No descriptionReturns:
string
Represents a TOML file.
Extends: ObjectFile
new TomlFile(project: Project, filePath: string, options: TomlFileOptions)
[Project](#projen-project)
) No descriptionstring
) No description[TomlFileOptions](#projen-tomlfileoptions)
) No description
boolean
) Indicates whether this file should be committed to git or ignored. Default: trueboolean
) Update the project’s .gitignore file. Default: trueboolean
) Whether the generated file should be marked as executable. Default: falseboolean
) Adds the projen marker to the file. Default: marker will be included as long as the project is not ejectedboolean
) Whether the generated file should be readonly. Default: trueany
) The object that will be serialized. Default: {} an empty object (use file.obj
to mutate).boolean
) Omits empty objects and arrays. Default: falseImplemented by derived classes and returns the contents of the file to emit.
protected synthesizeContent(resolver: IResolver): string
[IResolver](#projen-iresolver)
) No descriptionReturns:
string
Extends: Component
new Version(project: Project, options: VersionOptions)
[Project](#projen-project)
) No description[VersionOptions](#projen-versionoptions)
) No description
string
) The name of the directory into which changelog.md
and version.txt
files are emitted.string
) A name of a .json file to set the version
field in after a bump.string
) The tag prefix corresponding to this version. OptionalMap<string, any>
) Custom configuration for versionrc file used by standard-release. OptionalName | Type | Description |
---|---|---|
bumpTask🔹 | [Task](#projen-task) |
|
changelogFileName🔹 | string |
The name of the changelog file (under artifactsDirectory ). |
releaseTagFileName🔹 | string |
The name of the file that contains the release tag (under artifactsDirectory ). |
unbumpTask🔹 | [Task](#projen-task) |
|
versionFileName🔹 | string |
The name of the file that contains the version (under artifactsDirectory ). |
static STANDARD_VERSION🔹 | string |
Represents an XML file.
Objects passed in will be synthesized using the npm “xml” library.
Extends: ObjectFile
new XmlFile(project: Project, filePath: string, options?: XmlFileOptions)
[Project](#projen-project)
) No descriptionstring
) No description[XmlFileOptions](#projen-xmlfileoptions)
) No description
boolean
) Indicates whether this file should be committed to git or ignored. Default: trueboolean
) Update the project’s .gitignore file. Default: trueboolean
) Whether the generated file should be marked as executable. Default: falseboolean
) Adds the projen marker to the file. Default: marker will be included as long as the project is not ejectedboolean
) Whether the generated file should be readonly. Default: trueany
) The object that will be serialized. Default: {} an empty object (use file.obj
to mutate).boolean
) Omits empty objects and arrays. Default: falseImplemented by derived classes and returns the contents of the file to emit.
protected synthesizeContent(resolver: IResolver): string
[IResolver](#projen-iresolver)
) No descriptionReturns:
string
Represents a YAML file.
Extends: ObjectFile
new YamlFile(project: Project, filePath: string, options: YamlFileOptions)
[Project](#projen-project)
) No descriptionstring
) No description[YamlFileOptions](#projen-yamlfileoptions)
) No description
boolean
) Indicates whether this file should be committed to git or ignored. Default: trueboolean
) Update the project’s .gitignore file. Default: trueboolean
) Whether the generated file should be marked as executable. Default: falseboolean
) Adds the projen marker to the file. Default: marker will be included as long as the project is not ejectedboolean
) Whether the generated file should be readonly. Default: trueany
) The object that will be serialized. Default: {} an empty object (use file.obj
to mutate).boolean
) Omits empty objects and arrays. Default: falsenumber
) Maximum line width (set to 0 to disable folding). Default: 0Name | Type | Description |
---|---|---|
lineWidth🔹 | number |
Maximum line width (set to 0 to disable folding). |
Implemented by derived classes and returns the contents of the file to emit.
protected synthesizeContent(resolver: IResolver): string
[IResolver](#projen-iresolver)
) No descriptionReturns:
string
Discovers and creates integration tests and lambdas from code in the project’s source and test trees.
Submodule: awscdk
Extends: Component
new awscdk.AutoDiscover(project: Project, options: AutoDiscoverOptions)
[Project](#projen-project)
) No description[awscdk.AutoDiscoverOptions](#projen-awscdk-autodiscoveroptions)
) No description
[awscdk.AwsCdkDeps](#projen-awscdk-awscdkdeps)
) AWS CDK dependency manager.string
) Path to the tsconfig file to use for integration tests.string
) Project source tree (relative to project output directory).[awscdk.LambdaFunctionCommonOptions](#projen-awscdk-lambdafunctioncommonoptions)
) Options for AWS Lambda functions. Optional[awscdk.LambdaExtensionCommonOptions](#projen-awscdk-lambdaextensioncommonoptions)
) Options for lambda extensions. Optionalstring
) Test source tree.[awscdk.IntegrationTestCommonOptions](#projen-awscdk-integrationtestcommonoptions)
) Options for integration tests. Optionalboolean
) Auto-discover edge lambda functions. Default: trueboolean
) Auto-discover integration tests. Default: trueboolean
) Auto-discover lambda functions. Default: trueboolean
) Auto-discover lambda extensions. Default: trueAWS CDK construct library project.
A multi-language (jsii) construct library which vends constructs designed to use within the AWS CDK with a friendly workflow and automatic publishing to the construct catalog.
Submodule: awscdk
Extends: cdk.ConstructLibrary
new awscdk.AwsCdkConstructLibrary(options: AwsCdkConstructLibraryOptions)
[awscdk.AwsCdkConstructLibraryOptions](#projen-awscdk-awscdkconstructlibraryoptions)
) No description
string
) This is the name of your project.boolean
) Whether to commit the managed files by default. Default: true[IgnoreFileOptions](#projen-ignorefileoptions)
) Configuration options for .gitignore file. Optional[GitOptions](#projen-gitoptions)
) Configuration options for git. Optional[LoggerOptions](#projen-loggeroptions)
) Configure logging options such as verbosity. Default: {}string
) The root directory of the project. Default: “.”[Project](#projen-project)
) The parent project, if this project is part of a bigger project. Optionalstring
) The shell command to use in order to run the projen CLI. Default: “npx projen”boolean
) Generate (once) .projenrc.json (in JSON). Set to false
in order to disable .projenrc.json generation. Default: false[ProjenrcJsonOptions](#projen-projenrcjsonoptions)
) Options for .projenrc.json. Default: default optionsboolean
) Use renovatebot to handle dependency upgrades. Default: false[RenovatebotOptions](#projen-renovatebotoptions)
) Options for renovatebot. Default: default options[github.AutoApproveOptions](#projen-github-autoapproveoptions)
) Enable and configure the ‘auto approve’ workflow. Default: auto approve is disabledboolean
) Enable automatic merging on GitHub. Default: true[github.AutoMergeOptions](#projen-github-automergeoptions)
) Configure options for automatic merging on GitHub. Default: see defaults in AutoMergeOptions
boolean
) Add a clobber
task which resets the repo to origin. Default: true, but false for subprojectsboolean
) Add a VSCode development environment (used for GitHub Codespaces). Default: falseboolean
) Enable GitHub integration. Default: true[github.GitHubOptions](#projen-github-githuboptions)
) Options for GitHub integration. Default: see GitHubOptionsboolean
) Add a Gitpod development environment. Default: falseboolean
) Whether mergify should be enabled on this repository or not. Default: true[github.MergifyOptions](#projen-github-mergifyoptions)
) Options for mergify. Default: default options[ProjectType](#projen-projecttype)
) Which type of project this is (library/app). Default: ProjectType.UNKNOWN[github.GithubCredentials](#projen-github-githubcredentials)
) Choose a method of providing GitHub API access for projen workflows. Default: use a personal access token named PROJEN_GITHUB_TOKENstring
) The name of a secret which includes a GitHub Personal Access Token to be used by projen workflows. Default: “PROJEN_GITHUB_TOKEN”[SampleReadmeProps](#projen-samplereadmeprops)
) The README setup. Default: { filename: ‘README.md’, contents: ‘# replace this’ }boolean
) Auto-close of stale issues and pull request. Default: false[github.StaleOptions](#projen-github-staleoptions)
) Auto-close stale issues and pull requests. Default: see defaults in StaleOptions
boolean
) Enable VSCode integration. Default: trueboolean
) Allow the project to include peerDependencies
and bundledDependencies
. Default: truestring
) Author’s e-mail. Optionalstring
) Author’s name. Optionalboolean
) Is the author an organization. Optionalstring
) Author’s URL / Website. Optionalboolean
) Automatically add all executables under the bin
directory to your package.json
file under the bin
section. Default: trueMap<string, string>
) Binary programs vended with your module. Optionalstring
) The email address to which issues should be reported. Optionalstring
) The url to your project’s issue tracker. OptionalArray</code>) List of dependencies to bundle into this module. __*Optional*__
[javascript.CodeArtifactOptions](#projen-javascript-codeartifactoptions)
) Options for npm packages using AWS CodeArtifact. Default: undefinedArray</code>) Runtime dependencies of this module. __*Default*__: []
string
) The description is just a string that helps people understand the purpose of the package. OptionalArray</code>) Build dependencies for this module. __*Default*__: []
string
) Module entrypoint (main
in package.json
). Default: “lib/index.js”string
) Package’s Homepage / Website. OptionalArray</code>) Keywords to include in `package.json`. __*Optional*__
string
) License’s SPDX identifier. Default: “Apache-2.0”boolean
) Indicates if a license should be added. Default: truestring
) Minimum node.js version to require via engines
(inclusive). Default: no maxstring
) Minimum Node.js version to require via package.json engines
(inclusive). Default: no “engines” specified[javascript.NpmAccess](#projen-javascript-npmaccess)
) Access level of the npm package. Default: for scoped packages (e.g. foo@bar
), the default is NpmAccess.RESTRICTED
, for non-scoped packages, the default is NpmAccess.PUBLIC
.string
) The host name of the npm registry to publish to. Optionalstring
) The base URL of the npm package registry. Default: “https://registry.npmjs.org”string
) GitHub secret which contains the NPM token to use when publishing packages. Default: “NPM_TOKEN”[javascript.NodePackageManager](#projen-javascript-nodepackagemanager)
) The Node Package Manager used to execute scripts. Default: NodePackageManager.YARNstring
) The “name” in package.json. Default: defaults to project name[javascript.PeerDependencyOptions](#projen-javascript-peerdependencyoptions)
) Options for peerDeps
. OptionalArray</code>) Peer dependencies for this module. __*Default*__: []
string
) The version of PNPM to use if using PNPM as a package manager. Default: “7”string
) The repository is the location where the actual code for your package lives. Optionalstring
) If the package.json for your package is not in the root directory (for example if it is part of a monorepo), you can specify the directory in which it lives. OptionalArray<[javascript.ScopedPackagesOptions](#projen-javascript-scopedpackagesoptions)>
) Options for privately hosted scoped packages. Default: fetch all scoped packages from the public npm registryMap<string, string>
) npm scripts to include. Default: {}string
) Package’s Stability. Optionalstring
) Version requirement of publib
which is used to publish modules to npm. Default: “latest”number
) Major version to release from the default branch. Default: Major version is not enforced.number
) Minimal Major version to release. Default: No minimum version is being enforcedstring
) The npmDistTag to use when publishing from the default branch. Default: “latest”Array<[github.workflows.JobStep](#projen-github-workflows-jobstep)>
) Steps to execute after build as part of the release workflow. Default: []string
) Bump versions from the default branch as pre-releases (e.g. “beta”, “alpha”, “pre”). Default: normal semantic versionsboolean
) Instead of actually publishing to package managers, just print the publishing command. Default: falseboolean
) Define publishing tasks that can be executed manually as well as workflows. Default: falseMap<string, [release.BranchOptions](#projen-release-branchoptions)>
) Defines additional release branches. Default: no additional branches are used for release. you can use addBranch()
to add additional branches.boolean
) Automatically release new versions every commit to one of branches in releaseBranches
. Default: trueboolean
) Create a github issue on every failed publishing task. Default: falsestring
) The label to apply to issues indicating publish failures. Default: “failed-release”string
) CRON schedule to trigger new releases. Default: no scheduled releasesstring
) Automatically add the given prefix to release tags. Useful if you are releasing on multiple branches with overlapping version numbers. Default: “v”[release.ReleaseTrigger](#projen-release-releasetrigger)
) The release trigger to use. Default: Continuous releases (ReleaseTrigger.continuous()
)string
) The name of the default release workflow. Default: “Release”Array<[github.workflows.JobStep](#projen-github-workflows-jobstep)>
) A set of workflow steps to execute in order to setup the workflow container. OptionalMap<string, any>
) Custom configuration used when creating changelog with standard-version package. Default: standard configuration applicable for GitHub repositoriesstring
) Container image to use for GitHub workflows. Default: default imageArray</code>) Github Runner selection labels. __*Default*__: ["ubuntu-latest"]
string
) The name of the main release branch.string
) A directory which will contain build artifacts. Default: “dist”boolean
) Automatically approve deps upgrade PRs, allowing them to be merged by mergify (if configued). Default: trueboolean
) Define a GitHub workflow for building PRs. Default: true if not a subproject[github.workflows.Triggers](#projen-github-workflows-triggers)
) Build workflow triggers. Default: “{ pullRequest: {}, workflowDispatch: {} }”[javascript.BundlerOptions](#projen-javascript-bundleroptions)
) Options for Bundler
. Optionalboolean
) Define a GitHub workflow step for sending code coverage metrics to https://codecov.io/ Uses codecov/codecov-action@v3 A secret is required for private repos. Configured with @codeCovTokenSecret. Default: falsestring
) Define the secret name for a specified https://codecov.io/ token A secret is required to send coverage for private repositories. Default: if this option is not specified, only public repositories are supportedstring
) License copyright owner. Default: defaults to the value of authorName or “” if authorName
is undefined.string
) The copyright years to put in the LICENSE file. Default: current yearboolean
) Use dependabot to handle dependency upgrades. Default: false[github.DependabotOptions](#projen-github-dependabotoptions)
) Options for dependabot. Default: default optionsboolean
) Use github workflows to handle dependency upgrades. Default: true[javascript.UpgradeDependenciesOptions](#projen-javascript-upgradedependenciesoptions)
) Options for UpgradeDependencies
. Default: default optionsArray</code>) Additional entries to .gitignore. __*Optional*__
boolean
) Setup jest unit tests. Default: true[javascript.JestOptions](#projen-javascript-jestoptions)
) Jest options. Default: default optionsboolean
) Automatically update files modified during builds to pull-request branches. Default: trueArray</code>) Additional entries to .npmignore. __*Optional*__
boolean
) Defines an .npmignore file. Normally this is only needed for libraries that are packaged as tarballs. Default: true[IgnoreFileOptions](#projen-ignorefileoptions)
) Configuration options for .npmignore file. Optionalboolean
) Defines a package
task that will produce an npm tarball under the artifacts directory (e.g. dist
). Default: trueboolean
) Setup prettier. Default: false[javascript.PrettierOptions](#projen-javascript-prettieroptions)
) Prettier options. Default: default optionsboolean
) Indicates of “projen” should be installed as a devDependency. Default: trueboolean
) Generate (once) .projenrc.js (in JavaScript). Set to false
in order to disable .projenrc.js generation. Default: true if projenrcJson is false[javascript.ProjenrcOptions](#projen-javascript-projenrcoptions)
) Options for .projenrc.js. Default: default optionsstring
) Version of projen to install. Default: Defaults to the latest version.boolean
) Include a GitHub pull request template. Default: trueArray</code>) The contents of the pull request template. __*Default*__: default content
boolean
) Add release management to this project. Default: true (false for subprojects)boolean
) Automatically release to npm when new versions are introduced. Default: falseboolean
) DEPRECATED: renamed to release
. Default: true if not a subprojectArray<[github.workflows.JobStep](#projen-github-workflows-jobstep)>
) Workflow steps to use in order to bootstrap this repo. Default: “yarn install –frozen-lockfile && yarn projen”[github.GitIdentity](#projen-github-gitidentity)
) The git identity to use in workflows. Default: GitHub Actionsstring
) The node version to use in GitHub workflows. Default: same as minNodeVersion
boolean
) Enable Node.js package cache in GitHub workflows. Default: falseboolean
) Do not generate a tsconfig.json
file (used by jsii projects since tsconfig.json is generated by the jsii compiler). Default: falseboolean
) Do not generate a tsconfig.dev.json
file. Default: falseboolean
) Docgen by Typedoc. Default: falsestring
) Docs directory. Default: “docs”string
) The .d.ts file that includes the type declarations for this module. Default: .d.ts file derived from the project’s entrypoint (usually lib/index.d.ts)boolean
) Setup eslint. Default: true[javascript.EslintOptions](#projen-javascript-eslintoptions)
) Eslint options. Default: opinionated default optionsstring
) Typescript artifacts output directory. Default: “lib”boolean
) Use TypeScript for your projenrc file (.projenrc.ts
). Default: false[typescript.ProjenrcOptions](#projen-typescript-projenrcoptions)
) Options for .projenrc.ts. Optionalboolean
) Generate one-time sample in src/
and test/
if there are no files there. Default: truestring
) Typescript sources directory. Default: “src”string
) Jest tests directory. Tests files should be named xxx.test.ts
. Default: “test”[javascript.TypescriptConfigOptions](#projen-javascript-typescriptconfigoptions)
) Custom TSConfig. Default: default options[javascript.TypescriptConfigOptions](#projen-javascript-typescriptconfigoptions)
) Custom tsconfig options for the development tsconfig.json file (used for testing). Default: use the production tsconfig optionsstring
) The name of the development tsconfig.json file. Default: “tsconfig.dev.json”string
) TypeScript version to use. Default: “latest”string
) The name of the library author.string
) Email or URL of the library author.string
) Git repository URL.boolean
) Automatically run API compatibility test against the latest version published to npm after compilation. Default: falsestring
) Name of the ignore file for API compatibility tests. Default: “.compatignore”boolean
) Emit a compressed version of the assembly. Default: falsestring
) File path for generated docs. Default: “API.md”[cdk.JsiiDotNetTarget](#projen-cdk-jsiidotnettarget)
) No description OptionalArray</code>) Accepts a list of glob patterns. __*Optional*__
string
) Version of the jsii compiler to use. Default: “1.x”[cdk.JsiiGoTarget](#projen-cdk-jsiigotarget)
) Publish Go bindings to a git repository. Default: no publishing[cdk.JsiiJavaTarget](#projen-cdk-jsiijavatarget)
) Publish to maven. Default: no publishing[cdk.JsiiDotNetTarget](#projen-cdk-jsiidotnettarget)
) Publish to NuGet. Default: no publishing[cdk.JsiiPythonTarget](#projen-cdk-jsiipythontarget)
) Publish to pypi. Default: no publishing[cdk.JsiiPythonTarget](#projen-cdk-jsiipythontarget)
) No description Optionalstring
) No description Default: “.”[cdk.Catalog](#projen-cdk-catalog)
) Libraries will be picked up by the construct catalog when they are published to npm as jsii modules and will be published under:. Default: new version will be announcedstring
) Minimum version of the AWS CDK to depend on.boolean
) Warning: NodeJS only. Default: will be included by default for AWS CDK >= 1.0.0 < 2.0.0boolean
) Install the assertions library? Default: will be included by default for AWS CDK >= 1.111.0 < 2.0.0Array</code>) Which AWS CDKv1 modules this project requires. __*Optional*__
boolean
) If this is enabled (default), all modules declared in cdkDependencies
will be also added as normal dependencies
(as well as peerDependencies
). Default: trueArray</code>) AWS CDK modules required for testing. __*Optional*__
boolean
) Use pinned version instead of caret version for CDK. Optionalstring
) Minimum version of the constructs
library to depend on. Default: for CDK 1.x the default is “3.2.27”, for CDK 2.x the default is “10.0.5”.boolean
) Automatically adds an cloudfront.experimental.EdgeFunction
for each .edge-lambda.ts
handler in your source tree. If this is disabled, you can manually add an awscdk.AutoDiscover
component to your project. Default: trueboolean
) Automatically discovers and creates integration tests for each .integ.ts
file in under your test directory. Default: trueboolean
) Automatically adds an aws_lambda.Function
for each .lambda.ts
handler in your source tree. If this is disabled, you either need to explicitly call aws_lambda.Function.autoDiscover()
or define a new aws_lambda.Function()
for each handler. Default: trueboolean
) Automatically adds an awscdk.LambdaExtension
for each .lambda-extension.ts
entrypoint in your source tree. If this is disabled, you can manually add an awscdk.AutoDiscover
component to your project. Default: true[awscdk.LambdaFunctionCommonOptions](#projen-awscdk-lambdafunctioncommonoptions)
) Common options for all AWS Lambda functions. Default: default optionsName | Type | Description |
---|---|---|
cdkDeps🔹 | [awscdk.AwsCdkDeps](#projen-awscdk-awscdkdeps) |
|
cdkVersion🔹 | string |
The target CDK version for this library. |
version⚠️ | string |
Adds dependencies to AWS CDK modules.
Since this is a library project, dependencies will be added as peer dependencies.
addCdkDependencies(...deps: string[]): void
string
) names of cdk modules (e.g. @aws-cdk/aws-lambda
).Adds AWS CDK modules as dev dependencies.
addCdkTestDependencies(...deps: string[]): void
string
) names of cdk modules (e.g. @aws-cdk/aws-lambda
).Manages dependencies on the AWS CDK.
Submodule: awscdk
Extends: Component Implemented by: awscdk.AwsCdkDepsJava, awscdk.AwsCdkDepsJs, awscdk.AwsCdkDepsPy
new awscdk.AwsCdkDeps(project: Project, options: AwsCdkDepsOptions)
[Project](#projen-project)
) No description[awscdk.AwsCdkDepsOptions](#projen-awscdk-awscdkdepsoptions)
) No description
string
) Minimum version of the AWS CDK to depend on.boolean
) Warning: NodeJS only. Default: will be included by default for AWS CDK >= 1.0.0 < 2.0.0boolean
) Install the assertions library? Default: will be included by default for AWS CDK >= 1.111.0 < 2.0.0Array</code>) Which AWS CDKv1 modules this project requires. __*Optional*__
boolean
) If this is enabled (default), all modules declared in cdkDependencies
will be also added as normal dependencies
(as well as peerDependencies
). Default: trueArray</code>) AWS CDK modules required for testing. __*Optional*__
boolean
) Use pinned version instead of caret version for CDK. Optionalstring
) Minimum version of the constructs
library to depend on. Default: for CDK 1.x the default is “3.2.27”, for CDK 2.x the default is “10.0.5”.[DependencyType](#projen-dependencytype)
) The type of dependency to use for runtime AWS CDK and constructs
modules.Name | Type | Description |
---|---|---|
cdkDependenciesAsDeps⚠️ | boolean |
Whether CDK dependencies are added as normal dependencies (and peer dependencies). |
cdkMajorVersion🔹 | number |
The major version of the AWS CDK (e.g. 1, 2, …). |
cdkMinimumVersion🔹 | string |
The minimum version of the AWS CDK (e.g. 2.0.0 ). |
cdkVersion🔹 | string |
The dependency requirement for AWS CDK (e.g. ^2.0.0 ). |
Adds dependencies to AWS CDK modules.
The type of dependency is determined by the dependencyType
option.
This method is not supported in CDK v2. Use project.addPeerDeps()
or
project.addDeps()
as appropriate.
addV1Dependencies(...deps: string[]): void
string
) names of cdk modules (e.g. @aws-cdk/aws-lambda
).Adds AWS CDK modules as dev dependencies.
This method is not supported in CDK v2. Use project.addPeerDeps()
or
project.addDeps()
as appropriate.
addV1DevDependencies(...deps: string[]): void
string
) fully qualified names of cdk modules (e.g. @aws-cdk/aws-lambda
).Called before synthesis.
preSynthesize(): void
Return a configuration object with information about package naming in various languages.
protected packageNames(): AwsCdkPackageNames
Returns:
[awscdk.AwsCdkPackageNames](#projen-awscdk-awscdkpackagenames)
Manages dependencies on the AWS CDK for Java projects.
Submodule: awscdk
Extends: awscdk.AwsCdkDeps
new awscdk.AwsCdkDepsJava(project: Project, options: AwsCdkDepsOptions)
[Project](#projen-project)
) No description[awscdk.AwsCdkDepsOptions](#projen-awscdk-awscdkdepsoptions)
) No description
string
) Minimum version of the AWS CDK to depend on.boolean
) Warning: NodeJS only. Default: will be included by default for AWS CDK >= 1.0.0 < 2.0.0boolean
) Install the assertions library? Default: will be included by default for AWS CDK >= 1.111.0 < 2.0.0Array</code>) Which AWS CDKv1 modules this project requires. __*Optional*__
boolean
) If this is enabled (default), all modules declared in cdkDependencies
will be also added as normal dependencies
(as well as peerDependencies
). Default: trueArray</code>) AWS CDK modules required for testing. __*Optional*__
boolean
) Use pinned version instead of caret version for CDK. Optionalstring
) Minimum version of the constructs
library to depend on. Default: for CDK 1.x the default is “3.2.27”, for CDK 2.x the default is “10.0.5”.[DependencyType](#projen-dependencytype)
) The type of dependency to use for runtime AWS CDK and constructs
modules.Return a configuration object with information about package naming in various languages.
protected packageNames(): AwsCdkPackageNames
Returns:
[awscdk.AwsCdkPackageNames](#projen-awscdk-awscdkpackagenames)
Manages dependencies on the AWS CDK for Node.js projects.
Submodule: awscdk
Extends: awscdk.AwsCdkDeps
new awscdk.AwsCdkDepsJs(project: Project, options: AwsCdkDepsOptions)
[Project](#projen-project)
) No description[awscdk.AwsCdkDepsOptions](#projen-awscdk-awscdkdepsoptions)
) No description
string
) Minimum version of the AWS CDK to depend on.boolean
) Warning: NodeJS only. Default: will be included by default for AWS CDK >= 1.0.0 < 2.0.0boolean
) Install the assertions library? Default: will be included by default for AWS CDK >= 1.111.0 < 2.0.0Array</code>) Which AWS CDKv1 modules this project requires. __*Optional*__
boolean
) If this is enabled (default), all modules declared in cdkDependencies
will be also added as normal dependencies
(as well as peerDependencies
). Default: trueArray</code>) AWS CDK modules required for testing. __*Optional*__
boolean
) Use pinned version instead of caret version for CDK. Optionalstring
) Minimum version of the constructs
library to depend on. Default: for CDK 1.x the default is “3.2.27”, for CDK 2.x the default is “10.0.5”.[DependencyType](#projen-dependencytype)
) The type of dependency to use for runtime AWS CDK and constructs
modules.Return a configuration object with information about package naming in various languages.
protected packageNames(): AwsCdkPackageNames
Returns:
[awscdk.AwsCdkPackageNames](#projen-awscdk-awscdkpackagenames)
Manages dependencies on the AWS CDK for Python projects.
Submodule: awscdk
Extends: awscdk.AwsCdkDeps
new awscdk.AwsCdkDepsPy(project: Project, options: AwsCdkDepsOptions)
[Project](#projen-project)
) No description[awscdk.AwsCdkDepsOptions](#projen-awscdk-awscdkdepsoptions)
) No description
string
) Minimum version of the AWS CDK to depend on.boolean
) Warning: NodeJS only. Default: will be included by default for AWS CDK >= 1.0.0 < 2.0.0boolean
) Install the assertions library? Default: will be included by default for AWS CDK >= 1.111.0 < 2.0.0Array</code>) Which AWS CDKv1 modules this project requires. __*Optional*__
boolean
) If this is enabled (default), all modules declared in cdkDependencies
will be also added as normal dependencies
(as well as peerDependencies
). Default: trueArray</code>) AWS CDK modules required for testing. __*Optional*__
boolean
) Use pinned version instead of caret version for CDK. Optionalstring
) Minimum version of the constructs
library to depend on. Default: for CDK 1.x the default is “3.2.27”, for CDK 2.x the default is “10.0.5”.[DependencyType](#projen-dependencytype)
) The type of dependency to use for runtime AWS CDK and constructs
modules.Return a configuration object with information about package naming in various languages.
protected packageNames(): AwsCdkPackageNames
Returns:
[awscdk.AwsCdkPackageNames](#projen-awscdk-awscdkpackagenames)
AWS CDK app in Java.
Submodule: awscdk
Extends: java.JavaProject
new awscdk.AwsCdkJavaApp(options: AwsCdkJavaAppOptions)
[awscdk.AwsCdkJavaAppOptions](#projen-awscdk-awscdkjavaappoptions)
) No description
string
) This is the name of your project.boolean
) Whether to commit the managed files by default. Default: true[IgnoreFileOptions](#projen-ignorefileoptions)
) Configuration options for .gitignore file. Optional[GitOptions](#projen-gitoptions)
) Configuration options for git. Optional[LoggerOptions](#projen-loggeroptions)
) Configure logging options such as verbosity. Default: {}string
) The root directory of the project. Default: “.”[Project](#projen-project)
) The parent project, if this project is part of a bigger project. Optionalstring
) The shell command to use in order to run the projen CLI. Default: “npx projen”boolean
) Generate (once) .projenrc.json (in JSON). Set to false
in order to disable .projenrc.json generation. Default: false[ProjenrcJsonOptions](#projen-projenrcjsonoptions)
) Options for .projenrc.json. Default: default optionsboolean
) Use renovatebot to handle dependency upgrades. Default: false[RenovatebotOptions](#projen-renovatebotoptions)
) Options for renovatebot. Default: default options[github.AutoApproveOptions](#projen-github-autoapproveoptions)
) Enable and configure the ‘auto approve’ workflow. Default: auto approve is disabledboolean
) Enable automatic merging on GitHub. Default: true[github.AutoMergeOptions](#projen-github-automergeoptions)
) Configure options for automatic merging on GitHub. Default: see defaults in AutoMergeOptions
boolean
) Add a clobber
task which resets the repo to origin. Default: true, but false for subprojectsboolean
) Add a VSCode development environment (used for GitHub Codespaces). Default: falseboolean
) Enable GitHub integration. Default: true[github.GitHubOptions](#projen-github-githuboptions)
) Options for GitHub integration. Default: see GitHubOptionsboolean
) Add a Gitpod development environment. Default: falseboolean
) Whether mergify should be enabled on this repository or not. Default: true[github.MergifyOptions](#projen-github-mergifyoptions)
) Options for mergify. Default: default options[ProjectType](#projen-projecttype)
) Which type of project this is (library/app). Default: ProjectType.UNKNOWN[github.GithubCredentials](#projen-github-githubcredentials)
) Choose a method of providing GitHub API access for projen workflows. Default: use a personal access token named PROJEN_GITHUB_TOKENstring
) The name of a secret which includes a GitHub Personal Access Token to be used by projen workflows. Default: “PROJEN_GITHUB_TOKEN”[SampleReadmeProps](#projen-samplereadmeprops)
) The README setup. Default: { filename: ‘README.md’, contents: ‘# replace this’ }boolean
) Auto-close of stale issues and pull request. Default: false[github.StaleOptions](#projen-github-staleoptions)
) Auto-close stale issues and pull requests. Default: see defaults in StaleOptions
boolean
) Enable VSCode integration. Default: truestring
) The artifactId is generally the name that the project is known by.string
) This is generally unique amongst an organization or a project.string
) This is the last piece of the naming puzzle.string
) Description of a project is always good. Default: undefinedstring
) Project packaging format. Default: “jar”string
) The URL, like the name, is not required. Default: undefined[java.MavenCompileOptions](#projen-java-mavencompileoptions)
) Compile options. Default: defaultsArray</code>) List of runtime dependencies for this project. __*Default*__: []
string
) Final artifact output directory. Default: “dist/java”boolean
) Include junit tests. Default: true[java.JunitOptions](#projen-java-junitoptions)
) junit options. Default: defaults[java.MavenPackagingOptions](#projen-java-mavenpackagingoptions)
) Packaging options. Default: defaultsboolean
) Use projenrc in java. Default: true[java.ProjenrcOptions](#projen-java-projenrcoptions)
) Options related to projenrc in java. Default: default optionsArray</code>) List of test dependencies for this project. __*Default*__: []
boolean
) Include sample code and test if the relevant directories don’t exist. Default: truestring
) The java package to use for the code sample. Default: “org.acme”string
) A command to execute before synthesis. Default: no build commandstring
) cdk.out directory. Default: “cdk.out”Map<string, any>
) Additional context to include in cdk.json
. Default: no additional contextboolean
) Include all feature flags in cdk.json. Default: true[awscdk.ApprovalLevel](#projen-awscdk-approvallevel)
) To protect you against unintended changes that affect your security posture, the AWS CDK Toolkit prompts you to approve security-related changes before deploying them. Default: ApprovalLevel.BROADENINGArray</code>) Glob patterns to exclude from `cdk watch`. __*Default*__: []
Array</code>) Glob patterns to include in `cdk watch`. __*Default*__: []
string
) Minimum version of the AWS CDK to depend on.boolean
) Warning: NodeJS only. Default: will be included by default for AWS CDK >= 1.0.0 < 2.0.0boolean
) Install the assertions library? Default: will be included by default for AWS CDK >= 1.111.0 < 2.0.0Array</code>) Which AWS CDKv1 modules this project requires. __*Optional*__
boolean
) If this is enabled (default), all modules declared in cdkDependencies
will be also added as normal dependencies
(as well as peerDependencies
). Default: trueArray</code>) AWS CDK modules required for testing. __*Optional*__
boolean
) Use pinned version instead of caret version for CDK. Optionalstring
) Minimum version of the constructs
library to depend on. Default: for CDK 1.x the default is “3.2.27”, for CDK 2.x the default is “10.0.5”.string
) The name of the Java class with the static main()
method.Name | Type | Description |
---|---|---|
cdkConfig🔹 | [awscdk.CdkConfig](#projen-awscdk-cdkconfig) |
The cdk.json file. |
cdkDeps🔹 | [awscdk.AwsCdkDeps](#projen-awscdk-awscdkdeps) |
CDK dependency management helper class. |
cdkTasks🔹 | [awscdk.CdkTasks](#projen-awscdk-cdktasks) |
CDK tasks. |
mainClass🔹 | string |
The full name of the main class of the java app (package.Class). |
mainClassName🔹 | string |
The name of the Java class with the static main() method. |
mainPackage🔹 | string |
The name of the Java package that includes the main class. |
Adds an AWS CDK module dependencies.
addCdkDependency(...modules: string[]): void
string
) The list of modules to depend on (e.g. “software.amazon.awscdk/aws-lambda”, “software.amazon.awscdk/aws-iam”, etc).AWS CDK app in Python.
Submodule: awscdk
Extends: python.PythonProject
new awscdk.AwsCdkPythonApp(options: AwsCdkPythonAppOptions)
[awscdk.AwsCdkPythonAppOptions](#projen-awscdk-awscdkpythonappoptions)
) No description
string
) This is the name of your project.boolean
) Whether to commit the managed files by default. Default: true[IgnoreFileOptions](#projen-ignorefileoptions)
) Configuration options for .gitignore file. Optional[GitOptions](#projen-gitoptions)
) Configuration options for git. Optional[LoggerOptions](#projen-loggeroptions)
) Configure logging options such as verbosity. Default: {}string
) The root directory of the project. Default: “.”[Project](#projen-project)
) The parent project, if this project is part of a bigger project. Optionalstring
) The shell command to use in order to run the projen CLI. Default: “npx projen”boolean
) Generate (once) .projenrc.json (in JSON). Set to false
in order to disable .projenrc.json generation. Default: false[ProjenrcJsonOptions](#projen-projenrcjsonoptions)
) Options for .projenrc.json. Default: default optionsboolean
) Use renovatebot to handle dependency upgrades. Default: false[RenovatebotOptions](#projen-renovatebotoptions)
) Options for renovatebot. Default: default options[github.AutoApproveOptions](#projen-github-autoapproveoptions)
) Enable and configure the ‘auto approve’ workflow. Default: auto approve is disabledboolean
) Enable automatic merging on GitHub. Default: true[github.AutoMergeOptions](#projen-github-automergeoptions)
) Configure options for automatic merging on GitHub. Default: see defaults in AutoMergeOptions
boolean
) Add a clobber
task which resets the repo to origin. Default: true, but false for subprojectsboolean
) Add a VSCode development environment (used for GitHub Codespaces). Default: falseboolean
) Enable GitHub integration. Default: true[github.GitHubOptions](#projen-github-githuboptions)
) Options for GitHub integration. Default: see GitHubOptionsboolean
) Add a Gitpod development environment. Default: falseboolean
) Whether mergify should be enabled on this repository or not. Default: true[github.MergifyOptions](#projen-github-mergifyoptions)
) Options for mergify. Default: default options[ProjectType](#projen-projecttype)
) Which type of project this is (library/app). Default: ProjectType.UNKNOWN[github.GithubCredentials](#projen-github-githubcredentials)
) Choose a method of providing GitHub API access for projen workflows. Default: use a personal access token named PROJEN_GITHUB_TOKENstring
) The name of a secret which includes a GitHub Personal Access Token to be used by projen workflows. Default: “PROJEN_GITHUB_TOKEN”[SampleReadmeProps](#projen-samplereadmeprops)
) The README setup. Default: { filename: ‘README.md’, contents: ‘# replace this’ }boolean
) Auto-close of stale issues and pull request. Default: false[github.StaleOptions](#projen-github-staleoptions)
) Auto-close stale issues and pull requests. Default: see defaults in StaleOptions
boolean
) Enable VSCode integration. Default: truestring
) Author’s e-mail.string
) Author’s name.string
) Version of the package.Array</code>) A list of PyPI trove classifiers that describe the project. __*Optional*__
string
) A short description of the package. Optionalstring
) A URL to the website of the project. Optionalstring
) License of this package as an SPDX identifier. Optionalstring
) Package name. Optional[python.PoetryPyprojectOptionsWithoutDeps](#projen-python-poetrypyprojectoptionswithoutdeps)
) Additional options to set for poetry if using poetry. OptionalMap<string, any>
) Additional fields to pass in the setup() function if using setuptools. Optionalstring
) Name of the python package as used in imports and filenames.Array</code>) List of runtime dependencies for this project. __*Default*__: []
Array</code>) List of dev dependencies for this project. __*Default*__: []
boolean
) Use pip with a requirements.txt file to track project dependencies. Default: true, unless poetry is true, then falseboolean
) Use poetry to manage your project dependencies, virtual environment, and (optional) packaging/publishing. Default: falseboolean
) Use projenrc in javascript. Default: false[javascript.ProjenrcOptions](#projen-javascript-projenrcoptions)
) Options related to projenrc in JavaScript. Default: default optionsboolean
) Use projenrc in Python. Default: true[python.ProjenrcOptions](#projen-python-projenrcoptions)
) Options related to projenrc in python. Default: default optionsboolean
) Use projenrc in TypeScript. Default: false[typescript.ProjenrcTsOptions](#projen-typescript-projenrctsoptions)
) Options related to projenrc in TypeScript. Default: default optionsboolean
) Include pytest tests. Default: true[python.PytestOptions](#projen-python-pytestoptions)
) pytest options. Default: defaultsstring
) Path to the python executable to use. Default: “python”boolean
) Include sample code and test if the relevant directories don’t exist. Default: trueboolean
) Use setuptools with a setup.py script for packaging and publishing. Default: true, unless poetry is true, then falseboolean
) Use venv to manage a virtual environment for installing dependencies inside. Default: true, unless poetry is true, then false[python.VenvOptions](#projen-python-venvoptions)
) Venv options. Default: defaultsstring
) A command to execute before synthesis. Default: no build commandstring
) cdk.out directory. Default: “cdk.out”Map<string, any>
) Additional context to include in cdk.json
. Default: no additional contextboolean
) Include all feature flags in cdk.json. Default: true[awscdk.ApprovalLevel](#projen-awscdk-approvallevel)
) To protect you against unintended changes that affect your security posture, the AWS CDK Toolkit prompts you to approve security-related changes before deploying them. Default: ApprovalLevel.BROADENINGArray</code>) Glob patterns to exclude from `cdk watch`. __*Default*__: []
Array</code>) Glob patterns to include in `cdk watch`. __*Default*__: []
string
) Minimum version of the AWS CDK to depend on.boolean
) Warning: NodeJS only. Default: will be included by default for AWS CDK >= 1.0.0 < 2.0.0boolean
) Install the assertions library? Default: will be included by default for AWS CDK >= 1.111.0 < 2.0.0Array</code>) Which AWS CDKv1 modules this project requires. __*Optional*__
boolean
) If this is enabled (default), all modules declared in cdkDependencies
will be also added as normal dependencies
(as well as peerDependencies
). Default: trueArray</code>) AWS CDK modules required for testing. __*Optional*__
boolean
) Use pinned version instead of caret version for CDK. Optionalstring
) Minimum version of the constructs
library to depend on. Default: for CDK 1.x the default is “3.2.27”, for CDK 2.x the default is “10.0.5”.string
) The CDK app’s entrypoint (relative to the source directory, which is “src” by default). Default: “app.py”string
) Python sources directory. Default: “tests”Name | Type | Description |
---|---|---|
appEntrypoint🔹 | string |
The CDK app entrypoint. |
cdkConfig🔹 | [awscdk.CdkConfig](#projen-awscdk-cdkconfig) |
cdk.json configuration. |
cdkDeps🔹 | [awscdk.AwsCdkDeps](#projen-awscdk-awscdkdeps) |
|
cdkTasks🔹 | [awscdk.CdkTasks](#projen-awscdk-cdktasks) |
Common CDK tasks. |
cdkVersion🔹 | string |
The CDK version this app is using. |
testdir🔹 | string |
The directory in which the python tests reside. |
AWS CDK app in TypeScript.
Submodule: awscdk
Extends: typescript.TypeScriptAppProject
new awscdk.AwsCdkTypeScriptApp(options: AwsCdkTypeScriptAppOptions)
[awscdk.AwsCdkTypeScriptAppOptions](#projen-awscdk-awscdktypescriptappoptions)
) No description
string
) This is the name of your project.boolean
) Whether to commit the managed files by default. Default: true[IgnoreFileOptions](#projen-ignorefileoptions)
) Configuration options for .gitignore file. Optional[GitOptions](#projen-gitoptions)
) Configuration options for git. Optional[LoggerOptions](#projen-loggeroptions)
) Configure logging options such as verbosity. Default: {}string
) The root directory of the project. Default: “.”[Project](#projen-project)
) The parent project, if this project is part of a bigger project. Optionalstring
) The shell command to use in order to run the projen CLI. Default: “npx projen”boolean
) Generate (once) .projenrc.json (in JSON). Set to false
in order to disable .projenrc.json generation. Default: false[ProjenrcJsonOptions](#projen-projenrcjsonoptions)
) Options for .projenrc.json. Default: default optionsboolean
) Use renovatebot to handle dependency upgrades. Default: false[RenovatebotOptions](#projen-renovatebotoptions)
) Options for renovatebot. Default: default options[github.AutoApproveOptions](#projen-github-autoapproveoptions)
) Enable and configure the ‘auto approve’ workflow. Default: auto approve is disabledboolean
) Enable automatic merging on GitHub. Default: true[github.AutoMergeOptions](#projen-github-automergeoptions)
) Configure options for automatic merging on GitHub. Default: see defaults in AutoMergeOptions
boolean
) Add a clobber
task which resets the repo to origin. Default: true, but false for subprojectsboolean
) Add a VSCode development environment (used for GitHub Codespaces). Default: falseboolean
) Enable GitHub integration. Default: true[github.GitHubOptions](#projen-github-githuboptions)
) Options for GitHub integration. Default: see GitHubOptionsboolean
) Add a Gitpod development environment. Default: falseboolean
) Whether mergify should be enabled on this repository or not. Default: true[github.MergifyOptions](#projen-github-mergifyoptions)
) Options for mergify. Default: default options[ProjectType](#projen-projecttype)
) Which type of project this is (library/app). Default: ProjectType.UNKNOWN[github.GithubCredentials](#projen-github-githubcredentials)
) Choose a method of providing GitHub API access for projen workflows. Default: use a personal access token named PROJEN_GITHUB_TOKENstring
) The name of a secret which includes a GitHub Personal Access Token to be used by projen workflows. Default: “PROJEN_GITHUB_TOKEN”[SampleReadmeProps](#projen-samplereadmeprops)
) The README setup. Default: { filename: ‘README.md’, contents: ‘# replace this’ }boolean
) Auto-close of stale issues and pull request. Default: false[github.StaleOptions](#projen-github-staleoptions)
) Auto-close stale issues and pull requests. Default: see defaults in StaleOptions
boolean
) Enable VSCode integration. Default: trueboolean
) Allow the project to include peerDependencies
and bundledDependencies
. Default: truestring
) Author’s e-mail. Optionalstring
) Author’s name. Optionalboolean
) Is the author an organization. Optionalstring
) Author’s URL / Website. Optionalboolean
) Automatically add all executables under the bin
directory to your package.json
file under the bin
section. Default: trueMap<string, string>
) Binary programs vended with your module. Optionalstring
) The email address to which issues should be reported. Optionalstring
) The url to your project’s issue tracker. OptionalArray</code>) List of dependencies to bundle into this module. __*Optional*__
[javascript.CodeArtifactOptions](#projen-javascript-codeartifactoptions)
) Options for npm packages using AWS CodeArtifact. Default: undefinedArray</code>) Runtime dependencies of this module. __*Default*__: []
string
) The description is just a string that helps people understand the purpose of the package. OptionalArray</code>) Build dependencies for this module. __*Default*__: []
string
) Module entrypoint (main
in package.json
). Default: “lib/index.js”string
) Package’s Homepage / Website. OptionalArray</code>) Keywords to include in `package.json`. __*Optional*__
string
) License’s SPDX identifier. Default: “Apache-2.0”boolean
) Indicates if a license should be added. Default: truestring
) Minimum node.js version to require via engines
(inclusive). Default: no maxstring
) Minimum Node.js version to require via package.json engines
(inclusive). Default: no “engines” specified[javascript.NpmAccess](#projen-javascript-npmaccess)
) Access level of the npm package. Default: for scoped packages (e.g. foo@bar
), the default is NpmAccess.RESTRICTED
, for non-scoped packages, the default is NpmAccess.PUBLIC
.string
) The host name of the npm registry to publish to. Optionalstring
) The base URL of the npm package registry. Default: “https://registry.npmjs.org”string
) GitHub secret which contains the NPM token to use when publishing packages. Default: “NPM_TOKEN”[javascript.NodePackageManager](#projen-javascript-nodepackagemanager)
) The Node Package Manager used to execute scripts. Default: NodePackageManager.YARNstring
) The “name” in package.json. Default: defaults to project name[javascript.PeerDependencyOptions](#projen-javascript-peerdependencyoptions)
) Options for peerDeps
. OptionalArray</code>) Peer dependencies for this module. __*Default*__: []
string
) The version of PNPM to use if using PNPM as a package manager. Default: “7”string
) The repository is the location where the actual code for your package lives. Optionalstring
) If the package.json for your package is not in the root directory (for example if it is part of a monorepo), you can specify the directory in which it lives. OptionalArray<[javascript.ScopedPackagesOptions](#projen-javascript-scopedpackagesoptions)>
) Options for privately hosted scoped packages. Default: fetch all scoped packages from the public npm registryMap<string, string>
) npm scripts to include. Default: {}string
) Package’s Stability. Optionalstring
) Version requirement of publib
which is used to publish modules to npm. Default: “latest”number
) Major version to release from the default branch. Default: Major version is not enforced.number
) Minimal Major version to release. Default: No minimum version is being enforcedstring
) The npmDistTag to use when publishing from the default branch. Default: “latest”Array<[github.workflows.JobStep](#projen-github-workflows-jobstep)>
) Steps to execute after build as part of the release workflow. Default: []string
) Bump versions from the default branch as pre-releases (e.g. “beta”, “alpha”, “pre”). Default: normal semantic versionsboolean
) Instead of actually publishing to package managers, just print the publishing command. Default: falseboolean
) Define publishing tasks that can be executed manually as well as workflows. Default: falseMap<string, [release.BranchOptions](#projen-release-branchoptions)>
) Defines additional release branches. Default: no additional branches are used for release. you can use addBranch()
to add additional branches.boolean
) Automatically release new versions every commit to one of branches in releaseBranches
. Default: trueboolean
) Create a github issue on every failed publishing task. Default: falsestring
) The label to apply to issues indicating publish failures. Default: “failed-release”string
) CRON schedule to trigger new releases. Default: no scheduled releasesstring
) Automatically add the given prefix to release tags. Useful if you are releasing on multiple branches with overlapping version numbers. Default: “v”[release.ReleaseTrigger](#projen-release-releasetrigger)
) The release trigger to use. Default: Continuous releases (ReleaseTrigger.continuous()
)string
) The name of the default release workflow. Default: “Release”Array<[github.workflows.JobStep](#projen-github-workflows-jobstep)>
) A set of workflow steps to execute in order to setup the workflow container. OptionalMap<string, any>
) Custom configuration used when creating changelog with standard-version package. Default: standard configuration applicable for GitHub repositoriesstring
) Container image to use for GitHub workflows. Default: default imageArray</code>) Github Runner selection labels. __*Default*__: ["ubuntu-latest"]
string
) The name of the main release branch.string
) A directory which will contain build artifacts. Default: “dist”boolean
) Automatically approve deps upgrade PRs, allowing them to be merged by mergify (if configued). Default: trueboolean
) Define a GitHub workflow for building PRs. Default: true if not a subproject[github.workflows.Triggers](#projen-github-workflows-triggers)
) Build workflow triggers. Default: “{ pullRequest: {}, workflowDispatch: {} }”[javascript.BundlerOptions](#projen-javascript-bundleroptions)
) Options for Bundler
. Optionalboolean
) Define a GitHub workflow step for sending code coverage metrics to https://codecov.io/ Uses codecov/codecov-action@v3 A secret is required for private repos. Configured with @codeCovTokenSecret. Default: falsestring
) Define the secret name for a specified https://codecov.io/ token A secret is required to send coverage for private repositories. Default: if this option is not specified, only public repositories are supportedstring
) License copyright owner. Default: defaults to the value of authorName or “” if authorName
is undefined.string
) The copyright years to put in the LICENSE file. Default: current yearboolean
) Use dependabot to handle dependency upgrades. Default: false[github.DependabotOptions](#projen-github-dependabotoptions)
) Options for dependabot. Default: default optionsboolean
) Use github workflows to handle dependency upgrades. Default: true[javascript.UpgradeDependenciesOptions](#projen-javascript-upgradedependenciesoptions)
) Options for UpgradeDependencies
. Default: default optionsArray</code>) Additional entries to .gitignore. __*Optional*__
boolean
) Setup jest unit tests. Default: true[javascript.JestOptions](#projen-javascript-jestoptions)
) Jest options. Default: default optionsboolean
) Automatically update files modified during builds to pull-request branches. Default: trueArray</code>) Additional entries to .npmignore. __*Optional*__
boolean
) Defines an .npmignore file. Normally this is only needed for libraries that are packaged as tarballs. Default: true[IgnoreFileOptions](#projen-ignorefileoptions)
) Configuration options for .npmignore file. Optionalboolean
) Defines a package
task that will produce an npm tarball under the artifacts directory (e.g. dist
). Default: trueboolean
) Setup prettier. Default: false[javascript.PrettierOptions](#projen-javascript-prettieroptions)
) Prettier options. Default: default optionsboolean
) Indicates of “projen” should be installed as a devDependency. Default: trueboolean
) Generate (once) .projenrc.js (in JavaScript). Set to false
in order to disable .projenrc.js generation. Default: true if projenrcJson is false[javascript.ProjenrcOptions](#projen-javascript-projenrcoptions)
) Options for .projenrc.js. Default: default optionsstring
) Version of projen to install. Default: Defaults to the latest version.boolean
) Include a GitHub pull request template. Default: trueArray</code>) The contents of the pull request template. __*Default*__: default content
boolean
) Add release management to this project. Default: true (false for subprojects)boolean
) Automatically release to npm when new versions are introduced. Default: falseboolean
) DEPRECATED: renamed to release
. Default: true if not a subprojectArray<[github.workflows.JobStep](#projen-github-workflows-jobstep)>
) Workflow steps to use in order to bootstrap this repo. Default: “yarn install –frozen-lockfile && yarn projen”[github.GitIdentity](#projen-github-gitidentity)
) The git identity to use in workflows. Default: GitHub Actionsstring
) The node version to use in GitHub workflows. Default: same as minNodeVersion
boolean
) Enable Node.js package cache in GitHub workflows. Default: falseboolean
) Do not generate a tsconfig.json
file (used by jsii projects since tsconfig.json is generated by the jsii compiler). Default: falseboolean
) Do not generate a tsconfig.dev.json
file. Default: falseboolean
) Docgen by Typedoc. Default: falsestring
) Docs directory. Default: “docs”string
) The .d.ts file that includes the type declarations for this module. Default: .d.ts file derived from the project’s entrypoint (usually lib/index.d.ts)boolean
) Setup eslint. Default: true[javascript.EslintOptions](#projen-javascript-eslintoptions)
) Eslint options. Default: opinionated default optionsstring
) Typescript artifacts output directory. Default: “lib”boolean
) Use TypeScript for your projenrc file (.projenrc.ts
). Default: false[typescript.ProjenrcOptions](#projen-typescript-projenrcoptions)
) Options for .projenrc.ts. Optionalboolean
) Generate one-time sample in src/
and test/
if there are no files there. Default: truestring
) Typescript sources directory. Default: “src”string
) Jest tests directory. Tests files should be named xxx.test.ts
. Default: “test”[javascript.TypescriptConfigOptions](#projen-javascript-typescriptconfigoptions)
) Custom TSConfig. Default: default options[javascript.TypescriptConfigOptions](#projen-javascript-typescriptconfigoptions)
) Custom tsconfig options for the development tsconfig.json file (used for testing). Default: use the production tsconfig optionsstring
) The name of the development tsconfig.json file. Default: “tsconfig.dev.json”string
) TypeScript version to use. Default: “latest”string
) A command to execute before synthesis. Default: no build commandstring
) cdk.out directory. Default: “cdk.out”Map<string, any>
) Additional context to include in cdk.json
. Default: no additional contextboolean
) Include all feature flags in cdk.json. Default: true[awscdk.ApprovalLevel](#projen-awscdk-approvallevel)
) To protect you against unintended changes that affect your security posture, the AWS CDK Toolkit prompts you to approve security-related changes before deploying them. Default: ApprovalLevel.BROADENINGArray</code>) Glob patterns to exclude from `cdk watch`. __*Default*__: []
Array</code>) Glob patterns to include in `cdk watch`. __*Default*__: []
string
) Minimum version of the AWS CDK to depend on.boolean
) Warning: NodeJS only. Default: will be included by default for AWS CDK >= 1.0.0 < 2.0.0boolean
) Install the assertions library? Default: will be included by default for AWS CDK >= 1.111.0 < 2.0.0Array</code>) Which AWS CDKv1 modules this project requires. __*Optional*__
boolean
) If this is enabled (default), all modules declared in cdkDependencies
will be also added as normal dependencies
(as well as peerDependencies
). Default: trueArray</code>) AWS CDK modules required for testing. __*Optional*__
boolean
) Use pinned version instead of caret version for CDK. Optionalstring
) Minimum version of the constructs
library to depend on. Default: for CDK 1.x the default is “3.2.27”, for CDK 2.x the default is “10.0.5”.string
) The CDK app’s entrypoint (relative to the source directory, which is “src” by default). Default: “main.ts”boolean
) Automatically adds an cloudfront.experimental.EdgeFunction
for each .edge-lambda.ts
handler in your source tree. If this is disabled, you can manually add an awscdk.AutoDiscover
component to your project. Default: trueboolean
) Automatically discovers and creates integration tests for each .integ.ts
file in under your test directory. Default: trueboolean
) Automatically adds an awscdk.LambdaFunction
for each .lambda.ts
handler in your source tree. If this is disabled, you can manually add an awscdk.AutoDiscover
component to your project. Default: trueboolean
) Automatically adds an awscdk.LambdaExtension
for each .lambda-extension.ts
entrypoint in your source tree. If this is disabled, you can manually add an awscdk.AutoDiscover
component to your project. Default: true[awscdk.LambdaFunctionCommonOptions](#projen-awscdk-lambdafunctioncommonoptions)
) Common options for all AWS Lambda functions. Default: default optionsName | Type | Description |
---|---|---|
appEntrypoint🔹 | string |
The CDK app entrypoint. |
cdkConfig🔹 | [awscdk.CdkConfig](#projen-awscdk-cdkconfig) |
cdk.json configuration. |
cdkDeps🔹 | [awscdk.AwsCdkDeps](#projen-awscdk-awscdkdeps) |
|
cdkTasks🔹 | [awscdk.CdkTasks](#projen-awscdk-cdktasks) |
Common CDK tasks. |
cdkVersion🔹 | string |
The CDK version this app is using. |
Adds an AWS CDK module dependencies.
addCdkDependency(...modules: string[]): void
string
) The list of modules to depend on.Represents cdk.json file.
Submodule: awscdk
Extends: Component
new awscdk.CdkConfig(project: Project, options: CdkConfigOptions)
[Project](#projen-project)
) No description[awscdk.CdkConfigOptions](#projen-awscdk-cdkconfigoptions)
) No description
string
) A command to execute before synthesis. Default: no build commandstring
) cdk.out directory. Default: “cdk.out”Map<string, any>
) Additional context to include in cdk.json
. Default: no additional contextboolean
) Include all feature flags in cdk.json. Default: true[awscdk.ApprovalLevel](#projen-awscdk-approvallevel)
) To protect you against unintended changes that affect your security posture, the AWS CDK Toolkit prompts you to approve security-related changes before deploying them. Default: ApprovalLevel.BROADENINGArray</code>) Glob patterns to exclude from `cdk watch`. __*Default*__: []
Array</code>) Glob patterns to include in `cdk watch`. __*Default*__: []
string
) The command line to execute in order to synthesize the CDK application (language specific).Name | Type | Description |
---|---|---|
cdkout🔹 | string |
Name of the cdk.out directory. |
exclude🔹 | Array |
List of glob patterns to be excluded by CDK. |
include🔹 | Array |
List of glob patterns to be included by CDK. |
json🔹 | [JsonFile](#projen-jsonfile) |
Represents the JSON file. |
Add excludes to cdk.json
.
addExcludes(...patterns: string[]): void
string
) The excludes to add.Add includes to cdk.json
.
addIncludes(...patterns: string[]): void
string
) The includes to add.Adds standard AWS CDK tasks to your project.
Submodule: awscdk
Extends: Component
new awscdk.CdkTasks(project: Project)
[Project](#projen-project)
) No descriptionName | Type | Description |
---|---|---|
deploy🔹 | [Task](#projen-task) |
Deploys your app. |
destroy🔹 | [Task](#projen-task) |
Destroys all the stacks. |
diff🔹 | [Task](#projen-task) |
Diff against production. |
synth🔹 | [Task](#projen-task) |
Synthesizes your app. |
synthSilent🔹 | [Task](#projen-task) |
Synthesizes your app and suppresses stdout. |
watch🔹 | [Task](#projen-task) |
Watch task. |
Submodule: awscdk
Extends: awscdk.AwsCdkConstructLibrary
new awscdk.ConstructLibraryAws(options: AwsCdkConstructLibraryOptions)
[awscdk.AwsCdkConstructLibraryOptions](#projen-awscdk-awscdkconstructlibraryoptions)
) No description
string
) This is the name of your project.boolean
) Whether to commit the managed files by default. Default: true[IgnoreFileOptions](#projen-ignorefileoptions)
) Configuration options for .gitignore file. Optional[GitOptions](#projen-gitoptions)
) Configuration options for git. Optional[LoggerOptions](#projen-loggeroptions)
) Configure logging options such as verbosity. Default: {}string
) The root directory of the project. Default: “.”[Project](#projen-project)
) The parent project, if this project is part of a bigger project. Optionalstring
) The shell command to use in order to run the projen CLI. Default: “npx projen”boolean
) Generate (once) .projenrc.json (in JSON). Set to false
in order to disable .projenrc.json generation. Default: false[ProjenrcJsonOptions](#projen-projenrcjsonoptions)
) Options for .projenrc.json. Default: default optionsboolean
) Use renovatebot to handle dependency upgrades. Default: false[RenovatebotOptions](#projen-renovatebotoptions)
) Options for renovatebot. Default: default options[github.AutoApproveOptions](#projen-github-autoapproveoptions)
) Enable and configure the ‘auto approve’ workflow. Default: auto approve is disabledboolean
) Enable automatic merging on GitHub. Default: true[github.AutoMergeOptions](#projen-github-automergeoptions)
) Configure options for automatic merging on GitHub. Default: see defaults in AutoMergeOptions
boolean
) Add a clobber
task which resets the repo to origin. Default: true, but false for subprojectsboolean
) Add a VSCode development environment (used for GitHub Codespaces). Default: falseboolean
) Enable GitHub integration. Default: true[github.GitHubOptions](#projen-github-githuboptions)
) Options for GitHub integration. Default: see GitHubOptionsboolean
) Add a Gitpod development environment. Default: falseboolean
) Whether mergify should be enabled on this repository or not. Default: true[github.MergifyOptions](#projen-github-mergifyoptions)
) Options for mergify. Default: default options[ProjectType](#projen-projecttype)
) Which type of project this is (library/app). Default: ProjectType.UNKNOWN[github.GithubCredentials](#projen-github-githubcredentials)
) Choose a method of providing GitHub API access for projen workflows. Default: use a personal access token named PROJEN_GITHUB_TOKENstring
) The name of a secret which includes a GitHub Personal Access Token to be used by projen workflows. Default: “PROJEN_GITHUB_TOKEN”[SampleReadmeProps](#projen-samplereadmeprops)
) The README setup. Default: { filename: ‘README.md’, contents: ‘# replace this’ }boolean
) Auto-close of stale issues and pull request. Default: false[github.StaleOptions](#projen-github-staleoptions)
) Auto-close stale issues and pull requests. Default: see defaults in StaleOptions
boolean
) Enable VSCode integration. Default: trueboolean
) Allow the project to include peerDependencies
and bundledDependencies
. Default: truestring
) Author’s e-mail. Optionalstring
) Author’s name. Optionalboolean
) Is the author an organization. Optionalstring
) Author’s URL / Website. Optionalboolean
) Automatically add all executables under the bin
directory to your package.json
file under the bin
section. Default: trueMap<string, string>
) Binary programs vended with your module. Optionalstring
) The email address to which issues should be reported. Optionalstring
) The url to your project’s issue tracker. OptionalArray</code>) List of dependencies to bundle into this module. __*Optional*__
[javascript.CodeArtifactOptions](#projen-javascript-codeartifactoptions)
) Options for npm packages using AWS CodeArtifact. Default: undefinedArray</code>) Runtime dependencies of this module. __*Default*__: []
string
) The description is just a string that helps people understand the purpose of the package. OptionalArray</code>) Build dependencies for this module. __*Default*__: []
string
) Module entrypoint (main
in package.json
). Default: “lib/index.js”string
) Package’s Homepage / Website. OptionalArray</code>) Keywords to include in `package.json`. __*Optional*__
string
) License’s SPDX identifier. Default: “Apache-2.0”boolean
) Indicates if a license should be added. Default: truestring
) Minimum node.js version to require via engines
(inclusive). Default: no maxstring
) Minimum Node.js version to require via package.json engines
(inclusive). Default: no “engines” specified[javascript.NpmAccess](#projen-javascript-npmaccess)
) Access level of the npm package. Default: for scoped packages (e.g. foo@bar
), the default is NpmAccess.RESTRICTED
, for non-scoped packages, the default is NpmAccess.PUBLIC
.string
) The host name of the npm registry to publish to. Optionalstring
) The base URL of the npm package registry. Default: “https://registry.npmjs.org”string
) GitHub secret which contains the NPM token to use when publishing packages. Default: “NPM_TOKEN”[javascript.NodePackageManager](#projen-javascript-nodepackagemanager)
) The Node Package Manager used to execute scripts. Default: NodePackageManager.YARNstring
) The “name” in package.json. Default: defaults to project name[javascript.PeerDependencyOptions](#projen-javascript-peerdependencyoptions)
) Options for peerDeps
. OptionalArray</code>) Peer dependencies for this module. __*Default*__: []
string
) The version of PNPM to use if using PNPM as a package manager. Default: “7”string
) The repository is the location where the actual code for your package lives. Optionalstring
) If the package.json for your package is not in the root directory (for example if it is part of a monorepo), you can specify the directory in which it lives. OptionalArray<[javascript.ScopedPackagesOptions](#projen-javascript-scopedpackagesoptions)>
) Options for privately hosted scoped packages. Default: fetch all scoped packages from the public npm registryMap<string, string>
) npm scripts to include. Default: {}string
) Package’s Stability. Optionalstring
) Version requirement of publib
which is used to publish modules to npm. Default: “latest”number
) Major version to release from the default branch. Default: Major version is not enforced.number
) Minimal Major version to release. Default: No minimum version is being enforcedstring
) The npmDistTag to use when publishing from the default branch. Default: “latest”Array<[github.workflows.JobStep](#projen-github-workflows-jobstep)>
) Steps to execute after build as part of the release workflow. Default: []string
) Bump versions from the default branch as pre-releases (e.g. “beta”, “alpha”, “pre”). Default: normal semantic versionsboolean
) Instead of actually publishing to package managers, just print the publishing command. Default: falseboolean
) Define publishing tasks that can be executed manually as well as workflows. Default: falseMap<string, [release.BranchOptions](#projen-release-branchoptions)>
) Defines additional release branches. Default: no additional branches are used for release. you can use addBranch()
to add additional branches.boolean
) Automatically release new versions every commit to one of branches in releaseBranches
. Default: trueboolean
) Create a github issue on every failed publishing task. Default: falsestring
) The label to apply to issues indicating publish failures. Default: “failed-release”string
) CRON schedule to trigger new releases. Default: no scheduled releasesstring
) Automatically add the given prefix to release tags. Useful if you are releasing on multiple branches with overlapping version numbers. Default: “v”[release.ReleaseTrigger](#projen-release-releasetrigger)
) The release trigger to use. Default: Continuous releases (ReleaseTrigger.continuous()
)string
) The name of the default release workflow. Default: “Release”Array<[github.workflows.JobStep](#projen-github-workflows-jobstep)>
) A set of workflow steps to execute in order to setup the workflow container. OptionalMap<string, any>
) Custom configuration used when creating changelog with standard-version package. Default: standard configuration applicable for GitHub repositoriesstring
) Container image to use for GitHub workflows. Default: default imageArray</code>) Github Runner selection labels. __*Default*__: ["ubuntu-latest"]
string
) The name of the main release branch.string
) A directory which will contain build artifacts. Default: “dist”boolean
) Automatically approve deps upgrade PRs, allowing them to be merged by mergify (if configued). Default: trueboolean
) Define a GitHub workflow for building PRs. Default: true if not a subproject[github.workflows.Triggers](#projen-github-workflows-triggers)
) Build workflow triggers. Default: “{ pullRequest: {}, workflowDispatch: {} }”[javascript.BundlerOptions](#projen-javascript-bundleroptions)
) Options for Bundler
. Optionalboolean
) Define a GitHub workflow step for sending code coverage metrics to https://codecov.io/ Uses codecov/codecov-action@v3 A secret is required for private repos. Configured with @codeCovTokenSecret. Default: falsestring
) Define the secret name for a specified https://codecov.io/ token A secret is required to send coverage for private repositories. Default: if this option is not specified, only public repositories are supportedstring
) License copyright owner. Default: defaults to the value of authorName or “” if authorName
is undefined.string
) The copyright years to put in the LICENSE file. Default: current yearboolean
) Use dependabot to handle dependency upgrades. Default: false[github.DependabotOptions](#projen-github-dependabotoptions)
) Options for dependabot. Default: default optionsboolean
) Use github workflows to handle dependency upgrades. Default: true[javascript.UpgradeDependenciesOptions](#projen-javascript-upgradedependenciesoptions)
) Options for UpgradeDependencies
. Default: default optionsArray</code>) Additional entries to .gitignore. __*Optional*__
boolean
) Setup jest unit tests. Default: true[javascript.JestOptions](#projen-javascript-jestoptions)
) Jest options. Default: default optionsboolean
) Automatically update files modified during builds to pull-request branches. Default: trueArray</code>) Additional entries to .npmignore. __*Optional*__
boolean
) Defines an .npmignore file. Normally this is only needed for libraries that are packaged as tarballs. Default: true[IgnoreFileOptions](#projen-ignorefileoptions)
) Configuration options for .npmignore file. Optionalboolean
) Defines a package
task that will produce an npm tarball under the artifacts directory (e.g. dist
). Default: trueboolean
) Setup prettier. Default: false[javascript.PrettierOptions](#projen-javascript-prettieroptions)
) Prettier options. Default: default optionsboolean
) Indicates of “projen” should be installed as a devDependency. Default: trueboolean
) Generate (once) .projenrc.js (in JavaScript). Set to false
in order to disable .projenrc.js generation. Default: true if projenrcJson is false[javascript.ProjenrcOptions](#projen-javascript-projenrcoptions)
) Options for .projenrc.js. Default: default optionsstring
) Version of projen to install. Default: Defaults to the latest version.boolean
) Include a GitHub pull request template. Default: trueArray</code>) The contents of the pull request template. __*Default*__: default content
boolean
) Add release management to this project. Default: true (false for subprojects)boolean
) Automatically release to npm when new versions are introduced. Default: falseboolean
) DEPRECATED: renamed to release
. Default: true if not a subprojectArray<[github.workflows.JobStep](#projen-github-workflows-jobstep)>
) Workflow steps to use in order to bootstrap this repo. Default: “yarn install –frozen-lockfile && yarn projen”[github.GitIdentity](#projen-github-gitidentity)
) The git identity to use in workflows. Default: GitHub Actionsstring
) The node version to use in GitHub workflows. Default: same as minNodeVersion
boolean
) Enable Node.js package cache in GitHub workflows. Default: falseboolean
) Do not generate a tsconfig.json
file (used by jsii projects since tsconfig.json is generated by the jsii compiler). Default: falseboolean
) Do not generate a tsconfig.dev.json
file. Default: falseboolean
) Docgen by Typedoc. Default: falsestring
) Docs directory. Default: “docs”string
) The .d.ts file that includes the type declarations for this module. Default: .d.ts file derived from the project’s entrypoint (usually lib/index.d.ts)boolean
) Setup eslint. Default: true[javascript.EslintOptions](#projen-javascript-eslintoptions)
) Eslint options. Default: opinionated default optionsstring
) Typescript artifacts output directory. Default: “lib”boolean
) Use TypeScript for your projenrc file (.projenrc.ts
). Default: false[typescript.ProjenrcOptions](#projen-typescript-projenrcoptions)
) Options for .projenrc.ts. Optionalboolean
) Generate one-time sample in src/
and test/
if there are no files there. Default: truestring
) Typescript sources directory. Default: “src”string
) Jest tests directory. Tests files should be named xxx.test.ts
. Default: “test”[javascript.TypescriptConfigOptions](#projen-javascript-typescriptconfigoptions)
) Custom TSConfig. Default: default options[javascript.TypescriptConfigOptions](#projen-javascript-typescriptconfigoptions)
) Custom tsconfig options for the development tsconfig.json file (used for testing). Default: use the production tsconfig optionsstring
) The name of the development tsconfig.json file. Default: “tsconfig.dev.json”string
) TypeScript version to use. Default: “latest”string
) The name of the library author.string
) Email or URL of the library author.string
) Git repository URL.boolean
) Automatically run API compatibility test against the latest version published to npm after compilation. Default: falsestring
) Name of the ignore file for API compatibility tests. Default: “.compatignore”boolean
) Emit a compressed version of the assembly. Default: falsestring
) File path for generated docs. Default: “API.md”[cdk.JsiiDotNetTarget](#projen-cdk-jsiidotnettarget)
) No description OptionalArray</code>) Accepts a list of glob patterns. __*Optional*__
string
) Version of the jsii compiler to use. Default: “1.x”[cdk.JsiiGoTarget](#projen-cdk-jsiigotarget)
) Publish Go bindings to a git repository. Default: no publishing[cdk.JsiiJavaTarget](#projen-cdk-jsiijavatarget)
) Publish to maven. Default: no publishing[cdk.JsiiDotNetTarget](#projen-cdk-jsiidotnettarget)
) Publish to NuGet. Default: no publishing[cdk.JsiiPythonTarget](#projen-cdk-jsiipythontarget)
) Publish to pypi. Default: no publishing[cdk.JsiiPythonTarget](#projen-cdk-jsiipythontarget)
) No description Optionalstring
) No description Default: “.”[cdk.Catalog](#projen-cdk-catalog)
) Libraries will be picked up by the construct catalog when they are published to npm as jsii modules and will be published under:. Default: new version will be announcedstring
) Minimum version of the AWS CDK to depend on.boolean
) Warning: NodeJS only. Default: will be included by default for AWS CDK >= 1.0.0 < 2.0.0boolean
) Install the assertions library? Default: will be included by default for AWS CDK >= 1.111.0 < 2.0.0Array</code>) Which AWS CDKv1 modules this project requires. __*Optional*__
boolean
) If this is enabled (default), all modules declared in cdkDependencies
will be also added as normal dependencies
(as well as peerDependencies
). Default: trueArray</code>) AWS CDK modules required for testing. __*Optional*__
boolean
) Use pinned version instead of caret version for CDK. Optionalstring
) Minimum version of the constructs
library to depend on. Default: for CDK 1.x the default is “3.2.27”, for CDK 2.x the default is “10.0.5”.boolean
) Automatically adds an cloudfront.experimental.EdgeFunction
for each .edge-lambda.ts
handler in your source tree. If this is disabled, you can manually add an awscdk.AutoDiscover
component to your project. Default: trueboolean
) Automatically discovers and creates integration tests for each .integ.ts
file in under your test directory. Default: trueboolean
) Automatically adds an aws_lambda.Function
for each .lambda.ts
handler in your source tree. If this is disabled, you either need to explicitly call aws_lambda.Function.autoDiscover()
or define a new aws_lambda.Function()
for each handler. Default: trueboolean
) Automatically adds an awscdk.LambdaExtension
for each .lambda-extension.ts
entrypoint in your source tree. If this is disabled, you can manually add an awscdk.AutoDiscover
component to your project. Default: true[awscdk.LambdaFunctionCommonOptions](#projen-awscdk-lambdafunctioncommonoptions)
) Common options for all AWS Lambda functions. Default: default optionsCreates edge lambdas from entry points discovered in the project’s source tree.
Submodule: awscdk
Extends: cdk.AutoDiscoverBase
new awscdk.EdgeLambdaAutoDiscover(project: Project, options: EdgeLambdaAutoDiscoverOptions)
[Project](#projen-project)
) No description[awscdk.EdgeLambdaAutoDiscoverOptions](#projen-awscdk-edgelambdaautodiscoveroptions)
) No description
[awscdk.AwsCdkDeps](#projen-awscdk-awscdkdeps)
) AWS CDK dependency manager.string
) Path to the tsconfig file to use for integration tests.string
) Project source tree (relative to project output directory).[awscdk.LambdaFunctionCommonOptions](#projen-awscdk-lambdafunctioncommonoptions)
) Options for AWS Lambda functions. OptionalCloud integration tests.
Submodule: awscdk
Extends: cdk.IntegrationTestBase
new awscdk.IntegrationTest(project: Project, options: IntegrationTestOptions)
[Project](#projen-project)
) No description[awscdk.IntegrationTestOptions](#projen-awscdk-integrationtestoptions)
) No description
boolean
) Destroy the test app after a successful deployment. Default: trueboolean
) Enables path metadata, adding aws:cdk:path
, with the defining construct’s path, to the CloudFormation metadata for each synthesized resource. Default: falsestring
) A path from the project root directory to a TypeScript file which contains the integration test app.string
) The path of the tsconfig.json file to use when running integration test cdk apps.string
) Name of the integration test. Default: Derived from the entrypoint filename.[awscdk.AwsCdkDeps](#projen-awscdk-awscdkdeps)
) AWS CDK dependency manager.Array</code>) A list of stacks within the integration test to deploy/destroy. __*Default*__: ["**"]
Name | Type | Description |
---|---|---|
destroyTask🔹 | [Task](#projen-task) |
Destroy the integration test resources. |
watchTask🔹 | [Task](#projen-task) |
The watch task. |
Creates integration tests from entry points discovered in the test tree.
Submodule: awscdk
Extends: cdk.IntegrationTestAutoDiscoverBase
new awscdk.IntegrationTestAutoDiscover(project: Project, options: IntegrationTestAutoDiscoverOptions)
[Project](#projen-project)
) No description[awscdk.IntegrationTestAutoDiscoverOptions](#projen-awscdk-integrationtestautodiscoveroptions)
) No description
[awscdk.AwsCdkDeps](#projen-awscdk-awscdkdeps)
) AWS CDK dependency manager.string
) Path to the tsconfig file to use for integration tests.string
) Test source tree.[awscdk.IntegrationTestCommonOptions](#projen-awscdk-integrationtestcommonoptions)
) Options for integration tests. OptionalCreates lambdas from entry points discovered in the project’s source tree.
Submodule: awscdk
Extends: cdk.AutoDiscoverBase
new awscdk.LambdaAutoDiscover(project: Project, options: LambdaAutoDiscoverOptions)
[Project](#projen-project)
) No description[awscdk.LambdaAutoDiscoverOptions](#projen-awscdk-lambdaautodiscoveroptions)
) No description
[awscdk.AwsCdkDeps](#projen-awscdk-awscdkdeps)
) AWS CDK dependency manager.string
) Path to the tsconfig file to use for integration tests.string
) Project source tree (relative to project output directory).[awscdk.LambdaFunctionCommonOptions](#projen-awscdk-lambdafunctioncommonoptions)
) Options for AWS Lambda functions. OptionalCreate a Lambda Extension.
Submodule: awscdk
Extends: Component
new awscdk.LambdaExtension(project: Project, options: LambdaExtensionOptions)
[Project](#projen-project)
) No description[awscdk.LambdaExtensionOptions](#projen-awscdk-lambdaextensionoptions)
) No description
[javascript.BundlingOptions](#projen-javascript-bundlingoptions)
) Bundling options for this AWS Lambda extension. Default: defaultsArray<[awscdk.LambdaRuntime](#projen-awscdk-lambdaruntime)>
) The extension’s compatible runtimes. Optional[awscdk.AwsCdkDeps](#projen-awscdk-awscdkdeps)
) AWS CDK dependency manager.string
) A path from the project root directory to a TypeScript file which contains the AWS Lambda extension entrypoint (stand-alone script).string
) The name of the generated TypeScript source file. Default: The name of the entrypoint file, with the -layer-version.ts
suffix instead of .lambda-extension.ts
.string
) The name of the generated lambda.LayerVersion
subclass. Default: A pascal cased version of the name of the entrypoint file, with the extension LayerVersion
(e.g. AppConfigLayerVersion
).string
) Name of the extension. Default: Derived from the entrypoint filename.Creates Lambda Extensions from entrypoints discovered in the project’s source tree.
Submodule: awscdk
Extends: cdk.AutoDiscoverBase
new awscdk.LambdaExtensionAutoDiscover(project: Project, options: LambdaExtensionAutoDiscoverOptions)
[Project](#projen-project)
) No description[awscdk.LambdaExtensionAutoDiscoverOptions](#projen-awscdk-lambdaextensionautodiscoveroptions)
) No description
[awscdk.AwsCdkDeps](#projen-awscdk-awscdkdeps)
) AWS CDK dependency manager.string
) Path to the tsconfig file to use for integration tests.string
) Project source tree (relative to project output directory).[awscdk.LambdaExtensionCommonOptions](#projen-awscdk-lambdaextensioncommonoptions)
) Options for lambda extensions. OptionalGenerates a pre-bundled AWS Lambda function construct from handler code.
To use this, create an AWS Lambda handler file under your source tree with
the .lambda.ts
extension and add a LambdaFunction
component to your
typescript project pointing to this entrypoint.
This will add a task to your “compile” step which will use esbuild
to
bundle the handler code into the build directory. It will also generate a
file src/foo-function.ts
with a custom AWS construct called FooFunction
which extends @aws-cdk/aws-lambda.Function
which is bound to the bundled
handle through an asset.
Submodule: awscdk
Extends: Component
Defines a pre-bundled AWS Lambda function construct from handler code.
new awscdk.LambdaFunction(project: Project, options: LambdaFunctionOptions)
[Project](#projen-project)
) The project to use.[awscdk.LambdaFunctionOptions](#projen-awscdk-lambdafunctionoptions)
) Options.
boolean
) Whether to automatically reuse TCP connections when working with the AWS SDK for JavaScript. Default: true[javascript.BundlingOptions](#projen-javascript-bundlingoptions)
) Bundling options for this AWS Lambda function. Default: defaultsboolean
) Whether to create a cloudfront.experimental.EdgeFunction
instead of a lambda.Function
. Default: false[awscdk.LambdaRuntime](#projen-awscdk-lambdaruntime)
) The node.js version to target. Default: Runtime.NODEJS_16_X[awscdk.AwsCdkDeps](#projen-awscdk-awscdkdeps)
) AWS CDK dependency manager.string
) A path from the project root directory to a TypeScript file which contains the AWS Lambda handler entrypoint (exports a handler
function).string
) The name of the generated TypeScript source file. Default: The name of the entrypoint file, with the -function.ts
suffix instead of .lambda.ts
.string
) The name of the generated lambda.Function
subclass. Default: A pascal cased version of the name of the entrypoint file, with the extension Function
(e.g. ResizeImageFunction
).The runtime for the AWS Lambda function.
Submodule: awscdk
new awscdk.LambdaRuntime(functionRuntime: string, esbuildTarget: string, options?: LambdaRuntimeOptions)
string
) The Node.js runtime to use.string
) The esbuild setting to use.[awscdk.LambdaRuntimeOptions](#projen-awscdk-lambdaruntimeoptions)
) Options for this runtime.
Array</code>) Packages that are considered externals by default when bundling. __*Default*__: ['@aws-sdk/*']
Name | Type | Description |
---|---|---|
defaultExternals🔹 | Array |
|
esbuildPlatform🔹 | string |
|
esbuildTarget🔹 | string |
The esbuild setting to use. |
functionRuntime🔹 | string |
The Node.js runtime to use. |
static NODEJS_10_X⚠️ | [awscdk.LambdaRuntime](#projen-awscdk-lambdaruntime) |
Node.js 10.x. |
static NODEJS_12_X⚠️ | [awscdk.LambdaRuntime](#projen-awscdk-lambdaruntime) |
Node.js 12.x. |
static NODEJS_14_X⚠️ | [awscdk.LambdaRuntime](#projen-awscdk-lambdaruntime) |
Node.js 14.x. |
static NODEJS_16_X🔹 | [awscdk.LambdaRuntime](#projen-awscdk-lambdaruntime) |
Node.js 16.x. |
static NODEJS_18_X🔹 | [awscdk.LambdaRuntime](#projen-awscdk-lambdaruntime) |
Node.js 18.x. |
Submodule: build
Extends: Component
new build.BuildWorkflow(project: Project, options: BuildWorkflowOptions)
[Project](#projen-project)
) No description[build.BuildWorkflowOptions](#projen-build-buildworkflowoptions)
) No description
string
) A name of a directory that includes build artifacts.[Task](#projen-task)
) The task to execute in order to build the project.string
) The container image to use for builds. Default: the default workflow containerMap<string, string>
) Build environment variables. Default: {}[github.GitIdentity](#projen-github-gitidentity)
) Git identity to use for the workflow. Default: default identityboolean
) Automatically update files modified during builds to pull-request branches. Default: true[github.workflows.JobPermissions](#projen-github-workflows-jobpermissions)
) Permissions granted to the build job To limit job permissions for contents
, the desired permissions have to be explicitly set, e.g.: { contents: JobPermission.NONE }
. Default: { contents: JobPermission.WRITE }
Array<[github.workflows.JobStep](#projen-github-workflows-jobstep)>
) Steps to execute after build. Default: []Array<[github.workflows.JobStep](#projen-github-workflows-jobstep)>
) Steps to execute before the build. Default: []Array</code>) Github Runner selection labels. __*Default*__: ["ubuntu-latest"]
[github.workflows.Triggers](#projen-github-workflows-triggers)
) Build workflow triggers. Default: “{ pullRequest: {}, workflowDispatch: {} }”Name | Type | Description |
---|---|---|
buildJobIds🔹 | Array |
Returns a list of job IDs that are part of the build. |
Adds another job to the build workflow which is executed after the build job succeeded.
Jobs are executed only if the build did NOT self mutate. If the build self-mutate, the branch will either be updated or the build will fail (in forks), so there is no point in executing the post-build job.
addPostBuildJob(id: string, job: Job): void
string
) The id of the new job.[github.workflows.Job](#projen-github-workflows-job)
) The job specification.
[github.workflows.JobPermissions](#projen-github-workflows-jobpermissions)
) You can modify the default permissions granted to the GITHUB_TOKEN, adding or removing access as required, so that you only allow the minimum required access.any
) Concurrency ensures that only a single job or workflow using the same concurrency group will run at a time. Optionalstring
) You can use the if conditional to prevent a job from running unless a condition is met. Optionalstring
) The name of the job displayed on GitHub. OptionalArray</code>) Identifies any jobs that must complete successfully before this job will run. __*Optional*__
[github.workflows.JobStrategy](#projen-github-workflows-jobstrategy)
) A strategy creates a build matrix for your jobs. OptionalArray</code>) The type of machine to run the job on.
Array<[github.workflows.JobStep](#projen-github-workflows-jobstep)>
) A job contains a sequence of tasks called steps.[github.workflows.ContainerOptions](#projen-github-workflows-containeroptions)
) A container to run any steps in a job that don’t already specify a container. Optionalboolean
) Prevents a workflow run from failing when a job fails. Optional[github.workflows.JobDefaults](#projen-github-workflows-jobdefaults)
) A map of default settings that will apply to all steps in the job. OptionalMap<string, string>
) A map of environment variables that are available to all steps in the job. Optionalany
) The environment that the job references. OptionalMap<string, [github.workflows.JobStepOutput](#projen-github-workflows-jobstepoutput)>
) A map of outputs for a job. OptionalMap<string, [github.workflows.ContainerOptions](#projen-github-workflows-containeroptions)>
) Used to host service containers for a job in a workflow. Optionalnumber
) The maximum number of minutes to let a job run before GitHub automatically cancels it. Default: 360[github.workflows.Tools](#projen-github-workflows-tools)
) Tools required for this job. OptionalRun a sequence of commands as a job within the build workflow which is executed after the build job succeeded.
Jobs are executed only if the build did NOT self mutate. If the build self-mutate, the branch will either be updated or the build will fail (in forks), so there is no point in executing the post-build job.
addPostBuildJobCommands(id: string, commands: Array<string>, options?: AddPostBuildJobCommandsOptions): void
string
) No descriptionArray</code>) *No description*
[build.AddPostBuildJobCommandsOptions](#projen-build-addpostbuildjobcommandsoptions)
) Specify tools and other options.
boolean
) Check out the repository at the pull request branch before commands are run. Default: falseboolean
) Install project dependencies before running commands. checkoutRepo
must also be set to true. Default: falseArray</code>) Github Runner selection labels. __*Default*__: ["ubuntu-latest"]
[github.workflows.Tools](#projen-github-workflows-tools)
) Tools that should be installed before the commands are run. OptionalRun a task as a job within the build workflow which is executed after the build job succeeded.
The job will have access to build artifacts and will install project dependencies in order to be able to run any commands used in the tasks.
Jobs are executed only if the build did NOT self mutate. If the build self-mutate, the branch will either be updated or the build will fail (in forks), so there is no point in executing the post-build job.
addPostBuildJobTask(task: Task, options?: AddPostBuildJobTaskOptions): void
[Task](#projen-task)
) No description[build.AddPostBuildJobTaskOptions](#projen-build-addpostbuildjobtaskoptions)
) Specify tools and other options.
Array</code>) Github Runner selection labels. __*Default*__: ["ubuntu-latest"]
[github.workflows.Tools](#projen-github-workflows-tools)
) Tools that should be installed before the task is run. OptionalAdds steps that are executed after the build.
addPostBuildSteps(...steps: JobStep[]): void
[github.workflows.JobStep](#projen-github-workflows-jobstep)
) The job steps.
Map<string, string>
) Sets environment variables for steps to use in the runner environment. Optionalstring
) A unique identifier for the step. Optionalstring
) You can use the if conditional to prevent a job from running unless a condition is met. Optionalstring
) A name for your step to display on GitHub. Optionalstring
) Runs command-line programs using the operating system’s shell. Optionalstring
) Selects an action to run as part of a step in your job. OptionalMap<string, any>
) A map of the input parameters defined by the action. Optionalstring
) Specifies a working directory for a step. Optionalboolean
) Prevents a job from failing when a step fails. Optionalnumber
) The maximum number of minutes to run the step before killing the process. OptionalBase class for auto-discovering and creating project subcomponents.
Submodule: cdk
Extends: Component Implemented by: awscdk.EdgeLambdaAutoDiscover, awscdk.IntegrationTestAutoDiscover, awscdk.LambdaAutoDiscover, awscdk.LambdaExtensionAutoDiscover, cdk.IntegrationTestAutoDiscoverBase, cdk8s.IntegrationTestAutoDiscover
new cdk.AutoDiscoverBase(project: Project, options: AutoDiscoverBaseOptions)
[Project](#projen-project)
) No description[cdk.AutoDiscoverBaseOptions](#projen-cdk-autodiscoverbaseoptions)
) No description
string
) Locate files with the given extension.string
) Locate entrypoints in the given project directory.Name | Type | Description |
---|---|---|
entrypoints🔹 | Array |
Auto-discovered entry points with paths relative to the project directory. |
A multi-language library for CDK constructs.
Submodule: cdk
Extends: cdk.JsiiProject Implemented by: awscdk.AwsCdkConstructLibrary, awscdk.ConstructLibraryAws, cdk8s.ConstructLibraryCdk8s, cdktf.ConstructLibraryCdktf
new cdk.ConstructLibrary(options: ConstructLibraryOptions)
[cdk.ConstructLibraryOptions](#projen-cdk-constructlibraryoptions)
) No description
string
) This is the name of your project.boolean
) Whether to commit the managed files by default. Default: true[IgnoreFileOptions](#projen-ignorefileoptions)
) Configuration options for .gitignore file. Optional[GitOptions](#projen-gitoptions)
) Configuration options for git. Optional[LoggerOptions](#projen-loggeroptions)
) Configure logging options such as verbosity. Default: {}string
) The root directory of the project. Default: “.”[Project](#projen-project)
) The parent project, if this project is part of a bigger project. Optionalstring
) The shell command to use in order to run the projen CLI. Default: “npx projen”boolean
) Generate (once) .projenrc.json (in JSON). Set to false
in order to disable .projenrc.json generation. Default: false[ProjenrcJsonOptions](#projen-projenrcjsonoptions)
) Options for .projenrc.json. Default: default optionsboolean
) Use renovatebot to handle dependency upgrades. Default: false[RenovatebotOptions](#projen-renovatebotoptions)
) Options for renovatebot. Default: default options[github.AutoApproveOptions](#projen-github-autoapproveoptions)
) Enable and configure the ‘auto approve’ workflow. Default: auto approve is disabledboolean
) Enable automatic merging on GitHub. Default: true[github.AutoMergeOptions](#projen-github-automergeoptions)
) Configure options for automatic merging on GitHub. Default: see defaults in AutoMergeOptions
boolean
) Add a clobber
task which resets the repo to origin. Default: true, but false for subprojectsboolean
) Add a VSCode development environment (used for GitHub Codespaces). Default: falseboolean
) Enable GitHub integration. Default: true[github.GitHubOptions](#projen-github-githuboptions)
) Options for GitHub integration. Default: see GitHubOptionsboolean
) Add a Gitpod development environment. Default: falseboolean
) Whether mergify should be enabled on this repository or not. Default: true[github.MergifyOptions](#projen-github-mergifyoptions)
) Options for mergify. Default: default options[ProjectType](#projen-projecttype)
) Which type of project this is (library/app). Default: ProjectType.UNKNOWN[github.GithubCredentials](#projen-github-githubcredentials)
) Choose a method of providing GitHub API access for projen workflows. Default: use a personal access token named PROJEN_GITHUB_TOKENstring
) The name of a secret which includes a GitHub Personal Access Token to be used by projen workflows. Default: “PROJEN_GITHUB_TOKEN”[SampleReadmeProps](#projen-samplereadmeprops)
) The README setup. Default: { filename: ‘README.md’, contents: ‘# replace this’ }boolean
) Auto-close of stale issues and pull request. Default: false[github.StaleOptions](#projen-github-staleoptions)
) Auto-close stale issues and pull requests. Default: see defaults in StaleOptions
boolean
) Enable VSCode integration. Default: trueboolean
) Allow the project to include peerDependencies
and bundledDependencies
. Default: truestring
) Author’s e-mail. Optionalstring
) Author’s name. Optionalboolean
) Is the author an organization. Optionalstring
) Author’s URL / Website. Optionalboolean
) Automatically add all executables under the bin
directory to your package.json
file under the bin
section. Default: trueMap<string, string>
) Binary programs vended with your module. Optionalstring
) The email address to which issues should be reported. Optionalstring
) The url to your project’s issue tracker. OptionalArray</code>) List of dependencies to bundle into this module. __*Optional*__
[javascript.CodeArtifactOptions](#projen-javascript-codeartifactoptions)
) Options for npm packages using AWS CodeArtifact. Default: undefinedArray</code>) Runtime dependencies of this module. __*Default*__: []
string
) The description is just a string that helps people understand the purpose of the package. OptionalArray</code>) Build dependencies for this module. __*Default*__: []
string
) Module entrypoint (main
in package.json
). Default: “lib/index.js”string
) Package’s Homepage / Website. OptionalArray</code>) Keywords to include in `package.json`. __*Optional*__
string
) License’s SPDX identifier. Default: “Apache-2.0”boolean
) Indicates if a license should be added. Default: truestring
) Minimum node.js version to require via engines
(inclusive). Default: no maxstring
) Minimum Node.js version to require via package.json engines
(inclusive). Default: no “engines” specified[javascript.NpmAccess](#projen-javascript-npmaccess)
) Access level of the npm package. Default: for scoped packages (e.g. foo@bar
), the default is NpmAccess.RESTRICTED
, for non-scoped packages, the default is NpmAccess.PUBLIC
.string
) The host name of the npm registry to publish to. Optionalstring
) The base URL of the npm package registry. Default: “https://registry.npmjs.org”string
) GitHub secret which contains the NPM token to use when publishing packages. Default: “NPM_TOKEN”[javascript.NodePackageManager](#projen-javascript-nodepackagemanager)
) The Node Package Manager used to execute scripts. Default: NodePackageManager.YARNstring
) The “name” in package.json. Default: defaults to project name[javascript.PeerDependencyOptions](#projen-javascript-peerdependencyoptions)
) Options for peerDeps
. OptionalArray</code>) Peer dependencies for this module. __*Default*__: []
string
) The version of PNPM to use if using PNPM as a package manager. Default: “7”string
) The repository is the location where the actual code for your package lives. Optionalstring
) If the package.json for your package is not in the root directory (for example if it is part of a monorepo), you can specify the directory in which it lives. OptionalArray<[javascript.ScopedPackagesOptions](#projen-javascript-scopedpackagesoptions)>
) Options for privately hosted scoped packages. Default: fetch all scoped packages from the public npm registryMap<string, string>
) npm scripts to include. Default: {}string
) Package’s Stability. Optionalstring
) Version requirement of publib
which is used to publish modules to npm. Default: “latest”number
) Major version to release from the default branch. Default: Major version is not enforced.number
) Minimal Major version to release. Default: No minimum version is being enforcedstring
) The npmDistTag to use when publishing from the default branch. Default: “latest”Array<[github.workflows.JobStep](#projen-github-workflows-jobstep)>
) Steps to execute after build as part of the release workflow. Default: []string
) Bump versions from the default branch as pre-releases (e.g. “beta”, “alpha”, “pre”). Default: normal semantic versionsboolean
) Instead of actually publishing to package managers, just print the publishing command. Default: falseboolean
) Define publishing tasks that can be executed manually as well as workflows. Default: falseMap<string, [release.BranchOptions](#projen-release-branchoptions)>
) Defines additional release branches. Default: no additional branches are used for release. you can use addBranch()
to add additional branches.boolean
) Automatically release new versions every commit to one of branches in releaseBranches
. Default: trueboolean
) Create a github issue on every failed publishing task. Default: falsestring
) The label to apply to issues indicating publish failures. Default: “failed-release”string
) CRON schedule to trigger new releases. Default: no scheduled releasesstring
) Automatically add the given prefix to release tags. Useful if you are releasing on multiple branches with overlapping version numbers. Default: “v”[release.ReleaseTrigger](#projen-release-releasetrigger)
) The release trigger to use. Default: Continuous releases (ReleaseTrigger.continuous()
)string
) The name of the default release workflow. Default: “Release”Array<[github.workflows.JobStep](#projen-github-workflows-jobstep)>
) A set of workflow steps to execute in order to setup the workflow container. OptionalMap<string, any>
) Custom configuration used when creating changelog with standard-version package. Default: standard configuration applicable for GitHub repositoriesstring
) Container image to use for GitHub workflows. Default: default imageArray</code>) Github Runner selection labels. __*Default*__: ["ubuntu-latest"]
string
) The name of the main release branch.string
) A directory which will contain build artifacts. Default: “dist”boolean
) Automatically approve deps upgrade PRs, allowing them to be merged by mergify (if configued). Default: trueboolean
) Define a GitHub workflow for building PRs. Default: true if not a subproject[github.workflows.Triggers](#projen-github-workflows-triggers)
) Build workflow triggers. Default: “{ pullRequest: {}, workflowDispatch: {} }”[javascript.BundlerOptions](#projen-javascript-bundleroptions)
) Options for Bundler
. Optionalboolean
) Define a GitHub workflow step for sending code coverage metrics to https://codecov.io/ Uses codecov/codecov-action@v3 A secret is required for private repos. Configured with @codeCovTokenSecret. Default: falsestring
) Define the secret name for a specified https://codecov.io/ token A secret is required to send coverage for private repositories. Default: if this option is not specified, only public repositories are supportedstring
) License copyright owner. Default: defaults to the value of authorName or “” if authorName
is undefined.string
) The copyright years to put in the LICENSE file. Default: current yearboolean
) Use dependabot to handle dependency upgrades. Default: false[github.DependabotOptions](#projen-github-dependabotoptions)
) Options for dependabot. Default: default optionsboolean
) Use github workflows to handle dependency upgrades. Default: true[javascript.UpgradeDependenciesOptions](#projen-javascript-upgradedependenciesoptions)
) Options for UpgradeDependencies
. Default: default optionsArray</code>) Additional entries to .gitignore. __*Optional*__
boolean
) Setup jest unit tests. Default: true[javascript.JestOptions](#projen-javascript-jestoptions)
) Jest options. Default: default optionsboolean
) Automatically update files modified during builds to pull-request branches. Default: trueArray</code>) Additional entries to .npmignore. __*Optional*__
boolean
) Defines an .npmignore file. Normally this is only needed for libraries that are packaged as tarballs. Default: true[IgnoreFileOptions](#projen-ignorefileoptions)
) Configuration options for .npmignore file. Optionalboolean
) Defines a package
task that will produce an npm tarball under the artifacts directory (e.g. dist
). Default: trueboolean
) Setup prettier. Default: false[javascript.PrettierOptions](#projen-javascript-prettieroptions)
) Prettier options. Default: default optionsboolean
) Indicates of “projen” should be installed as a devDependency. Default: trueboolean
) Generate (once) .projenrc.js (in JavaScript). Set to false
in order to disable .projenrc.js generation. Default: true if projenrcJson is false[javascript.ProjenrcOptions](#projen-javascript-projenrcoptions)
) Options for .projenrc.js. Default: default optionsstring
) Version of projen to install. Default: Defaults to the latest version.boolean
) Include a GitHub pull request template. Default: trueArray</code>) The contents of the pull request template. __*Default*__: default content
boolean
) Add release management to this project. Default: true (false for subprojects)boolean
) Automatically release to npm when new versions are introduced. Default: falseboolean
) DEPRECATED: renamed to release
. Default: true if not a subprojectArray<[github.workflows.JobStep](#projen-github-workflows-jobstep)>
) Workflow steps to use in order to bootstrap this repo. Default: “yarn install –frozen-lockfile && yarn projen”[github.GitIdentity](#projen-github-gitidentity)
) The git identity to use in workflows. Default: GitHub Actionsstring
) The node version to use in GitHub workflows. Default: same as minNodeVersion
boolean
) Enable Node.js package cache in GitHub workflows. Default: falseboolean
) Do not generate a tsconfig.json
file (used by jsii projects since tsconfig.json is generated by the jsii compiler). Default: falseboolean
) Do not generate a tsconfig.dev.json
file. Default: falseboolean
) Docgen by Typedoc. Default: falsestring
) Docs directory. Default: “docs”string
) The .d.ts file that includes the type declarations for this module. Default: .d.ts file derived from the project’s entrypoint (usually lib/index.d.ts)boolean
) Setup eslint. Default: true[javascript.EslintOptions](#projen-javascript-eslintoptions)
) Eslint options. Default: opinionated default optionsstring
) Typescript artifacts output directory. Default: “lib”boolean
) Use TypeScript for your projenrc file (.projenrc.ts
). Default: false[typescript.ProjenrcOptions](#projen-typescript-projenrcoptions)
) Options for .projenrc.ts. Optionalboolean
) Generate one-time sample in src/
and test/
if there are no files there. Default: truestring
) Typescript sources directory. Default: “src”string
) Jest tests directory. Tests files should be named xxx.test.ts
. Default: “test”[javascript.TypescriptConfigOptions](#projen-javascript-typescriptconfigoptions)
) Custom TSConfig. Default: default options[javascript.TypescriptConfigOptions](#projen-javascript-typescriptconfigoptions)
) Custom tsconfig options for the development tsconfig.json file (used for testing). Default: use the production tsconfig optionsstring
) The name of the development tsconfig.json file. Default: “tsconfig.dev.json”string
) TypeScript version to use. Default: “latest”string
) The name of the library author.string
) Email or URL of the library author.string
) Git repository URL.boolean
) Automatically run API compatibility test against the latest version published to npm after compilation. Default: falsestring
) Name of the ignore file for API compatibility tests. Default: “.compatignore”boolean
) Emit a compressed version of the assembly. Default: falsestring
) File path for generated docs. Default: “API.md”[cdk.JsiiDotNetTarget](#projen-cdk-jsiidotnettarget)
) No description OptionalArray</code>) Accepts a list of glob patterns. __*Optional*__
string
) Version of the jsii compiler to use. Default: “1.x”[cdk.JsiiGoTarget](#projen-cdk-jsiigotarget)
) Publish Go bindings to a git repository. Default: no publishing[cdk.JsiiJavaTarget](#projen-cdk-jsiijavatarget)
) Publish to maven. Default: no publishing[cdk.JsiiDotNetTarget](#projen-cdk-jsiidotnettarget)
) Publish to NuGet. Default: no publishing[cdk.JsiiPythonTarget](#projen-cdk-jsiipythontarget)
) Publish to pypi. Default: no publishing[cdk.JsiiPythonTarget](#projen-cdk-jsiipythontarget)
) No description Optionalstring
) No description Default: “.”[cdk.Catalog](#projen-cdk-catalog)
) Libraries will be picked up by the construct catalog when they are published to npm as jsii modules and will be published under:. Default: new version will be announcedBase class for locating integration tests in the project’s test tree.
Submodule: cdk
Extends: cdk.AutoDiscoverBase
new cdk.IntegrationTestAutoDiscoverBase(project: Project, options: IntegrationTestAutoDiscoverBaseOptions)
[Project](#projen-project)
) No description[cdk.IntegrationTestAutoDiscoverBaseOptions](#projen-cdk-integrationtestautodiscoverbaseoptions)
) No description
string
) Test source tree.Submodule: cdk
Extends: Component Implemented by: awscdk.IntegrationTest, cdk8s.IntegrationTest
new cdk.IntegrationTestBase(project: Project, options: IntegrationTestBaseOptions)
[Project](#projen-project)
) No description[cdk.IntegrationTestBaseOptions](#projen-cdk-integrationtestbaseoptions)
) No description
string
) A path from the project root directory to a TypeScript file which contains the integration test app.string
) The path of the tsconfig.json file to use when running integration test cdk apps.string
) Name of the integration test. Default: Derived from the entrypoint filename.Name | Type | Description |
---|---|---|
assertTask🔹 | [Task](#projen-task) |
Synthesizes the integration test and compares against a local copy (runs during build). |
deployTask🔹 | [Task](#projen-task) |
Deploy the integration test and update the snapshot upon success. |
name🔹 | string |
Integration test name. |
snapshotDir🔹 | string |
Snapshot output directory. |
snapshotTask🔹 | [Task](#projen-task) |
Just update snapshot (without deployment). |
tmpDir🔹 | string |
Temporary directory for each integration test. |
Creates a markdown file based on the jsii manifest: - Adds a docgen
script to package.json - Runs jsii-docgen
after compilation - Enforces that markdown file is checked in.
Submodule: cdk
new cdk.JsiiDocgen(project: JsiiProject, options?: JsiiDocgenOptions)
[cdk.JsiiProject](#projen-cdk-jsiiproject)
) No description[cdk.JsiiDocgenOptions](#projen-cdk-jsiidocgenoptions)
) No description
string
) File path for generated docs. Default: “API.md”Multi-language jsii library project.
Submodule: cdk
Extends: typescript.TypeScriptProject
new cdk.JsiiProject(options: JsiiProjectOptions)
[cdk.JsiiProjectOptions](#projen-cdk-jsiiprojectoptions)
) No description
string
) This is the name of your project.boolean
) Whether to commit the managed files by default. Default: true[IgnoreFileOptions](#projen-ignorefileoptions)
) Configuration options for .gitignore file. Optional[GitOptions](#projen-gitoptions)
) Configuration options for git. Optional[LoggerOptions](#projen-loggeroptions)
) Configure logging options such as verbosity. Default: {}string
) The root directory of the project. Default: “.”[Project](#projen-project)
) The parent project, if this project is part of a bigger project. Optionalstring
) The shell command to use in order to run the projen CLI. Default: “npx projen”boolean
) Generate (once) .projenrc.json (in JSON). Set to false
in order to disable .projenrc.json generation. Default: false[ProjenrcJsonOptions](#projen-projenrcjsonoptions)
) Options for .projenrc.json. Default: default optionsboolean
) Use renovatebot to handle dependency upgrades. Default: false[RenovatebotOptions](#projen-renovatebotoptions)
) Options for renovatebot. Default: default options[github.AutoApproveOptions](#projen-github-autoapproveoptions)
) Enable and configure the ‘auto approve’ workflow. Default: auto approve is disabledboolean
) Enable automatic merging on GitHub. Default: true[github.AutoMergeOptions](#projen-github-automergeoptions)
) Configure options for automatic merging on GitHub. Default: see defaults in AutoMergeOptions
boolean
) Add a clobber
task which resets the repo to origin. Default: true, but false for subprojectsboolean
) Add a VSCode development environment (used for GitHub Codespaces). Default: falseboolean
) Enable GitHub integration. Default: true[github.GitHubOptions](#projen-github-githuboptions)
) Options for GitHub integration. Default: see GitHubOptionsboolean
) Add a Gitpod development environment. Default: falseboolean
) Whether mergify should be enabled on this repository or not. Default: true[github.MergifyOptions](#projen-github-mergifyoptions)
) Options for mergify. Default: default options[ProjectType](#projen-projecttype)
) Which type of project this is (library/app). Default: ProjectType.UNKNOWN[github.GithubCredentials](#projen-github-githubcredentials)
) Choose a method of providing GitHub API access for projen workflows. Default: use a personal access token named PROJEN_GITHUB_TOKENstring
) The name of a secret which includes a GitHub Personal Access Token to be used by projen workflows. Default: “PROJEN_GITHUB_TOKEN”[SampleReadmeProps](#projen-samplereadmeprops)
) The README setup. Default: { filename: ‘README.md’, contents: ‘# replace this’ }boolean
) Auto-close of stale issues and pull request. Default: false[github.StaleOptions](#projen-github-staleoptions)
) Auto-close stale issues and pull requests. Default: see defaults in StaleOptions
boolean
) Enable VSCode integration. Default: trueboolean
) Allow the project to include peerDependencies
and bundledDependencies
. Default: truestring
) Author’s e-mail. Optionalstring
) Author’s name. Optionalboolean
) Is the author an organization. Optionalstring
) Author’s URL / Website. Optionalboolean
) Automatically add all executables under the bin
directory to your package.json
file under the bin
section. Default: trueMap<string, string>
) Binary programs vended with your module. Optionalstring
) The email address to which issues should be reported. Optionalstring
) The url to your project’s issue tracker. OptionalArray</code>) List of dependencies to bundle into this module. __*Optional*__
[javascript.CodeArtifactOptions](#projen-javascript-codeartifactoptions)
) Options for npm packages using AWS CodeArtifact. Default: undefinedArray</code>) Runtime dependencies of this module. __*Default*__: []
string
) The description is just a string that helps people understand the purpose of the package. OptionalArray</code>) Build dependencies for this module. __*Default*__: []
string
) Module entrypoint (main
in package.json
). Default: “lib/index.js”string
) Package’s Homepage / Website. OptionalArray</code>) Keywords to include in `package.json`. __*Optional*__
string
) License’s SPDX identifier. Default: “Apache-2.0”boolean
) Indicates if a license should be added. Default: truestring
) Minimum node.js version to require via engines
(inclusive). Default: no maxstring
) Minimum Node.js version to require via package.json engines
(inclusive). Default: no “engines” specified[javascript.NpmAccess](#projen-javascript-npmaccess)
) Access level of the npm package. Default: for scoped packages (e.g. foo@bar
), the default is NpmAccess.RESTRICTED
, for non-scoped packages, the default is NpmAccess.PUBLIC
.string
) The host name of the npm registry to publish to. Optionalstring
) The base URL of the npm package registry. Default: “https://registry.npmjs.org”string
) GitHub secret which contains the NPM token to use when publishing packages. Default: “NPM_TOKEN”[javascript.NodePackageManager](#projen-javascript-nodepackagemanager)
) The Node Package Manager used to execute scripts. Default: NodePackageManager.YARNstring
) The “name” in package.json. Default: defaults to project name[javascript.PeerDependencyOptions](#projen-javascript-peerdependencyoptions)
) Options for peerDeps
. OptionalArray</code>) Peer dependencies for this module. __*Default*__: []
string
) The version of PNPM to use if using PNPM as a package manager. Default: “7”string
) The repository is the location where the actual code for your package lives. Optionalstring
) If the package.json for your package is not in the root directory (for example if it is part of a monorepo), you can specify the directory in which it lives. OptionalArray<[javascript.ScopedPackagesOptions](#projen-javascript-scopedpackagesoptions)>
) Options for privately hosted scoped packages. Default: fetch all scoped packages from the public npm registryMap<string, string>
) npm scripts to include. Default: {}string
) Package’s Stability. Optionalstring
) Version requirement of publib
which is used to publish modules to npm. Default: “latest”number
) Major version to release from the default branch. Default: Major version is not enforced.number
) Minimal Major version to release. Default: No minimum version is being enforcedstring
) The npmDistTag to use when publishing from the default branch. Default: “latest”Array<[github.workflows.JobStep](#projen-github-workflows-jobstep)>
) Steps to execute after build as part of the release workflow. Default: []string
) Bump versions from the default branch as pre-releases (e.g. “beta”, “alpha”, “pre”). Default: normal semantic versionsboolean
) Instead of actually publishing to package managers, just print the publishing command. Default: falseboolean
) Define publishing tasks that can be executed manually as well as workflows. Default: falseMap<string, [release.BranchOptions](#projen-release-branchoptions)>
) Defines additional release branches. Default: no additional branches are used for release. you can use addBranch()
to add additional branches.boolean
) Automatically release new versions every commit to one of branches in releaseBranches
. Default: trueboolean
) Create a github issue on every failed publishing task. Default: falsestring
) The label to apply to issues indicating publish failures. Default: “failed-release”string
) CRON schedule to trigger new releases. Default: no scheduled releasesstring
) Automatically add the given prefix to release tags. Useful if you are releasing on multiple branches with overlapping version numbers. Default: “v”[release.ReleaseTrigger](#projen-release-releasetrigger)
) The release trigger to use. Default: Continuous releases (ReleaseTrigger.continuous()
)string
) The name of the default release workflow. Default: “Release”Array<[github.workflows.JobStep](#projen-github-workflows-jobstep)>
) A set of workflow steps to execute in order to setup the workflow container. OptionalMap<string, any>
) Custom configuration used when creating changelog with standard-version package. Default: standard configuration applicable for GitHub repositoriesstring
) Container image to use for GitHub workflows. Default: default imageArray</code>) Github Runner selection labels. __*Default*__: ["ubuntu-latest"]
string
) The name of the main release branch.string
) A directory which will contain build artifacts. Default: “dist”boolean
) Automatically approve deps upgrade PRs, allowing them to be merged by mergify (if configued). Default: trueboolean
) Define a GitHub workflow for building PRs. Default: true if not a subproject[github.workflows.Triggers](#projen-github-workflows-triggers)
) Build workflow triggers. Default: “{ pullRequest: {}, workflowDispatch: {} }”[javascript.BundlerOptions](#projen-javascript-bundleroptions)
) Options for Bundler
. Optionalboolean
) Define a GitHub workflow step for sending code coverage metrics to https://codecov.io/ Uses codecov/codecov-action@v3 A secret is required for private repos. Configured with @codeCovTokenSecret. Default: falsestring
) Define the secret name for a specified https://codecov.io/ token A secret is required to send coverage for private repositories. Default: if this option is not specified, only public repositories are supportedstring
) License copyright owner. Default: defaults to the value of authorName or “” if authorName
is undefined.string
) The copyright years to put in the LICENSE file. Default: current yearboolean
) Use dependabot to handle dependency upgrades. Default: false[github.DependabotOptions](#projen-github-dependabotoptions)
) Options for dependabot. Default: default optionsboolean
) Use github workflows to handle dependency upgrades. Default: true[javascript.UpgradeDependenciesOptions](#projen-javascript-upgradedependenciesoptions)
) Options for UpgradeDependencies
. Default: default optionsArray</code>) Additional entries to .gitignore. __*Optional*__
boolean
) Setup jest unit tests. Default: true[javascript.JestOptions](#projen-javascript-jestoptions)
) Jest options. Default: default optionsboolean
) Automatically update files modified during builds to pull-request branches. Default: trueArray</code>) Additional entries to .npmignore. __*Optional*__
boolean
) Defines an .npmignore file. Normally this is only needed for libraries that are packaged as tarballs. Default: true[IgnoreFileOptions](#projen-ignorefileoptions)
) Configuration options for .npmignore file. Optionalboolean
) Defines a package
task that will produce an npm tarball under the artifacts directory (e.g. dist
). Default: trueboolean
) Setup prettier. Default: false[javascript.PrettierOptions](#projen-javascript-prettieroptions)
) Prettier options. Default: default optionsboolean
) Indicates of “projen” should be installed as a devDependency. Default: trueboolean
) Generate (once) .projenrc.js (in JavaScript). Set to false
in order to disable .projenrc.js generation. Default: true if projenrcJson is false[javascript.ProjenrcOptions](#projen-javascript-projenrcoptions)
) Options for .projenrc.js. Default: default optionsstring
) Version of projen to install. Default: Defaults to the latest version.boolean
) Include a GitHub pull request template. Default: trueArray</code>) The contents of the pull request template. __*Default*__: default content
boolean
) Add release management to this project. Default: true (false for subprojects)boolean
) Automatically release to npm when new versions are introduced. Default: falseboolean
) DEPRECATED: renamed to release
. Default: true if not a subprojectArray<[github.workflows.JobStep](#projen-github-workflows-jobstep)>
) Workflow steps to use in order to bootstrap this repo. Default: “yarn install –frozen-lockfile && yarn projen”[github.GitIdentity](#projen-github-gitidentity)
) The git identity to use in workflows. Default: GitHub Actionsstring
) The node version to use in GitHub workflows. Default: same as minNodeVersion
boolean
) Enable Node.js package cache in GitHub workflows. Default: falseboolean
) Do not generate a tsconfig.json
file (used by jsii projects since tsconfig.json is generated by the jsii compiler). Default: falseboolean
) Do not generate a tsconfig.dev.json
file. Default: falseboolean
) Docgen by Typedoc. Default: falsestring
) Docs directory. Default: “docs”string
) The .d.ts file that includes the type declarations for this module. Default: .d.ts file derived from the project’s entrypoint (usually lib/index.d.ts)boolean
) Setup eslint. Default: true[javascript.EslintOptions](#projen-javascript-eslintoptions)
) Eslint options. Default: opinionated default optionsstring
) Typescript artifacts output directory. Default: “lib”boolean
) Use TypeScript for your projenrc file (.projenrc.ts
). Default: false[typescript.ProjenrcOptions](#projen-typescript-projenrcoptions)
) Options for .projenrc.ts. Optionalboolean
) Generate one-time sample in src/
and test/
if there are no files there. Default: truestring
) Typescript sources directory. Default: “src”string
) Jest tests directory. Tests files should be named xxx.test.ts
. Default: “test”[javascript.TypescriptConfigOptions](#projen-javascript-typescriptconfigoptions)
) Custom TSConfig. Default: default options[javascript.TypescriptConfigOptions](#projen-javascript-typescriptconfigoptions)
) Custom tsconfig options for the development tsconfig.json file (used for testing). Default: use the production tsconfig optionsstring
) The name of the development tsconfig.json file. Default: “tsconfig.dev.json”string
) TypeScript version to use. Default: “latest”string
) The name of the library author.string
) Email or URL of the library author.string
) Git repository URL.boolean
) Automatically run API compatibility test against the latest version published to npm after compilation. Default: falsestring
) Name of the ignore file for API compatibility tests. Default: “.compatignore”boolean
) Emit a compressed version of the assembly. Default: falsestring
) File path for generated docs. Default: “API.md”[cdk.JsiiDotNetTarget](#projen-cdk-jsiidotnettarget)
) No description OptionalArray</code>) Accepts a list of glob patterns. __*Optional*__
string
) Version of the jsii compiler to use. Default: “1.x”[cdk.JsiiGoTarget](#projen-cdk-jsiigotarget)
) Publish Go bindings to a git repository. Default: no publishing[cdk.JsiiJavaTarget](#projen-cdk-jsiijavatarget)
) Publish to maven. Default: no publishing[cdk.JsiiDotNetTarget](#projen-cdk-jsiidotnettarget)
) Publish to NuGet. Default: no publishing[cdk.JsiiPythonTarget](#projen-cdk-jsiipythontarget)
) Publish to pypi. Default: no publishing[cdk.JsiiPythonTarget](#projen-cdk-jsiipythontarget)
) No description Optionalstring
) No description Default: “.”Name | Type | Description |
---|---|---|
eslint?🔹 | [javascript.Eslint](#projen-javascript-eslint) |
Optional |
Automatically discovers and creates IntegrationTest
s from entry points found in the test tree.
Submodule: cdk8s
Extends: Component
new cdk8s.AutoDiscover(project: Project, options: AutoDiscoverOptions)
[Project](#projen-project)
) No description[cdk8s.AutoDiscoverOptions](#projen-cdk8s-autodiscoveroptions)
) No description
string
) Test source tree.string
) Path to the tsconfig file to use for integration tests.boolean
) Automatically discover integration tests. Default: trueManages dependencies on the CDK8s.
Submodule: cdk8s
Extends: Component Implemented by: cdk8s.Cdk8sDepsPy
new cdk8s.Cdk8sDeps(project: Project, options: Cdk8sDepsOptions)
[Project](#projen-project)
) No description[cdk8s.Cdk8sDepsOptions](#projen-cdk8s-cdk8sdepsoptions)
) No description
string
) Minumum version of the cdk8s to depend on.string
) Minumum version of the cdk8s-cli to depend on. Default: “2.0.28”boolean
) Use pinned version instead of caret version for cdk8s-cli. Default: falseboolean
) Include cdk8s-plus. Default: truestring
) Minumum version of the cdk8s-plus-XX to depend on. Default: “2.0.0-rc.26”boolean
) Use pinned version instead of caret version for cdk8s-plus-17. Default: falseboolean
) Use pinned version instead of caret version for cdk8s. Default: falsestring
) Minimum version of the constructs
library to depend on. Default: “10.1.42”boolean
) Use pinned version instead of caret version for constructs. Default: falsenumber
) The cdk8s-plus library depends of Kubernetes minor version For example, cdk8s-plus-22 targets kubernetes version 1.22.0 cdk8s-plus-21 targets kubernetes version 1.21.0. Default: 22boolean
) Add cdk8s-cli only to Node projects.[DependencyType](#projen-dependencytype)
) The type of dependency to use for runtime CDK8s and constructs
modules.Name | Type | Description |
---|---|---|
cdk8sMajorVersion🔹 | number |
The major version of the CDK8s (e.g. 1, 2, …). |
cdk8sMinimumVersion🔹 | string |
The minimum version of the CDK8s (e.g. 2.0.0 ). |
cdk8sVersion🔹 | string |
The dependency requirement for CDK8s. |
Return a configuration object with information about package naming in various languages.
protected packageNames(): Cdk8sPackageNames
Returns:
[cdk8s.Cdk8sPackageNames](#projen-cdk8s-cdk8spackagenames)
Submodule: cdk8s
Extends: cdk8s.Cdk8sDeps
new cdk8s.Cdk8sDepsPy(project: Project, options: Cdk8sDepsOptions)
[Project](#projen-project)
) No description[cdk8s.Cdk8sDepsOptions](#projen-cdk8s-cdk8sdepsoptions)
) No description
string
) Minumum version of the cdk8s to depend on.string
) Minumum version of the cdk8s-cli to depend on. Default: “2.0.28”boolean
) Use pinned version instead of caret version for cdk8s-cli. Default: falseboolean
) Include cdk8s-plus. Default: truestring
) Minumum version of the cdk8s-plus-XX to depend on. Default: “2.0.0-rc.26”boolean
) Use pinned version instead of caret version for cdk8s-plus-17. Default: falseboolean
) Use pinned version instead of caret version for cdk8s. Default: falsestring
) Minimum version of the constructs
library to depend on. Default: “10.1.42”boolean
) Use pinned version instead of caret version for constructs. Default: falsenumber
) The cdk8s-plus library depends of Kubernetes minor version For example, cdk8s-plus-22 targets kubernetes version 1.22.0 cdk8s-plus-21 targets kubernetes version 1.21.0. Default: 22boolean
) Add cdk8s-cli only to Node projects.[DependencyType](#projen-dependencytype)
) The type of dependency to use for runtime CDK8s and constructs
modules.Return a configuration object with information about package naming in various languages.
protected packageNames(): Cdk8sPackageNames
Returns:
[cdk8s.Cdk8sPackageNames](#projen-cdk8s-cdk8spackagenames)
CDK8s app in Python.
Submodule: cdk8s
Extends: python.PythonProject
new cdk8s.Cdk8sPythonApp(options: Cdk8sPythonOptions)
[cdk8s.Cdk8sPythonOptions](#projen-cdk8s-cdk8spythonoptions)
) No description
string
) This is the name of your project.boolean
) Whether to commit the managed files by default. Default: true[IgnoreFileOptions](#projen-ignorefileoptions)
) Configuration options for .gitignore file. Optional[GitOptions](#projen-gitoptions)
) Configuration options for git. Optional[LoggerOptions](#projen-loggeroptions)
) Configure logging options such as verbosity. Default: {}string
) The root directory of the project. Default: “.”[Project](#projen-project)
) The parent project, if this project is part of a bigger project. Optionalstring
) The shell command to use in order to run the projen CLI. Default: “npx projen”boolean
) Generate (once) .projenrc.json (in JSON). Set to false
in order to disable .projenrc.json generation. Default: false[ProjenrcJsonOptions](#projen-projenrcjsonoptions)
) Options for .projenrc.json. Default: default optionsboolean
) Use renovatebot to handle dependency upgrades. Default: false[RenovatebotOptions](#projen-renovatebotoptions)
) Options for renovatebot. Default: default options[github.AutoApproveOptions](#projen-github-autoapproveoptions)
) Enable and configure the ‘auto approve’ workflow. Default: auto approve is disabledboolean
) Enable automatic merging on GitHub. Default: true[github.AutoMergeOptions](#projen-github-automergeoptions)
) Configure options for automatic merging on GitHub. Default: see defaults in AutoMergeOptions
boolean
) Add a clobber
task which resets the repo to origin. Default: true, but false for subprojectsboolean
) Add a VSCode development environment (used for GitHub Codespaces). Default: falseboolean
) Enable GitHub integration. Default: true[github.GitHubOptions](#projen-github-githuboptions)
) Options for GitHub integration. Default: see GitHubOptionsboolean
) Add a Gitpod development environment. Default: falseboolean
) Whether mergify should be enabled on this repository or not. Default: true[github.MergifyOptions](#projen-github-mergifyoptions)
) Options for mergify. Default: default options[ProjectType](#projen-projecttype)
) Which type of project this is (library/app). Default: ProjectType.UNKNOWN[github.GithubCredentials](#projen-github-githubcredentials)
) Choose a method of providing GitHub API access for projen workflows. Default: use a personal access token named PROJEN_GITHUB_TOKENstring
) The name of a secret which includes a GitHub Personal Access Token to be used by projen workflows. Default: “PROJEN_GITHUB_TOKEN”[SampleReadmeProps](#projen-samplereadmeprops)
) The README setup. Default: { filename: ‘README.md’, contents: ‘# replace this’ }boolean
) Auto-close of stale issues and pull request. Default: false[github.StaleOptions](#projen-github-staleoptions)
) Auto-close stale issues and pull requests. Default: see defaults in StaleOptions
boolean
) Enable VSCode integration. Default: truestring
) Author’s e-mail.string
) Author’s name.string
) Version of the package.Array</code>) A list of PyPI trove classifiers that describe the project. __*Optional*__
string
) A short description of the package. Optionalstring
) A URL to the website of the project. Optionalstring
) License of this package as an SPDX identifier. Optionalstring
) Package name. Optional[python.PoetryPyprojectOptionsWithoutDeps](#projen-python-poetrypyprojectoptionswithoutdeps)
) Additional options to set for poetry if using poetry. OptionalMap<string, any>
) Additional fields to pass in the setup() function if using setuptools. Optionalstring
) Name of the python package as used in imports and filenames.Array</code>) List of runtime dependencies for this project. __*Default*__: []
Array</code>) List of dev dependencies for this project. __*Default*__: []
boolean
) Use pip with a requirements.txt file to track project dependencies. Default: true, unless poetry is true, then falseboolean
) Use poetry to manage your project dependencies, virtual environment, and (optional) packaging/publishing. Default: falseboolean
) Use projenrc in javascript. Default: false[javascript.ProjenrcOptions](#projen-javascript-projenrcoptions)
) Options related to projenrc in JavaScript. Default: default optionsboolean
) Use projenrc in Python. Default: true[python.ProjenrcOptions](#projen-python-projenrcoptions)
) Options related to projenrc in python. Default: default optionsboolean
) Use projenrc in TypeScript. Default: false[typescript.ProjenrcTsOptions](#projen-typescript-projenrctsoptions)
) Options related to projenrc in TypeScript. Default: default optionsboolean
) Include pytest tests. Default: true[python.PytestOptions](#projen-python-pytestoptions)
) pytest options. Default: defaultsstring
) Path to the python executable to use. Default: “python”boolean
) Include sample code and test if the relevant directories don’t exist. Default: trueboolean
) Use setuptools with a setup.py script for packaging and publishing. Default: true, unless poetry is true, then falseboolean
) Use venv to manage a virtual environment for installing dependencies inside. Default: true, unless poetry is true, then false[python.VenvOptions](#projen-python-venvoptions)
) Venv options. Default: defaultsstring
) Minumum version of the cdk8s to depend on.string
) Minumum version of the cdk8s-cli to depend on. Default: “2.0.28”boolean
) Use pinned version instead of caret version for cdk8s-cli. Default: falseboolean
) Include cdk8s-plus. Default: truestring
) Minumum version of the cdk8s-plus-XX to depend on. Default: “2.0.0-rc.26”boolean
) Use pinned version instead of caret version for cdk8s-plus-17. Default: falseboolean
) Use pinned version instead of caret version for cdk8s. Default: falsestring
) Minimum version of the constructs
library to depend on. Default: “10.1.42”boolean
) Use pinned version instead of caret version for constructs. Default: falsenumber
) The cdk8s-plus library depends of Kubernetes minor version For example, cdk8s-plus-22 targets kubernetes version 1.22.0 cdk8s-plus-21 targets kubernetes version 1.21.0. Default: 22string
) The CDK8s app’s entrypoint. Default: “app.py”Array</code>) Import additional specs. __*Default*__: no additional specs imported
string
) Import a specific Kubernetes spec version. Default: Use the cdk8s defaultName | Type | Description |
---|---|---|
appEntrypoint🔹 | string |
The CDK8s app entrypoint. |
cdk8sDeps🔹 | [cdk8s.Cdk8sDeps](#projen-cdk8s-cdk8sdeps) |
CDK8s app in TypeScript.
Submodule: cdk8s
Extends: typescript.TypeScriptAppProject
new cdk8s.Cdk8sTypeScriptApp(options: Cdk8sTypeScriptAppOptions)
[cdk8s.Cdk8sTypeScriptAppOptions](#projen-cdk8s-cdk8stypescriptappoptions)
) No description
string
) This is the name of your project.boolean
) Whether to commit the managed files by default. Default: true[IgnoreFileOptions](#projen-ignorefileoptions)
) Configuration options for .gitignore file. Optional[GitOptions](#projen-gitoptions)
) Configuration options for git. Optional[LoggerOptions](#projen-loggeroptions)
) Configure logging options such as verbosity. Default: {}string
) The root directory of the project. Default: “.”[Project](#projen-project)
) The parent project, if this project is part of a bigger project. Optionalstring
) The shell command to use in order to run the projen CLI. Default: “npx projen”boolean
) Generate (once) .projenrc.json (in JSON). Set to false
in order to disable .projenrc.json generation. Default: false[ProjenrcJsonOptions](#projen-projenrcjsonoptions)
) Options for .projenrc.json. Default: default optionsboolean
) Use renovatebot to handle dependency upgrades. Default: false[RenovatebotOptions](#projen-renovatebotoptions)
) Options for renovatebot. Default: default options[github.AutoApproveOptions](#projen-github-autoapproveoptions)
) Enable and configure the ‘auto approve’ workflow. Default: auto approve is disabledboolean
) Enable automatic merging on GitHub. Default: true[github.AutoMergeOptions](#projen-github-automergeoptions)
) Configure options for automatic merging on GitHub. Default: see defaults in AutoMergeOptions
boolean
) Add a clobber
task which resets the repo to origin. Default: true, but false for subprojectsboolean
) Add a VSCode development environment (used for GitHub Codespaces). Default: falseboolean
) Enable GitHub integration. Default: true[github.GitHubOptions](#projen-github-githuboptions)
) Options for GitHub integration. Default: see GitHubOptionsboolean
) Add a Gitpod development environment. Default: falseboolean
) Whether mergify should be enabled on this repository or not. Default: true[github.MergifyOptions](#projen-github-mergifyoptions)
) Options for mergify. Default: default options[ProjectType](#projen-projecttype)
) Which type of project this is (library/app). Default: ProjectType.UNKNOWN[github.GithubCredentials](#projen-github-githubcredentials)
) Choose a method of providing GitHub API access for projen workflows. Default: use a personal access token named PROJEN_GITHUB_TOKENstring
) The name of a secret which includes a GitHub Personal Access Token to be used by projen workflows. Default: “PROJEN_GITHUB_TOKEN”[SampleReadmeProps](#projen-samplereadmeprops)
) The README setup. Default: { filename: ‘README.md’, contents: ‘# replace this’ }boolean
) Auto-close of stale issues and pull request. Default: false[github.StaleOptions](#projen-github-staleoptions)
) Auto-close stale issues and pull requests. Default: see defaults in StaleOptions
boolean
) Enable VSCode integration. Default: trueboolean
) Allow the project to include peerDependencies
and bundledDependencies
. Default: truestring
) Author’s e-mail. Optionalstring
) Author’s name. Optionalboolean
) Is the author an organization. Optionalstring
) Author’s URL / Website. Optionalboolean
) Automatically add all executables under the bin
directory to your package.json
file under the bin
section. Default: trueMap<string, string>
) Binary programs vended with your module. Optionalstring
) The email address to which issues should be reported. Optionalstring
) The url to your project’s issue tracker. OptionalArray</code>) List of dependencies to bundle into this module. __*Optional*__
[javascript.CodeArtifactOptions](#projen-javascript-codeartifactoptions)
) Options for npm packages using AWS CodeArtifact. Default: undefinedArray</code>) Runtime dependencies of this module. __*Default*__: []
string
) The description is just a string that helps people understand the purpose of the package. OptionalArray</code>) Build dependencies for this module. __*Default*__: []
string
) Module entrypoint (main
in package.json
). Default: “lib/index.js”string
) Package’s Homepage / Website. OptionalArray</code>) Keywords to include in `package.json`. __*Optional*__
string
) License’s SPDX identifier. Default: “Apache-2.0”boolean
) Indicates if a license should be added. Default: truestring
) Minimum node.js version to require via engines
(inclusive). Default: no maxstring
) Minimum Node.js version to require via package.json engines
(inclusive). Default: no “engines” specified[javascript.NpmAccess](#projen-javascript-npmaccess)
) Access level of the npm package. Default: for scoped packages (e.g. foo@bar
), the default is NpmAccess.RESTRICTED
, for non-scoped packages, the default is NpmAccess.PUBLIC
.string
) The host name of the npm registry to publish to. Optionalstring
) The base URL of the npm package registry. Default: “https://registry.npmjs.org”string
) GitHub secret which contains the NPM token to use when publishing packages. Default: “NPM_TOKEN”[javascript.NodePackageManager](#projen-javascript-nodepackagemanager)
) The Node Package Manager used to execute scripts. Default: NodePackageManager.YARNstring
) The “name” in package.json. Default: defaults to project name[javascript.PeerDependencyOptions](#projen-javascript-peerdependencyoptions)
) Options for peerDeps
. OptionalArray</code>) Peer dependencies for this module. __*Default*__: []
string
) The version of PNPM to use if using PNPM as a package manager. Default: “7”string
) The repository is the location where the actual code for your package lives. Optionalstring
) If the package.json for your package is not in the root directory (for example if it is part of a monorepo), you can specify the directory in which it lives. OptionalArray<[javascript.ScopedPackagesOptions](#projen-javascript-scopedpackagesoptions)>
) Options for privately hosted scoped packages. Default: fetch all scoped packages from the public npm registryMap<string, string>
) npm scripts to include. Default: {}string
) Package’s Stability. Optionalstring
) Version requirement of publib
which is used to publish modules to npm. Default: “latest”number
) Major version to release from the default branch. Default: Major version is not enforced.number
) Minimal Major version to release. Default: No minimum version is being enforcedstring
) The npmDistTag to use when publishing from the default branch. Default: “latest”Array<[github.workflows.JobStep](#projen-github-workflows-jobstep)>
) Steps to execute after build as part of the release workflow. Default: []string
) Bump versions from the default branch as pre-releases (e.g. “beta”, “alpha”, “pre”). Default: normal semantic versionsboolean
) Instead of actually publishing to package managers, just print the publishing command. Default: falseboolean
) Define publishing tasks that can be executed manually as well as workflows. Default: falseMap<string, [release.BranchOptions](#projen-release-branchoptions)>
) Defines additional release branches. Default: no additional branches are used for release. you can use addBranch()
to add additional branches.boolean
) Automatically release new versions every commit to one of branches in releaseBranches
. Default: trueboolean
) Create a github issue on every failed publishing task. Default: falsestring
) The label to apply to issues indicating publish failures. Default: “failed-release”string
) CRON schedule to trigger new releases. Default: no scheduled releasesstring
) Automatically add the given prefix to release tags. Useful if you are releasing on multiple branches with overlapping version numbers. Default: “v”[release.ReleaseTrigger](#projen-release-releasetrigger)
) The release trigger to use. Default: Continuous releases (ReleaseTrigger.continuous()
)string
) The name of the default release workflow. Default: “Release”Array<[github.workflows.JobStep](#projen-github-workflows-jobstep)>
) A set of workflow steps to execute in order to setup the workflow container. OptionalMap<string, any>
) Custom configuration used when creating changelog with standard-version package. Default: standard configuration applicable for GitHub repositoriesstring
) Container image to use for GitHub workflows. Default: default imageArray</code>) Github Runner selection labels. __*Default*__: ["ubuntu-latest"]
string
) The name of the main release branch.string
) A directory which will contain build artifacts. Default: “dist”boolean
) Automatically approve deps upgrade PRs, allowing them to be merged by mergify (if configued). Default: trueboolean
) Define a GitHub workflow for building PRs. Default: true if not a subproject[github.workflows.Triggers](#projen-github-workflows-triggers)
) Build workflow triggers. Default: “{ pullRequest: {}, workflowDispatch: {} }”[javascript.BundlerOptions](#projen-javascript-bundleroptions)
) Options for Bundler
. Optionalboolean
) Define a GitHub workflow step for sending code coverage metrics to https://codecov.io/ Uses codecov/codecov-action@v3 A secret is required for private repos. Configured with @codeCovTokenSecret. Default: falsestring
) Define the secret name for a specified https://codecov.io/ token A secret is required to send coverage for private repositories. Default: if this option is not specified, only public repositories are supportedstring
) License copyright owner. Default: defaults to the value of authorName or “” if authorName
is undefined.string
) The copyright years to put in the LICENSE file. Default: current yearboolean
) Use dependabot to handle dependency upgrades. Default: false[github.DependabotOptions](#projen-github-dependabotoptions)
) Options for dependabot. Default: default optionsboolean
) Use github workflows to handle dependency upgrades. Default: true[javascript.UpgradeDependenciesOptions](#projen-javascript-upgradedependenciesoptions)
) Options for UpgradeDependencies
. Default: default optionsArray</code>) Additional entries to .gitignore. __*Optional*__
boolean
) Setup jest unit tests. Default: true[javascript.JestOptions](#projen-javascript-jestoptions)
) Jest options. Default: default optionsboolean
) Automatically update files modified during builds to pull-request branches. Default: trueArray</code>) Additional entries to .npmignore. __*Optional*__
boolean
) Defines an .npmignore file. Normally this is only needed for libraries that are packaged as tarballs. Default: true[IgnoreFileOptions](#projen-ignorefileoptions)
) Configuration options for .npmignore file. Optionalboolean
) Defines a package
task that will produce an npm tarball under the artifacts directory (e.g. dist
). Default: trueboolean
) Setup prettier. Default: false[javascript.PrettierOptions](#projen-javascript-prettieroptions)
) Prettier options. Default: default optionsboolean
) Indicates of “projen” should be installed as a devDependency. Default: trueboolean
) Generate (once) .projenrc.js (in JavaScript). Set to false
in order to disable .projenrc.js generation. Default: true if projenrcJson is false[javascript.ProjenrcOptions](#projen-javascript-projenrcoptions)
) Options for .projenrc.js. Default: default optionsstring
) Version of projen to install. Default: Defaults to the latest version.boolean
) Include a GitHub pull request template. Default: trueArray</code>) The contents of the pull request template. __*Default*__: default content
boolean
) Add release management to this project. Default: true (false for subprojects)boolean
) Automatically release to npm when new versions are introduced. Default: falseboolean
) DEPRECATED: renamed to release
. Default: true if not a subprojectArray<[github.workflows.JobStep](#projen-github-workflows-jobstep)>
) Workflow steps to use in order to bootstrap this repo. Default: “yarn install –frozen-lockfile && yarn projen”[github.GitIdentity](#projen-github-gitidentity)
) The git identity to use in workflows. Default: GitHub Actionsstring
) The node version to use in GitHub workflows. Default: same as minNodeVersion
boolean
) Enable Node.js package cache in GitHub workflows. Default: falseboolean
) Do not generate a tsconfig.json
file (used by jsii projects since tsconfig.json is generated by the jsii compiler). Default: falseboolean
) Do not generate a tsconfig.dev.json
file. Default: falseboolean
) Docgen by Typedoc. Default: falsestring
) Docs directory. Default: “docs”string
) The .d.ts file that includes the type declarations for this module. Default: .d.ts file derived from the project’s entrypoint (usually lib/index.d.ts)boolean
) Setup eslint. Default: true[javascript.EslintOptions](#projen-javascript-eslintoptions)
) Eslint options. Default: opinionated default optionsstring
) Typescript artifacts output directory. Default: “lib”boolean
) Use TypeScript for your projenrc file (.projenrc.ts
). Default: false[typescript.ProjenrcOptions](#projen-typescript-projenrcoptions)
) Options for .projenrc.ts. Optionalboolean
) Generate one-time sample in src/
and test/
if there are no files there. Default: truestring
) Typescript sources directory. Default: “src”string
) Jest tests directory. Tests files should be named xxx.test.ts
. Default: “test”[javascript.TypescriptConfigOptions](#projen-javascript-typescriptconfigoptions)
) Custom TSConfig. Default: default options[javascript.TypescriptConfigOptions](#projen-javascript-typescriptconfigoptions)
) Custom tsconfig options for the development tsconfig.json file (used for testing). Default: use the production tsconfig optionsstring
) The name of the development tsconfig.json file. Default: “tsconfig.dev.json”string
) TypeScript version to use. Default: “latest”string
) Minumum version of the cdk8s to depend on.string
) Minumum version of the cdk8s-cli to depend on. Default: “2.0.28”boolean
) Use pinned version instead of caret version for cdk8s-cli. Default: falseboolean
) Include cdk8s-plus. Default: truestring
) Minumum version of the cdk8s-plus-XX to depend on. Default: “2.0.0-rc.26”boolean
) Use pinned version instead of caret version for cdk8s-plus-17. Default: falseboolean
) Use pinned version instead of caret version for cdk8s. Default: falsestring
) Minimum version of the constructs
library to depend on. Default: “10.1.42”boolean
) Use pinned version instead of caret version for constructs. Default: falsenumber
) The cdk8s-plus library depends of Kubernetes minor version For example, cdk8s-plus-22 targets kubernetes version 1.22.0 cdk8s-plus-21 targets kubernetes version 1.21.0. Default: 22string
) The CDK8s app’s entrypoint (relative to the source directory, which is “src” by default). Default: “main.ts”Array</code>) Import additional specs. __*Default*__: no additional specs imported
boolean
) Automatically adds an cdk8s.IntegrationTest
for each .integ.ts
app in your test directory. If this is disabled, you can manually add an cdk8s.AutoDiscover
component to your project. Default: truestring
) Import a specific Kubernetes spec version. Default: Use the cdk8s defaultName | Type | Description |
---|---|---|
appEntrypoint🔹 | string |
The CDK8s app entrypoint. |
cdk8sDeps🔹 | [cdk8s.Cdk8sDeps](#projen-cdk8s-cdk8sdeps) |
CDK8s construct library project.
A multi-language (jsii) construct library which vends constructs designed to use within the CDK for Kubernetes (CDK8s), with a friendly workflow and automatic publishing to the construct catalog.
Submodule: cdk8s
Extends: cdk.ConstructLibrary
new cdk8s.ConstructLibraryCdk8s(options: ConstructLibraryCdk8sOptions)
[cdk8s.ConstructLibraryCdk8sOptions](#projen-cdk8s-constructlibrarycdk8soptions)
) No description
string
) This is the name of your project.boolean
) Whether to commit the managed files by default. Default: true[IgnoreFileOptions](#projen-ignorefileoptions)
) Configuration options for .gitignore file. Optional[GitOptions](#projen-gitoptions)
) Configuration options for git. Optional[LoggerOptions](#projen-loggeroptions)
) Configure logging options such as verbosity. Default: {}string
) The root directory of the project. Default: “.”[Project](#projen-project)
) The parent project, if this project is part of a bigger project. Optionalstring
) The shell command to use in order to run the projen CLI. Default: “npx projen”boolean
) Generate (once) .projenrc.json (in JSON). Set to false
in order to disable .projenrc.json generation. Default: false[ProjenrcJsonOptions](#projen-projenrcjsonoptions)
) Options for .projenrc.json. Default: default optionsboolean
) Use renovatebot to handle dependency upgrades. Default: false[RenovatebotOptions](#projen-renovatebotoptions)
) Options for renovatebot. Default: default options[github.AutoApproveOptions](#projen-github-autoapproveoptions)
) Enable and configure the ‘auto approve’ workflow. Default: auto approve is disabledboolean
) Enable automatic merging on GitHub. Default: true[github.AutoMergeOptions](#projen-github-automergeoptions)
) Configure options for automatic merging on GitHub. Default: see defaults in AutoMergeOptions
boolean
) Add a clobber
task which resets the repo to origin. Default: true, but false for subprojectsboolean
) Add a VSCode development environment (used for GitHub Codespaces). Default: falseboolean
) Enable GitHub integration. Default: true[github.GitHubOptions](#projen-github-githuboptions)
) Options for GitHub integration. Default: see GitHubOptionsboolean
) Add a Gitpod development environment. Default: falseboolean
) Whether mergify should be enabled on this repository or not. Default: true[github.MergifyOptions](#projen-github-mergifyoptions)
) Options for mergify. Default: default options[ProjectType](#projen-projecttype)
) Which type of project this is (library/app). Default: ProjectType.UNKNOWN[github.GithubCredentials](#projen-github-githubcredentials)
) Choose a method of providing GitHub API access for projen workflows. Default: use a personal access token named PROJEN_GITHUB_TOKENstring
) The name of a secret which includes a GitHub Personal Access Token to be used by projen workflows. Default: “PROJEN_GITHUB_TOKEN”[SampleReadmeProps](#projen-samplereadmeprops)
) The README setup. Default: { filename: ‘README.md’, contents: ‘# replace this’ }boolean
) Auto-close of stale issues and pull request. Default: false[github.StaleOptions](#projen-github-staleoptions)
) Auto-close stale issues and pull requests. Default: see defaults in StaleOptions
boolean
) Enable VSCode integration. Default: trueboolean
) Allow the project to include peerDependencies
and bundledDependencies
. Default: truestring
) Author’s e-mail. Optionalstring
) Author’s name. Optionalboolean
) Is the author an organization. Optionalstring
) Author’s URL / Website. Optionalboolean
) Automatically add all executables under the bin
directory to your package.json
file under the bin
section. Default: trueMap<string, string>
) Binary programs vended with your module. Optionalstring
) The email address to which issues should be reported. Optionalstring
) The url to your project’s issue tracker. OptionalArray</code>) List of dependencies to bundle into this module. __*Optional*__
[javascript.CodeArtifactOptions](#projen-javascript-codeartifactoptions)
) Options for npm packages using AWS CodeArtifact. Default: undefinedArray</code>) Runtime dependencies of this module. __*Default*__: []
string
) The description is just a string that helps people understand the purpose of the package. OptionalArray</code>) Build dependencies for this module. __*Default*__: []
string
) Module entrypoint (main
in package.json
). Default: “lib/index.js”string
) Package’s Homepage / Website. OptionalArray</code>) Keywords to include in `package.json`. __*Optional*__
string
) License’s SPDX identifier. Default: “Apache-2.0”boolean
) Indicates if a license should be added. Default: truestring
) Minimum node.js version to require via engines
(inclusive). Default: no maxstring
) Minimum Node.js version to require via package.json engines
(inclusive). Default: no “engines” specified[javascript.NpmAccess](#projen-javascript-npmaccess)
) Access level of the npm package. Default: for scoped packages (e.g. foo@bar
), the default is NpmAccess.RESTRICTED
, for non-scoped packages, the default is NpmAccess.PUBLIC
.string
) The host name of the npm registry to publish to. Optionalstring
) The base URL of the npm package registry. Default: “https://registry.npmjs.org”string
) GitHub secret which contains the NPM token to use when publishing packages. Default: “NPM_TOKEN”[javascript.NodePackageManager](#projen-javascript-nodepackagemanager)
) The Node Package Manager used to execute scripts. Default: NodePackageManager.YARNstring
) The “name” in package.json. Default: defaults to project name[javascript.PeerDependencyOptions](#projen-javascript-peerdependencyoptions)
) Options for peerDeps
. OptionalArray</code>) Peer dependencies for this module. __*Default*__: []
string
) The version of PNPM to use if using PNPM as a package manager. Default: “7”string
) The repository is the location where the actual code for your package lives. Optionalstring
) If the package.json for your package is not in the root directory (for example if it is part of a monorepo), you can specify the directory in which it lives. OptionalArray<[javascript.ScopedPackagesOptions](#projen-javascript-scopedpackagesoptions)>
) Options for privately hosted scoped packages. Default: fetch all scoped packages from the public npm registryMap<string, string>
) npm scripts to include. Default: {}string
) Package’s Stability. Optionalstring
) Version requirement of publib
which is used to publish modules to npm. Default: “latest”number
) Major version to release from the default branch. Default: Major version is not enforced.number
) Minimal Major version to release. Default: No minimum version is being enforcedstring
) The npmDistTag to use when publishing from the default branch. Default: “latest”Array<[github.workflows.JobStep](#projen-github-workflows-jobstep)>
) Steps to execute after build as part of the release workflow. Default: []string
) Bump versions from the default branch as pre-releases (e.g. “beta”, “alpha”, “pre”). Default: normal semantic versionsboolean
) Instead of actually publishing to package managers, just print the publishing command. Default: falseboolean
) Define publishing tasks that can be executed manually as well as workflows. Default: falseMap<string, [release.BranchOptions](#projen-release-branchoptions)>
) Defines additional release branches. Default: no additional branches are used for release. you can use addBranch()
to add additional branches.boolean
) Automatically release new versions every commit to one of branches in releaseBranches
. Default: trueboolean
) Create a github issue on every failed publishing task. Default: falsestring
) The label to apply to issues indicating publish failures. Default: “failed-release”string
) CRON schedule to trigger new releases. Default: no scheduled releasesstring
) Automatically add the given prefix to release tags. Useful if you are releasing on multiple branches with overlapping version numbers. Default: “v”[release.ReleaseTrigger](#projen-release-releasetrigger)
) The release trigger to use. Default: Continuous releases (ReleaseTrigger.continuous()
)string
) The name of the default release workflow. Default: “Release”Array<[github.workflows.JobStep](#projen-github-workflows-jobstep)>
) A set of workflow steps to execute in order to setup the workflow container. OptionalMap<string, any>
) Custom configuration used when creating changelog with standard-version package. Default: standard configuration applicable for GitHub repositoriesstring
) Container image to use for GitHub workflows. Default: default imageArray</code>) Github Runner selection labels. __*Default*__: ["ubuntu-latest"]
string
) The name of the main release branch.string
) A directory which will contain build artifacts. Default: “dist”boolean
) Automatically approve deps upgrade PRs, allowing them to be merged by mergify (if configued). Default: trueboolean
) Define a GitHub workflow for building PRs. Default: true if not a subproject[github.workflows.Triggers](#projen-github-workflows-triggers)
) Build workflow triggers. Default: “{ pullRequest: {}, workflowDispatch: {} }”[javascript.BundlerOptions](#projen-javascript-bundleroptions)
) Options for Bundler
. Optionalboolean
) Define a GitHub workflow step for sending code coverage metrics to https://codecov.io/ Uses codecov/codecov-action@v3 A secret is required for private repos. Configured with @codeCovTokenSecret. Default: falsestring
) Define the secret name for a specified https://codecov.io/ token A secret is required to send coverage for private repositories. Default: if this option is not specified, only public repositories are supportedstring
) License copyright owner. Default: defaults to the value of authorName or “” if authorName
is undefined.string
) The copyright years to put in the LICENSE file. Default: current yearboolean
) Use dependabot to handle dependency upgrades. Default: false[github.DependabotOptions](#projen-github-dependabotoptions)
) Options for dependabot. Default: default optionsboolean
) Use github workflows to handle dependency upgrades. Default: true[javascript.UpgradeDependenciesOptions](#projen-javascript-upgradedependenciesoptions)
) Options for UpgradeDependencies
. Default: default optionsArray</code>) Additional entries to .gitignore. __*Optional*__
boolean
) Setup jest unit tests. Default: true[javascript.JestOptions](#projen-javascript-jestoptions)
) Jest options. Default: default optionsboolean
) Automatically update files modified during builds to pull-request branches. Default: trueArray</code>) Additional entries to .npmignore. __*Optional*__
boolean
) Defines an .npmignore file. Normally this is only needed for libraries that are packaged as tarballs. Default: true[IgnoreFileOptions](#projen-ignorefileoptions)
) Configuration options for .npmignore file. Optionalboolean
) Defines a package
task that will produce an npm tarball under the artifacts directory (e.g. dist
). Default: trueboolean
) Setup prettier. Default: false[javascript.PrettierOptions](#projen-javascript-prettieroptions)
) Prettier options. Default: default optionsboolean
) Indicates of “projen” should be installed as a devDependency. Default: trueboolean
) Generate (once) .projenrc.js (in JavaScript). Set to false
in order to disable .projenrc.js generation. Default: true if projenrcJson is false[javascript.ProjenrcOptions](#projen-javascript-projenrcoptions)
) Options for .projenrc.js. Default: default optionsstring
) Version of projen to install. Default: Defaults to the latest version.boolean
) Include a GitHub pull request template. Default: trueArray</code>) The contents of the pull request template. __*Default*__: default content
boolean
) Add release management to this project. Default: true (false for subprojects)boolean
) Automatically release to npm when new versions are introduced. Default: falseboolean
) DEPRECATED: renamed to release
. Default: true if not a subprojectArray<[github.workflows.JobStep](#projen-github-workflows-jobstep)>
) Workflow steps to use in order to bootstrap this repo. Default: “yarn install –frozen-lockfile && yarn projen”[github.GitIdentity](#projen-github-gitidentity)
) The git identity to use in workflows. Default: GitHub Actionsstring
) The node version to use in GitHub workflows. Default: same as minNodeVersion
boolean
) Enable Node.js package cache in GitHub workflows. Default: falseboolean
) Do not generate a tsconfig.json
file (used by jsii projects since tsconfig.json is generated by the jsii compiler). Default: falseboolean
) Do not generate a tsconfig.dev.json
file. Default: falseboolean
) Docgen by Typedoc. Default: falsestring
) Docs directory. Default: “docs”string
) The .d.ts file that includes the type declarations for this module. Default: .d.ts file derived from the project’s entrypoint (usually lib/index.d.ts)boolean
) Setup eslint. Default: true[javascript.EslintOptions](#projen-javascript-eslintoptions)
) Eslint options. Default: opinionated default optionsstring
) Typescript artifacts output directory. Default: “lib”boolean
) Use TypeScript for your projenrc file (.projenrc.ts
). Default: false[typescript.ProjenrcOptions](#projen-typescript-projenrcoptions)
) Options for .projenrc.ts. Optionalboolean
) Generate one-time sample in src/
and test/
if there are no files there. Default: truestring
) Typescript sources directory. Default: “src”string
) Jest tests directory. Tests files should be named xxx.test.ts
. Default: “test”[javascript.TypescriptConfigOptions](#projen-javascript-typescriptconfigoptions)
) Custom TSConfig. Default: default options[javascript.TypescriptConfigOptions](#projen-javascript-typescriptconfigoptions)
) Custom tsconfig options for the development tsconfig.json file (used for testing). Default: use the production tsconfig optionsstring
) The name of the development tsconfig.json file. Default: “tsconfig.dev.json”string
) TypeScript version to use. Default: “latest”string
) The name of the library author.string
) Email or URL of the library author.string
) Git repository URL.boolean
) Automatically run API compatibility test against the latest version published to npm after compilation. Default: falsestring
) Name of the ignore file for API compatibility tests. Default: “.compatignore”boolean
) Emit a compressed version of the assembly. Default: falsestring
) File path for generated docs. Default: “API.md”[cdk.JsiiDotNetTarget](#projen-cdk-jsiidotnettarget)
) No description OptionalArray</code>) Accepts a list of glob patterns. __*Optional*__
string
) Version of the jsii compiler to use. Default: “1.x”[cdk.JsiiGoTarget](#projen-cdk-jsiigotarget)
) Publish Go bindings to a git repository. Default: no publishing[cdk.JsiiJavaTarget](#projen-cdk-jsiijavatarget)
) Publish to maven. Default: no publishing[cdk.JsiiDotNetTarget](#projen-cdk-jsiidotnettarget)
) Publish to NuGet. Default: no publishing[cdk.JsiiPythonTarget](#projen-cdk-jsiipythontarget)
) Publish to pypi. Default: no publishing[cdk.JsiiPythonTarget](#projen-cdk-jsiipythontarget)
) No description Optionalstring
) No description Default: “.”[cdk.Catalog](#projen-cdk-catalog)
) Libraries will be picked up by the construct catalog when they are published to npm as jsii modules and will be published under:. Default: new version will be announcedstring
) Minimum target version this library is tested against.boolean
) Use pinned version instead of caret version for cdk8s-plus-17. Default: falseboolean
) Use pinned version instead of caret version for CDK8s. Default: falsestring
) constructs verion. Default: “3.3.196”boolean
) Use pinned version instead of caret version for constructs. Default: falseboolean
) Automatically adds an cdk8s.IntegrationTest
for each .integ.ts
app in your test directory. If this is disabled, you can manually add an cdk8s.AutoDiscover
component to your project. Default: trueName | Type | Description |
---|---|---|
cdk8sVersion🔹 | string |
The CDK8s version this app is using. |
constructsVersion🔹 | string |
The constructs version this app is using. |
CDK8S integration test.
Submodule: cdk8s
Extends: cdk.IntegrationTestBase
new cdk8s.IntegrationTest(project: Project, options: IntegrationTestOptions)
[Project](#projen-project)
) No description[cdk8s.IntegrationTestOptions](#projen-cdk8s-integrationtestoptions)
) No description
string
) A path from the project root directory to a TypeScript file which contains the integration test app.string
) The path of the tsconfig.json file to use when running integration test cdk apps.string
) Name of the integration test. Default: Derived from the entrypoint filename.Discovers and creates integration tests from files in the test root.
Submodule: cdk8s
Extends: cdk.IntegrationTestAutoDiscoverBase
new cdk8s.IntegrationTestAutoDiscover(project: Project, options: IntegrationTestAutoDiscoverOptions)
[Project](#projen-project)
) No description[cdk8s.IntegrationTestAutoDiscoverOptions](#projen-cdk8s-integrationtestautodiscoveroptions)
) No description
string
) Test source tree.string
) Path to the tsconfig file to use for integration tests.CDKTF construct library project.
A multi-language (jsii) construct library which vends constructs designed to use within the CDK for Terraform (CDKTF), with a friendly workflow and automatic publishing to the construct catalog.
Submodule: cdktf
Extends: cdk.ConstructLibrary
new cdktf.ConstructLibraryCdktf(options: ConstructLibraryCdktfOptions)
[cdktf.ConstructLibraryCdktfOptions](#projen-cdktf-constructlibrarycdktfoptions)
) No description
string
) This is the name of your project.boolean
) Whether to commit the managed files by default. Default: true[IgnoreFileOptions](#projen-ignorefileoptions)
) Configuration options for .gitignore file. Optional[GitOptions](#projen-gitoptions)
) Configuration options for git. Optional[LoggerOptions](#projen-loggeroptions)
) Configure logging options such as verbosity. Default: {}string
) The root directory of the project. Default: “.”[Project](#projen-project)
) The parent project, if this project is part of a bigger project. Optionalstring
) The shell command to use in order to run the projen CLI. Default: “npx projen”boolean
) Generate (once) .projenrc.json (in JSON). Set to false
in order to disable .projenrc.json generation. Default: false[ProjenrcJsonOptions](#projen-projenrcjsonoptions)
) Options for .projenrc.json. Default: default optionsboolean
) Use renovatebot to handle dependency upgrades. Default: false[RenovatebotOptions](#projen-renovatebotoptions)
) Options for renovatebot. Default: default options[github.AutoApproveOptions](#projen-github-autoapproveoptions)
) Enable and configure the ‘auto approve’ workflow. Default: auto approve is disabledboolean
) Enable automatic merging on GitHub. Default: true[github.AutoMergeOptions](#projen-github-automergeoptions)
) Configure options for automatic merging on GitHub. Default: see defaults in AutoMergeOptions
boolean
) Add a clobber
task which resets the repo to origin. Default: true, but false for subprojectsboolean
) Add a VSCode development environment (used for GitHub Codespaces). Default: falseboolean
) Enable GitHub integration. Default: true[github.GitHubOptions](#projen-github-githuboptions)
) Options for GitHub integration. Default: see GitHubOptionsboolean
) Add a Gitpod development environment. Default: falseboolean
) Whether mergify should be enabled on this repository or not. Default: true[github.MergifyOptions](#projen-github-mergifyoptions)
) Options for mergify. Default: default options[ProjectType](#projen-projecttype)
) Which type of project this is (library/app). Default: ProjectType.UNKNOWN[github.GithubCredentials](#projen-github-githubcredentials)
) Choose a method of providing GitHub API access for projen workflows. Default: use a personal access token named PROJEN_GITHUB_TOKENstring
) The name of a secret which includes a GitHub Personal Access Token to be used by projen workflows. Default: “PROJEN_GITHUB_TOKEN”[SampleReadmeProps](#projen-samplereadmeprops)
) The README setup. Default: { filename: ‘README.md’, contents: ‘# replace this’ }boolean
) Auto-close of stale issues and pull request. Default: false[github.StaleOptions](#projen-github-staleoptions)
) Auto-close stale issues and pull requests. Default: see defaults in StaleOptions
boolean
) Enable VSCode integration. Default: trueboolean
) Allow the project to include peerDependencies
and bundledDependencies
. Default: truestring
) Author’s e-mail. Optionalstring
) Author’s name. Optionalboolean
) Is the author an organization. Optionalstring
) Author’s URL / Website. Optionalboolean
) Automatically add all executables under the bin
directory to your package.json
file under the bin
section. Default: trueMap<string, string>
) Binary programs vended with your module. Optionalstring
) The email address to which issues should be reported. Optionalstring
) The url to your project’s issue tracker. OptionalArray</code>) List of dependencies to bundle into this module. __*Optional*__
[javascript.CodeArtifactOptions](#projen-javascript-codeartifactoptions)
) Options for npm packages using AWS CodeArtifact. Default: undefinedArray</code>) Runtime dependencies of this module. __*Default*__: []
string
) The description is just a string that helps people understand the purpose of the package. OptionalArray</code>) Build dependencies for this module. __*Default*__: []
string
) Module entrypoint (main
in package.json
). Default: “lib/index.js”string
) Package’s Homepage / Website. OptionalArray</code>) Keywords to include in `package.json`. __*Optional*__
string
) License’s SPDX identifier. Default: “Apache-2.0”boolean
) Indicates if a license should be added. Default: truestring
) Minimum node.js version to require via engines
(inclusive). Default: no maxstring
) Minimum Node.js version to require via package.json engines
(inclusive). Default: no “engines” specified[javascript.NpmAccess](#projen-javascript-npmaccess)
) Access level of the npm package. Default: for scoped packages (e.g. foo@bar
), the default is NpmAccess.RESTRICTED
, for non-scoped packages, the default is NpmAccess.PUBLIC
.string
) The host name of the npm registry to publish to. Optionalstring
) The base URL of the npm package registry. Default: “https://registry.npmjs.org”string
) GitHub secret which contains the NPM token to use when publishing packages. Default: “NPM_TOKEN”[javascript.NodePackageManager](#projen-javascript-nodepackagemanager)
) The Node Package Manager used to execute scripts. Default: NodePackageManager.YARNstring
) The “name” in package.json. Default: defaults to project name[javascript.PeerDependencyOptions](#projen-javascript-peerdependencyoptions)
) Options for peerDeps
. OptionalArray</code>) Peer dependencies for this module. __*Default*__: []
string
) The version of PNPM to use if using PNPM as a package manager. Default: “7”string
) The repository is the location where the actual code for your package lives. Optionalstring
) If the package.json for your package is not in the root directory (for example if it is part of a monorepo), you can specify the directory in which it lives. OptionalArray<[javascript.ScopedPackagesOptions](#projen-javascript-scopedpackagesoptions)>
) Options for privately hosted scoped packages. Default: fetch all scoped packages from the public npm registryMap<string, string>
) npm scripts to include. Default: {}string
) Package’s Stability. Optionalstring
) Version requirement of publib
which is used to publish modules to npm. Default: “latest”number
) Major version to release from the default branch. Default: Major version is not enforced.number
) Minimal Major version to release. Default: No minimum version is being enforcedstring
) The npmDistTag to use when publishing from the default branch. Default: “latest”Array<[github.workflows.JobStep](#projen-github-workflows-jobstep)>
) Steps to execute after build as part of the release workflow. Default: []string
) Bump versions from the default branch as pre-releases (e.g. “beta”, “alpha”, “pre”). Default: normal semantic versionsboolean
) Instead of actually publishing to package managers, just print the publishing command. Default: falseboolean
) Define publishing tasks that can be executed manually as well as workflows. Default: falseMap<string, [release.BranchOptions](#projen-release-branchoptions)>
) Defines additional release branches. Default: no additional branches are used for release. you can use addBranch()
to add additional branches.boolean
) Automatically release new versions every commit to one of branches in releaseBranches
. Default: trueboolean
) Create a github issue on every failed publishing task. Default: falsestring
) The label to apply to issues indicating publish failures. Default: “failed-release”string
) CRON schedule to trigger new releases. Default: no scheduled releasesstring
) Automatically add the given prefix to release tags. Useful if you are releasing on multiple branches with overlapping version numbers. Default: “v”[release.ReleaseTrigger](#projen-release-releasetrigger)
) The release trigger to use. Default: Continuous releases (ReleaseTrigger.continuous()
)string
) The name of the default release workflow. Default: “Release”Array<[github.workflows.JobStep](#projen-github-workflows-jobstep)>
) A set of workflow steps to execute in order to setup the workflow container. OptionalMap<string, any>
) Custom configuration used when creating changelog with standard-version package. Default: standard configuration applicable for GitHub repositoriesstring
) Container image to use for GitHub workflows. Default: default imageArray</code>) Github Runner selection labels. __*Default*__: ["ubuntu-latest"]
string
) The name of the main release branch.string
) A directory which will contain build artifacts. Default: “dist”boolean
) Automatically approve deps upgrade PRs, allowing them to be merged by mergify (if configued). Default: trueboolean
) Define a GitHub workflow for building PRs. Default: true if not a subproject[github.workflows.Triggers](#projen-github-workflows-triggers)
) Build workflow triggers. Default: “{ pullRequest: {}, workflowDispatch: {} }”[javascript.BundlerOptions](#projen-javascript-bundleroptions)
) Options for Bundler
. Optionalboolean
) Define a GitHub workflow step for sending code coverage metrics to https://codecov.io/ Uses codecov/codecov-action@v3 A secret is required for private repos. Configured with @codeCovTokenSecret. Default: falsestring
) Define the secret name for a specified https://codecov.io/ token A secret is required to send coverage for private repositories. Default: if this option is not specified, only public repositories are supportedstring
) License copyright owner. Default: defaults to the value of authorName or “” if authorName
is undefined.string
) The copyright years to put in the LICENSE file. Default: current yearboolean
) Use dependabot to handle dependency upgrades. Default: false[github.DependabotOptions](#projen-github-dependabotoptions)
) Options for dependabot. Default: default optionsboolean
) Use github workflows to handle dependency upgrades. Default: true[javascript.UpgradeDependenciesOptions](#projen-javascript-upgradedependenciesoptions)
) Options for UpgradeDependencies
. Default: default optionsArray</code>) Additional entries to .gitignore. __*Optional*__
boolean
) Setup jest unit tests. Default: true[javascript.JestOptions](#projen-javascript-jestoptions)
) Jest options. Default: default optionsboolean
) Automatically update files modified during builds to pull-request branches. Default: trueArray</code>) Additional entries to .npmignore. __*Optional*__
boolean
) Defines an .npmignore file. Normally this is only needed for libraries that are packaged as tarballs. Default: true[IgnoreFileOptions](#projen-ignorefileoptions)
) Configuration options for .npmignore file. Optionalboolean
) Defines a package
task that will produce an npm tarball under the artifacts directory (e.g. dist
). Default: trueboolean
) Setup prettier. Default: false[javascript.PrettierOptions](#projen-javascript-prettieroptions)
) Prettier options. Default: default optionsboolean
) Indicates of “projen” should be installed as a devDependency. Default: trueboolean
) Generate (once) .projenrc.js (in JavaScript). Set to false
in order to disable .projenrc.js generation. Default: true if projenrcJson is false[javascript.ProjenrcOptions](#projen-javascript-projenrcoptions)
) Options for .projenrc.js. Default: default optionsstring
) Version of projen to install. Default: Defaults to the latest version.boolean
) Include a GitHub pull request template. Default: trueArray</code>) The contents of the pull request template. __*Default*__: default content
boolean
) Add release management to this project. Default: true (false for subprojects)boolean
) Automatically release to npm when new versions are introduced. Default: falseboolean
) DEPRECATED: renamed to release
. Default: true if not a subprojectArray<[github.workflows.JobStep](#projen-github-workflows-jobstep)>
) Workflow steps to use in order to bootstrap this repo. Default: “yarn install –frozen-lockfile && yarn projen”[github.GitIdentity](#projen-github-gitidentity)
) The git identity to use in workflows. Default: GitHub Actionsstring
) The node version to use in GitHub workflows. Default: same as minNodeVersion
boolean
) Enable Node.js package cache in GitHub workflows. Default: falseboolean
) Do not generate a tsconfig.json
file (used by jsii projects since tsconfig.json is generated by the jsii compiler). Default: falseboolean
) Do not generate a tsconfig.dev.json
file. Default: falseboolean
) Docgen by Typedoc. Default: falsestring
) Docs directory. Default: “docs”string
) The .d.ts file that includes the type declarations for this module. Default: .d.ts file derived from the project’s entrypoint (usually lib/index.d.ts)boolean
) Setup eslint. Default: true[javascript.EslintOptions](#projen-javascript-eslintoptions)
) Eslint options. Default: opinionated default optionsstring
) Typescript artifacts output directory. Default: “lib”boolean
) Use TypeScript for your projenrc file (.projenrc.ts
). Default: false[typescript.ProjenrcOptions](#projen-typescript-projenrcoptions)
) Options for .projenrc.ts. Optionalboolean
) Generate one-time sample in src/
and test/
if there are no files there. Default: truestring
) Typescript sources directory. Default: “src”string
) Jest tests directory. Tests files should be named xxx.test.ts
. Default: “test”[javascript.TypescriptConfigOptions](#projen-javascript-typescriptconfigoptions)
) Custom TSConfig. Default: default options[javascript.TypescriptConfigOptions](#projen-javascript-typescriptconfigoptions)
) Custom tsconfig options for the development tsconfig.json file (used for testing). Default: use the production tsconfig optionsstring
) The name of the development tsconfig.json file. Default: “tsconfig.dev.json”string
) TypeScript version to use. Default: “latest”string
) The name of the library author.string
) Email or URL of the library author.string
) Git repository URL.boolean
) Automatically run API compatibility test against the latest version published to npm after compilation. Default: falsestring
) Name of the ignore file for API compatibility tests. Default: “.compatignore”boolean
) Emit a compressed version of the assembly. Default: falsestring
) File path for generated docs. Default: “API.md”[cdk.JsiiDotNetTarget](#projen-cdk-jsiidotnettarget)
) No description OptionalArray</code>) Accepts a list of glob patterns. __*Optional*__
string
) Version of the jsii compiler to use. Default: “1.x”[cdk.JsiiGoTarget](#projen-cdk-jsiigotarget)
) Publish Go bindings to a git repository. Default: no publishing[cdk.JsiiJavaTarget](#projen-cdk-jsiijavatarget)
) Publish to maven. Default: no publishing[cdk.JsiiDotNetTarget](#projen-cdk-jsiidotnettarget)
) Publish to NuGet. Default: no publishing[cdk.JsiiPythonTarget](#projen-cdk-jsiipythontarget)
) Publish to pypi. Default: no publishing[cdk.JsiiPythonTarget](#projen-cdk-jsiipythontarget)
) No description Optionalstring
) No description Default: “.”[cdk.Catalog](#projen-cdk-catalog)
) Libraries will be picked up by the construct catalog when they are published to npm as jsii modules and will be published under:. Default: new version will be announcedstring
) Minimum target version this library is tested against.string
) Construct version to use. Default: “^10.0.12”Circleci Class to manage .circleci/config.yml
. Check projen’s docs for more information.
Submodule: circleci
Extends: Component
new circleci.Circleci(project: Project, options?: CircleCiProps)
[Project](#projen-project)
) No description[circleci.CircleCiProps](#projen-circleci-circleciprops)
) No description
Array<[circleci.Job](#projen-circleci-job)>
) List of Jobs to create unique steps per pipeline, e.g. json jobs: [{ identifier: "compile", docker: { image: "golang:alpine" } steps: ["checkout", run: {command: "go build ."}] }]
. OptionalMap<string, string>
) Contains a map of CirclCi Orbs json orbs: { node: "circleci/node@5.0.1" slack: "circleci/slack@4.8.3" }
. Optionalboolean
) The setup field enables you to conditionally trigger configurations from outside the primary .circleci parent directory, update pipeline parameters, or generate customized configurations. Optionalnumber
) pipeline version. Default: 2.1Array<[circleci.Workflow](#projen-circleci-workflow)>
) List of Workflows of pipeline, e.g. json workflows: { { identifier: "build", jobs: [{ identifier: "node/install", context: ["npm"], }] } }
. OptionalName | Type | Description |
---|---|---|
file🔹 | [YamlFile](#projen-yamlfile) |
The yaml file for the Circleci pipeline. |
Add a Circleci Orb to pipeline.
Will throw error if the orb already exists
addOrb(name: string, orb: string): void
string
) No descriptionstring
) No descriptionadd new workflow to existing pipeline.
addWorkflow(workflow: Workflow): void
[circleci.Workflow](#projen-circleci-workflow)
) No description
string
) name of dynamic key *.Array<[circleci.WorkflowJob](#projen-circleci-workflowjob)>
) No description OptionalArray<[circleci.Triggers](#projen-circleci-triggers)>
) No description Optionalany
) when is too dynamic to be casted to interfaces. OptionalAuto approve pull requests that meet a criteria.
Submodule: github
Extends: Component
new github.AutoApprove(github: GitHub, options?: AutoApproveOptions)
[github.GitHub](#projen-github-github)
) No description[github.AutoApproveOptions](#projen-github-autoapproveoptions)
) No description
Array</code>) Only pull requests authored by these Github usernames will be auto-approved. __*Default*__: ['github-bot']
string
) Only pull requests with this label will be auto-approved. Default: ‘auto-approve’Array</code>) Github Runner selection labels. __*Default*__: ["ubuntu-latest"]
string
) A GitHub secret name which contains a GitHub Access Token with write permissions for the pull_request
scope. Default: “GITHUB_TOKEN”Name | Type | Description |
---|---|---|
label🔹 | string |
Sets up mergify to merging approved pull requests.
If buildJob
is specified, the specified GitHub workflow job ID is required
to succeed in order for the PR to be merged.
approvedReviews
specified the number of code review approvals required for
the PR to be merged.
Submodule: github
Extends: Component
new github.AutoMerge(github: GitHub, options?: AutoMergeOptions)
[github.GitHub](#projen-github-github)
) No description[github.AutoMergeOptions](#projen-github-automergeoptions)
) No description
number
) Number of approved code reviews. Default: 1Array</code>) List of labels that will prevent auto-merging. __*Default*__: ['do-not-merge']
Adds conditions to the auto merge rule.
addConditions(...conditions: string[]): void
string
) The conditions to add (mergify syntax).Adds conditions that will be rendered only during synthesis.
addConditionsLater(later: IAddConditionsLater): void
[github.IAddConditionsLater](#projen-github-iaddconditionslater)
) The later.Defines dependabot configuration for node projects.
Since module versions are managed in projen, the versioning strategy will be configured to “lockfile-only” which means that only updates that can be done on the lockfile itself will be proposed.
Submodule: github
Extends: Component
new github.Dependabot(github: GitHub, options?: DependabotOptions)
[github.GitHub](#projen-github-github)
) No description[github.DependabotOptions](#projen-github-dependabotoptions)
) No description
Array<[github.DependabotIgnore](#projen-github-dependabotignore)>
) You can use the ignore
option to customize which dependencies are updated. Default: []boolean
) Ignores updates to projen
. Default: trueArray</code>) List of labels to apply to the created PR's. __*Optional*__
Map<string, [github.DependabotRegistry](#projen-github-dependabotregistry)>
) Map of package registries to use. Default: use public registries[github.DependabotScheduleInterval](#projen-github-dependabotscheduleinterval)
) How often to check for new versions and raise pull requests. Default: ScheduleInterval.DAILY[github.VersioningStrategy](#projen-github-versioningstrategy)
) The strategy to use when edits manifest and lock files. Default: VersioningStrategy.LOCKFILE_ONLY The default is to only update the lock file because package.json is controlled by projen and any outside updates will fail the build.Name | Type | Description |
---|---|---|
config🔹 | any |
The raw dependabot configuration. |
ignoresProjen🔹 | boolean |
Whether or not projen is also upgraded in this config,. |
Ignores a dependency from automatic updates.
addIgnore(dependencyName: string, ...versions: string[]): void
string
) Use to ignore updates for dependencies with matching names, optionally using *
to match zero or more characters.string
) Use to ignore specific versions or ranges of versions.Submodule: github
Extends: Component
new github.GitHub(project: Project, options?: GitHubOptions)
[Project](#projen-project)
) No description[github.GitHubOptions](#projen-github-githuboptions)
) No description
boolean
) Download files in LFS in workflows. Default: true if the associated project has lfsPatterns
, false
otherwiseboolean
) Whether mergify should be enabled on this repository or not. Default: true[github.MergifyOptions](#projen-github-mergifyoptions)
) Options for Mergify. Default: default options[github.GithubCredentials](#projen-github-githubcredentials)
) Choose a method of providing GitHub API access for projen workflows. Default: use a personal access token named PROJEN_GITHUB_TOKENstring
) The name of a secret which includes a GitHub Personal Access Token to be used by projen workflows. Default: “PROJEN_GITHUB_TOKEN”boolean
) Add a workflow that performs basic checks for pull requests, like validating that PRs follow Conventional Commits. Default: true[github.PullRequestLintOptions](#projen-github-pullrequestlintoptions)
) Options for configuring a pull request linter. Default: see defaults in PullRequestLintOptions
boolean
) Enables GitHub workflows. Default: trueName | Type | Description |
---|---|---|
actions🔹 | [github.GitHubActionsProvider](#projen-github-githubactionsprovider) |
|
downloadLfs🔹 | boolean |
Whether downloading from LFS is enabled for this GitHub project. |
projenCredentials🔹 | [github.GithubCredentials](#projen-github-githubcredentials) |
GitHub API authentication method used by projen workflows. |
workflows🔹 | Array<[github.GithubWorkflow](#projen-github-githubworkflow)> |
All workflows. |
workflowsEnabled🔹 | boolean |
Are workflows enabled? |
mergify?🔹 | [github.Mergify](#projen-github-mergify) |
The Mergify configured on this repository.Optional |
addDependabot(options?: DependabotOptions): Dependabot
[github.DependabotOptions](#projen-github-dependabotoptions)
) No description
Array<[github.DependabotIgnore](#projen-github-dependabotignore)>
) You can use the ignore
option to customize which dependencies are updated. Default: []boolean
) Ignores updates to projen
. Default: trueArray</code>) List of labels to apply to the created PR's. __*Optional*__
Map<string, [github.DependabotRegistry](#projen-github-dependabotregistry)>
) Map of package registries to use. Default: use public registries[github.DependabotScheduleInterval](#projen-github-dependabotscheduleinterval)
) How often to check for new versions and raise pull requests. Default: ScheduleInterval.DAILY[github.VersioningStrategy](#projen-github-versioningstrategy)
) The strategy to use when edits manifest and lock files. Default: VersioningStrategy.LOCKFILE_ONLY The default is to only update the lock file because package.json is controlled by projen and any outside updates will fail the build.Returns:
[github.Dependabot](#projen-github-dependabot)
addPullRequestTemplate(...content: string[]): PullRequestTemplate
string
) No descriptionReturns:
[github.PullRequestTemplate](#projen-github-pullrequesttemplate)
Adds a workflow to the project.
addWorkflow(name: string): GithubWorkflow
string
) Name of the workflow.Returns:
[github.GithubWorkflow](#projen-github-githubworkflow)
Finds a GitHub workflow by name.
Returns undefined
if the workflow cannot be found.
tryFindWorkflow(name: string): GithubWorkflow
string
) The name of the GitHub workflow.Returns:
[github.GithubWorkflow](#projen-github-githubworkflow)
Returns the GitHub
component of a project or undefined
if the project does not have a GitHub component.
static of(project: Project): GitHub
[Project](#projen-project)
) No descriptionReturns:
[github.GitHub](#projen-github-github)
Manage the versions used for GitHub Actions used in steps.
Submodule: github
new github.GitHubActionsProvider()
Resolve an action name to the version that should be used, taking into account any overrides.
get(action: string): string
string
) No descriptionReturns:
string
Define an override for a given action.
Specify the action name without a version to override all usages of the action. You can also override a specific action version, by providing the version string. Specific overrides take precedence over overrides without a version.
If an override for the same action name is set multiple times, the last override is used.
set(action: string, override: string): void
string
) No descriptionstring
) No descriptionGitHub-based project.
Submodule: github
Extends: Project
new github.GitHubProject(options: GitHubProjectOptions)
[github.GitHubProjectOptions](#projen-github-githubprojectoptions)
) No description
string
) This is the name of your project.boolean
) Whether to commit the managed files by default. Default: true[IgnoreFileOptions](#projen-ignorefileoptions)
) Configuration options for .gitignore file. Optional[GitOptions](#projen-gitoptions)
) Configuration options for git. Optional[LoggerOptions](#projen-loggeroptions)
) Configure logging options such as verbosity. Default: {}string
) The root directory of the project. Default: “.”[Project](#projen-project)
) The parent project, if this project is part of a bigger project. Optionalstring
) The shell command to use in order to run the projen CLI. Default: “npx projen”boolean
) Generate (once) .projenrc.json (in JSON). Set to false
in order to disable .projenrc.json generation. Default: false[ProjenrcJsonOptions](#projen-projenrcjsonoptions)
) Options for .projenrc.json. Default: default optionsboolean
) Use renovatebot to handle dependency upgrades. Default: false[RenovatebotOptions](#projen-renovatebotoptions)
) Options for renovatebot. Default: default options[github.AutoApproveOptions](#projen-github-autoapproveoptions)
) Enable and configure the ‘auto approve’ workflow. Default: auto approve is disabledboolean
) Enable automatic merging on GitHub. Default: true[github.AutoMergeOptions](#projen-github-automergeoptions)
) Configure options for automatic merging on GitHub. Default: see defaults in AutoMergeOptions
boolean
) Add a clobber
task which resets the repo to origin. Default: true, but false for subprojectsboolean
) Add a VSCode development environment (used for GitHub Codespaces). Default: falseboolean
) Enable GitHub integration. Default: true[github.GitHubOptions](#projen-github-githuboptions)
) Options for GitHub integration. Default: see GitHubOptionsboolean
) Add a Gitpod development environment. Default: falseboolean
) Whether mergify should be enabled on this repository or not. Default: true[github.MergifyOptions](#projen-github-mergifyoptions)
) Options for mergify. Default: default options[ProjectType](#projen-projecttype)
) Which type of project this is (library/app). Default: ProjectType.UNKNOWN[github.GithubCredentials](#projen-github-githubcredentials)
) Choose a method of providing GitHub API access for projen workflows. Default: use a personal access token named PROJEN_GITHUB_TOKENstring
) The name of a secret which includes a GitHub Personal Access Token to be used by projen workflows. Default: “PROJEN_GITHUB_TOKEN”[SampleReadmeProps](#projen-samplereadmeprops)
) The README setup. Default: { filename: ‘README.md’, contents: ‘# replace this’ }boolean
) Auto-close of stale issues and pull request. Default: false[github.StaleOptions](#projen-github-staleoptions)
) Auto-close stale issues and pull requests. Default: see defaults in StaleOptions
boolean
) Enable VSCode integration. Default: trueName | Type | Description |
---|---|---|
projectType⚠️ | [ProjectType](#projen-projecttype) |
|
autoApprove?⚠️ | [github.AutoApprove](#projen-github-autoapprove) |
Auto approve set up for this project. Optional |
devContainer?⚠️ | [vscode.DevContainer](#projen-vscode-devcontainer) |
Access for .devcontainer.json (used for GitHub Codespaces). Optional |
github?⚠️ | [github.GitHub](#projen-github-github) |
Access all github components. Optional |
gitpod?⚠️ | [Gitpod](#projen-gitpod) |
Access for Gitpod. Optional |
vscode?⚠️ | [vscode.VsCode](#projen-vscode-vscode) |
Access all VSCode components. Optional |
Marks the provided file(s) as being generated.
This is achieved using the github-linguist attributes. Generated files do not count against the repository statistics and language breakdown.
annotateGenerated(glob: string): void
string
) the glob pattern to match (could be a file path).Represents a method of providing GitHub API access for projen workflows.
Submodule: github
Name | Type | Description |
---|---|---|
setupSteps🔹 | Array<[github.workflows.JobStep](#projen-github-workflows-jobstep)> |
Setup steps to obtain GitHub credentials. |
tokenRef🔹 | string |
The value to use in a workflow when a GitHub token is expected. |
Provide API access through a GitHub App.
The GitHub App must be installed on the GitHub repo, its App ID and a private key must be added as secrets to the repo. The name of the secrets can be specified here.
static fromApp(options?: GithubCredentialsAppOptions): GithubCredentials
[github.GithubCredentialsAppOptions](#projen-github-githubcredentialsappoptions)
) No description
string
) No description Optional[github.workflows.AppPermissions](#projen-github-workflows-apppermissions)
) The permissions granted to the token. Default: all permissions granted to the appstring
) No description OptionalReturns:
[github.GithubCredentials](#projen-github-githubcredentials)
Provide API access through a GitHub personal access token.
The token must be added as a secret to the GitHub repo, and the name of the secret can be specified here.
static fromPersonalAccessToken(options?: GithubCredentialsPersonalAccessTokenOptions): GithubCredentials
[github.GithubCredentialsPersonalAccessTokenOptions](#projen-github-githubcredentialspersonalaccesstokenoptions)
) No description
string
) No description OptionalReturns:
[github.GithubCredentials](#projen-github-githubcredentials)
Workflow for GitHub.
A workflow is a configurable automated process made up of one or more jobs.
Submodule: github
Extends: Component
new github.GithubWorkflow(github: GitHub, name: string, options?: GithubWorkflowOptions)
[github.GitHub](#projen-github-github)
) No descriptionstring
) No description[github.GithubWorkflowOptions](#projen-github-githubworkflowoptions)
) No description
string
) Concurrency ensures that only a single job or workflow using the same concurrency group will run at a time. Default: disabledboolean
) Force the creation of the workflow even if workflows
is disabled in GitHub
. Default: falseName | Type | Description |
---|---|---|
name🔹 | string |
The name of the workflow. |
projenCredentials🔹 | [github.GithubCredentials](#projen-github-githubcredentials) |
GitHub API authentication method used by projen workflows. |
concurrency?🔹 | string |
Concurrency ensures that only a single job or workflow using the same concurrency group will run at a time. Default: disabled |
file?🔹 | [YamlFile](#projen-yamlfile) |
The workflow YAML file. Optional |
runName?🔹 | string |
The name for workflow runs generated from the workflow. Optional |
Adds a single job to the workflow.
addJob(id: string, job: JobCallingReusableWorkflow | Job): void
string
) The job name (unique within the workflow).[github.workflows.JobCallingReusableWorkflow](#projen-github-workflows-jobcallingreusableworkflow) | [github.workflows.Job](#projen-github-workflows-job)
) The job specification.Add jobs to the workflow.
addJobs(jobs: Map<string, JobCallingReusableWorkflow | Job>): void
Map<string, [github.workflows.JobCallingReusableWorkflow](#projen-github-workflows-jobcallingreusableworkflow) | [github.workflows.Job](#projen-github-workflows-job)>
) Jobs to add.Get a single job from the workflow.
getJob(id: string): JobCallingReusableWorkflow | Job
string
) The job name (unique within the workflow).Returns:
[github.workflows.JobCallingReusableWorkflow](#projen-github-workflows-jobcallingreusableworkflow) | [github.workflows.Job](#projen-github-workflows-job)
Add events to triggers the workflow.
on(events: Triggers): void
[github.workflows.Triggers](#projen-github-workflows-triggers)
) The event(s) to trigger the workflow.
[github.workflows.BranchProtectionRuleOptions](#projen-github-workflows-branchprotectionruleoptions)
) Runs your workflow anytime the branch_protection_rule event occurs. Optional[github.workflows.CheckRunOptions](#projen-github-workflows-checkrunoptions)
) Runs your workflow anytime the check_run event occurs. Optional[github.workflows.CheckSuiteOptions](#projen-github-workflows-checksuiteoptions)
) Runs your workflow anytime the check_suite event occurs. Optional[github.workflows.CreateOptions](#projen-github-workflows-createoptions)
) Runs your workflow anytime someone creates a branch or tag, which triggers the create event. Optional[github.workflows.DeleteOptions](#projen-github-workflows-deleteoptions)
) Runs your workflow anytime someone deletes a branch or tag, which triggers the delete event. Optional[github.workflows.DeploymentOptions](#projen-github-workflows-deploymentoptions)
) Runs your workflow anytime someone creates a deployment, which triggers the deployment event. Optional[github.workflows.DeploymentStatusOptions](#projen-github-workflows-deploymentstatusoptions)
) Runs your workflow anytime a third party provides a deployment status, which triggers the deployment_status event. Optional[github.workflows.DiscussionOptions](#projen-github-workflows-discussionoptions)
) Runs your workflow anytime the discussion event occurs. Optional[github.workflows.DiscussionCommentOptions](#projen-github-workflows-discussioncommentoptions)
) Runs your workflow anytime the discussion_comment event occurs. Optional[github.workflows.ForkOptions](#projen-github-workflows-forkoptions)
) Runs your workflow anytime when someone forks a repository, which triggers the fork event. Optional[github.workflows.GollumOptions](#projen-github-workflows-gollumoptions)
) Runs your workflow when someone creates or updates a Wiki page, which triggers the gollum event. Optional[github.workflows.IssueCommentOptions](#projen-github-workflows-issuecommentoptions)
) Runs your workflow anytime the issue_comment event occurs. Optional[github.workflows.IssuesOptions](#projen-github-workflows-issuesoptions)
) Runs your workflow anytime the issues event occurs. Optional[github.workflows.LabelOptions](#projen-github-workflows-labeloptions)
) Runs your workflow anytime the label event occurs. Optional[github.workflows.MergeGroupOptions](#projen-github-workflows-mergegroupoptions)
) Runs your workflow when a pull request is added to a merge queue, which adds the pull request to a merge group. Optional[github.workflows.MilestoneOptions](#projen-github-workflows-milestoneoptions)
) Runs your workflow anytime the milestone event occurs. Optional[github.workflows.PageBuildOptions](#projen-github-workflows-pagebuildoptions)
) Runs your workflow anytime someone pushes to a GitHub Pages-enabled branch, which triggers the page_build event. Optional[github.workflows.ProjectOptions](#projen-github-workflows-projectoptions)
) Runs your workflow anytime the project event occurs. Optional[github.workflows.ProjectCardOptions](#projen-github-workflows-projectcardoptions)
) Runs your workflow anytime the project_card event occurs. Optional[github.workflows.ProjectColumnOptions](#projen-github-workflows-projectcolumnoptions)
) Runs your workflow anytime the project_column event occurs. Optional[github.workflows.PublicOptions](#projen-github-workflows-publicoptions)
) Runs your workflow anytime someone makes a private repository public, which triggers the public event. Optional[github.workflows.PullRequestOptions](#projen-github-workflows-pullrequestoptions)
) Runs your workflow anytime the pull_request event occurs. Optional[github.workflows.PullRequestReviewOptions](#projen-github-workflows-pullrequestreviewoptions)
) Runs your workflow anytime the pull_request_review event occurs. Optional[github.workflows.PullRequestReviewCommentOptions](#projen-github-workflows-pullrequestreviewcommentoptions)
) Runs your workflow anytime a comment on a pull request’s unified diff is modified, which triggers the pull_request_review_comment event. Optional[github.workflows.PullRequestTargetOptions](#projen-github-workflows-pullrequesttargetoptions)
) This event runs in the context of the base of the pull request, rather than in the merge commit as the pull_request event does. Optional[github.workflows.PushOptions](#projen-github-workflows-pushoptions)
) Runs your workflow when someone pushes to a repository branch, which triggers the push event. Optional[github.workflows.RegistryPackageOptions](#projen-github-workflows-registrypackageoptions)
) Runs your workflow anytime a package is published or updated. Optional[github.workflows.ReleaseOptions](#projen-github-workflows-releaseoptions)
) Runs your workflow anytime the release event occurs. Optional[github.workflows.RepositoryDispatchOptions](#projen-github-workflows-repositorydispatchoptions)
) You can use the GitHub API to trigger a webhook event called repository_dispatch when you want to trigger a workflow for activity that happens outside of GitHub. OptionalArray<[github.workflows.CronScheduleOptions](#projen-github-workflows-cronscheduleoptions)>
) You can schedule a workflow to run at specific UTC times using POSIX cron syntax. Optional[github.workflows.StatusOptions](#projen-github-workflows-statusoptions)
) Runs your workflow anytime the status of a Git commit changes, which triggers the status event. Optional[github.workflows.WatchOptions](#projen-github-workflows-watchoptions)
) Runs your workflow anytime the watch event occurs. Optional[github.workflows.WorkflowCallOptions](#projen-github-workflows-workflowcalloptions)
) Can be called from another workflow. Optional[github.workflows.WorkflowDispatchOptions](#projen-github-workflows-workflowdispatchoptions)
) You can configure custom-defined input properties, default input values, and required inputs for the event directly in your workflow. Optional[github.workflows.WorkflowRunOptions](#projen-github-workflows-workflowrunoptions)
) This event occurs when a workflow run is requested or completed, and allows you to execute a workflow based on the finished result of another workflow. OptionalRemoves a single job to the workflow.
removeJob(id: string): void
string
) The job name (unique within the workflow).Updates a single job to the workflow.
updateJob(id: string, job: JobCallingReusableWorkflow | Job): void
string
) The job name (unique within the workflow).[github.workflows.JobCallingReusableWorkflow](#projen-github-workflows-jobcallingreusableworkflow) | [github.workflows.Job](#projen-github-workflows-job)
) No descriptionUpdates jobs for this worklow Does a complete replace, it does not try to merge the jobs.
updateJobs(jobs: Map<string, JobCallingReusableWorkflow | Job>): void
Map<string, [github.workflows.JobCallingReusableWorkflow](#projen-github-workflows-jobcallingreusableworkflow) | [github.workflows.Job](#projen-github-workflows-job)>
) Jobs to update.Submodule: github
Extends: Component
new github.Mergify(github: GitHub, options?: MergifyOptions)
[github.GitHub](#projen-github-github)
) No description[github.MergifyOptions](#projen-github-mergifyoptions)
) No description
Array<[github.MergifyQueue](#projen-github-mergifyqueue)>
) No description OptionalArray<[github.MergifyRule](#projen-github-mergifyrule)>
) No description OptionaladdQueue(queue: MergifyQueue): void
[github.MergifyQueue](#projen-github-mergifyqueue)
) No description
Array<string | [github.MergifyConditionalOperator](#projen-github-mergifyconditionaloperator)>
) A list of Conditions string that must match against the pull request for the pull request to be added to the queue.string
) The name of the queue.string
) Merge method to use. Default: “merge”string
) Method to use to update the pull request with its base branch when the speculative check is done in-place. Default: merge
for all merge methods except fast-forward
where rebase
is usedaddRule(rule: MergifyRule): void
[github.MergifyRule](#projen-github-mergifyrule)
) No description
Map<string, any>
) A dictionary made of Actions that will be executed on the matching pull requests.Array<string | [github.MergifyConditionalOperator](#projen-github-mergifyconditionaloperator)>
) A list of Conditions string that must match against the pull request for the rule to be applied.string
) The name of the rule.Configure validations to run on GitHub pull requests.
Only generates a file if at least one linter is configured.
Submodule: github
Extends: Component
new github.PullRequestLint(github: GitHub, options?: PullRequestLintOptions)
[github.GitHub](#projen-github-github)
) No description[github.PullRequestLintOptions](#projen-github-pullrequestlintoptions)
) No description
Array</code>) Github Runner selection labels. __*Default*__: ["ubuntu-latest"]
boolean
) Validate that pull request titles follow Conventional Commits. Default: true[github.SemanticTitleOptions](#projen-github-semantictitleoptions)
) Options for validating the conventional commit title linter. Default: title must start with “feat”, “fix”, or “chore”Template for GitHub pull requests.
Submodule: github
Extends: TextFile
new github.PullRequestTemplate(github: GitHub, options?: PullRequestTemplateOptions)
[github.GitHub](#projen-github-github)
) No description[github.PullRequestTemplateOptions](#projen-github-pullrequesttemplateoptions)
) No description
Array</code>) The contents of the template. __*Default*__: a standard default template will be created.
Warns and then closes issues and PRs that have had no activity for a specified amount of time.
The default configuration will:
Submodule: github
Extends: Component
new github.Stale(github: GitHub, options?: StaleOptions)
[github.GitHub](#projen-github-github)
) No description[github.StaleOptions](#projen-github-staleoptions)
) No description
[github.StaleBehavior](#projen-github-stalebehavior)
) How to handle stale issues. Default: By default, stale issues with no activity will be marked as stale after 60 days and closed within 7 days.[github.StaleBehavior](#projen-github-stalebehavior)
) How to handle stale pull requests. Default: By default, pull requests with no activity will be marked as stale after 14 days and closed within 2 days with relevant comments.Array</code>) Github Runner selection labels. __*Default*__: ["ubuntu-latest"]
A GitHub workflow for common build tasks within a project.
Submodule: github
Extends: github.GithubWorkflow
new github.TaskWorkflow(github: GitHub, options: TaskWorkflowOptions)
[github.GitHub](#projen-github-github)
) No description[github.TaskWorkflowOptions](#projen-github-taskworkflowoptions)
) No description
string
) The workflow name.[github.workflows.JobPermissions](#projen-github-workflows-jobpermissions)
) Permissions for the build job.[Task](#projen-task)
) The main task to be executed.string
) A directory name which contains artifacts to be uploaded (e.g. dist
). If this is set, the contents of this directory will be uploaded as an artifact at the end of the workflow run, even if other steps fail. Default: not setMap<string, any>
) Override for the with
property of the source code checkout step. Default: not setstring
) Adds an ‘if’ condition to the workflow. Optional[github.workflows.ContainerOptions](#projen-github-workflows-containeroptions)
) No description Default: default imageboolean
) Whether to download files from Git LFS for this workflow. Default: Use the setting on the corresponding GitHub projectMap<string, string>
) Workflow environment variables. Default: {}[github.GitIdentity](#projen-github-gitidentity)
) The git identity to use in this workflow. Optionalstring
) The primary job id. Default: “build”Map<string, [github.workflows.JobStepOutput](#projen-github-workflows-jobstepoutput)>
) Mapping of job output names to values/expressions. Default: {}Array<[github.workflows.JobStep](#projen-github-workflows-jobstep)>
) Actions to run after the main build step. Default: not setArray<[github.workflows.JobStep](#projen-github-workflows-jobstep)>
) Steps to run before the main build step. Default: not setArray<[github.workflows.JobStep](#projen-github-workflows-jobstep)>
) Initial steps to run before the source code checkout. Default: not setArray</code>) Github Runner selection labels. __*Default*__: ["ubuntu-latest"]
[github.workflows.Triggers](#projen-github-workflows-triggers)
) The triggers for the workflow. Default: by default workflows can only be triggered by manually.Name | Type | Description |
---|---|---|
jobId🔹 | string |
|
artifactsDirectory?🔹 | string |
Optional |
A set of utility functions for creating GitHub actions in workflows.
Submodule: github
new github.WorkflowActions()
Checks out a repository and applies a git patch that was created using uploadGitPatch
.
static checkoutWithPatch(options?: CheckoutWithPatchOptions): Array<JobStep>
[github.CheckoutWithPatchOptions](#projen-github-checkoutwithpatchoptions)
) Options.
boolean
) Whether LFS is enabled for the GitHub repository. Default: falsestring
) The name of the artifact the patch is stored as. Default: “.repo.patch”string
) Branch or tag name. Default: the default branch is implicitly usedstring
) The repository (owner/repo) to use. Default: the default repository is implicitly usedstring
) A GitHub token to use when checking out the repository. Default: the default GITHUB_TOKEN is implicitly usedReturns:
Array<[github.workflows.JobStep](#projen-github-workflows-jobstep)>
A step that creates a pull request based on the current repo state.
static createPullRequest(options: CreatePullRequestOptions): Array<JobStep>
[github.CreatePullRequestOptions](#projen-github-createpullrequestoptions)
) Options.
string
) Description added to the pull request.string
) The full title used to create the pull request.string
) The name of the workflow that will create the PR.Array</code>) Assignees to add on the PR. __*Default*__: no assignees
string
) Sets the pull request base branch. Default: The branch checked out in the workflow.string
) The pull request branch name. Default: github-actions/${options.workflowName}
[github.GithubCredentials](#projen-github-githubcredentials)
) The job credentials used to create the pull request. Optional[github.GitIdentity](#projen-github-gitidentity)
) The git identity used to create the commit. Default: the default github-actions userArray</code>) Labels to apply on the PR. __*Default*__: no labels.
boolean
) Add Signed-off-by line by the committer at the end of the commit log message. Default: truestring
) The step ID which produces the output which indicates if a patch was created. Default: “create_pr”string
) The name of the step displayed on GitHub. Default: “Create Pull Request”Returns:
Array<[github.workflows.JobStep](#projen-github-workflows-jobstep)>
Configures the git identity (user name and email).
static setupGitIdentity(id: GitIdentity): Array<JobStep>
[github.GitIdentity](#projen-github-gitidentity)
) The identity to use.
string
) The email address of the git user.string
) The name of the user.Returns:
Array<[github.workflows.JobStep](#projen-github-workflows-jobstep)>
Creates a .patch file from the current git diff and uploads it as an artifact. Use checkoutWithPatch
to download and apply in another job.
If a patch was uploaded, the action can optionally fail the job.
static uploadGitPatch(options: UploadGitPatchOptions): Array<JobStep>
[github.UploadGitPatchOptions](#projen-github-uploadgitpatchoptions)
) Options.
string
) The name of the output to emit.string
) The step ID which produces the output which indicates if a patch was created.string
) Fail if a mutation was found and print this error message. Default: do not fail upon mutationstring
) The name of the artifact the patch is stored as. Default: “.repo.patch”string
) The name of the step. Default: “Find mutations”Returns:
Array<[github.workflows.JobStep](#projen-github-workflows-jobstep)>
A set of utility functions for creating jobs in GitHub Workflows.
Submodule: github
new github.WorkflowJobs()
Creates a pull request with the changes of a patch file.
static pullRequestFromPatch(options: PullRequestFromPatchOptions): Job
[github.PullRequestFromPatchOptions](#projen-github-pullrequestfrompatchoptions)
) No description
string
) Description added to the pull request.string
) The full title used to create the pull request.string
) The name of the workflow that will create the PR.Array</code>) Assignees to add on the PR. __*Default*__: no assignees
string
) Sets the pull request base branch. Default: The branch checked out in the workflow.string
) The pull request branch name. Default: github-actions/${options.workflowName}
[github.GithubCredentials](#projen-github-githubcredentials)
) The job credentials used to create the pull request. Optional[github.GitIdentity](#projen-github-gitidentity)
) The git identity used to create the commit. Default: the default github-actions userArray</code>) Labels to apply on the PR. __*Default*__: no labels.
boolean
) Add Signed-off-by line by the committer at the end of the commit log message. Default: truestring
) The step ID which produces the output which indicates if a patch was created. Default: “create_pr”string
) The name of the step displayed on GitHub. Default: “Create Pull Request”[github.PullRequestPatchSource](#projen-github-pullrequestpatchsource)
) Information about the patch that is used to create the pull request.string
) The name of the job displayed on GitHub. Default: “Create Pull Request”Array</code>) Github Runner selection labels. __*Default*__: ["ubuntu-latest"]
Returns:
[github.workflows.Job](#projen-github-workflows-job)
CI for GitLab.
A CI is a configurable automated process made up of one or more stages/jobs.
Submodule: gitlab
Extends: Component
new gitlab.CiConfiguration(project: Project, name: string, options?: CiConfigurationOptions)
[Project](#projen-project)
) No descriptionstring
) No description[gitlab.CiConfigurationOptions](#projen-gitlab-ciconfigurationoptions)
) No description
[gitlab.Default](#projen-gitlab-default)
) Default settings for the CI Configuration. OptionalMap<string, [gitlab.Job](#projen-gitlab-job)>
) An initial set of jobs to add to the configuration. Optional[gitlab.Job](#projen-gitlab-job)
) A special job used to upload static sites to Gitlab pages. OptionalArray</code>) Groups jobs into stages. __*Optional*__
Map<string, any>
) Global variables that are passed to jobs. Optional[gitlab.Workflow](#projen-gitlab-workflow)
) Used to control pipeline behavior. OptionalName | Type | Description |
---|---|---|
defaultAfterScript🔹 | Array |
Defines default scripts that should run after all jobs. |
defaultBeforeScript🔹 | Array |
Defines default scripts that should run before all jobs. |
defaultTags🔹 | Array |
Used to select a specific runner from the list of all runners that are available for the project. |
file🔹 | [YamlFile](#projen-yamlfile) |
The workflow YAML file. |
jobs🔹 | Map<string, [gitlab.Job](#projen-gitlab-job)> |
The jobs in the CI configuration. |
name🔹 | string |
The name of the configuration. |
path🔹 | string |
Path to CI file generated by the configuration. |
project🔹 | [Project](#projen-project) |
The project the configuration belongs to. |
stages🔹 | Array |
Groups jobs into stages. |
variables🔹 | Map<string, string | number | [gitlab.VariableConfig](#projen-gitlab-variableconfig)> |
Global variables that are passed to jobs. |
defaultArtifacts?🔹 | [gitlab.Artifacts](#projen-gitlab-artifacts) |
Default list of files and directories that should be attached to the job if it succeeds. Optional |
defaultCache?🔹 | [gitlab.Cache](#projen-gitlab-cache) |
A default list of files and directories to cache between jobs. Optional |
defaultImage?🔹 | [gitlab.Image](#projen-gitlab-image) |
Specifies the default docker image to use globally for all jobs. Optional |
defaultInterruptible?🔹 | boolean |
The default behavior for whether a job should be canceled when a newer pipeline starts before the job completes (Default: false). Optional |
defaultRetry?🔹 | [gitlab.Retry](#projen-gitlab-retry) |
How many times a job is retried if it fails. Optional |
defaultTimeout?🔹 | string |
A default timeout job written in natural language (Ex. Optional |
pages?🔹 | [gitlab.Job](#projen-gitlab-job) |
A special job used to upload static sites to Gitlab pages. Optional |
workflow?🔹 | [gitlab.Workflow](#projen-gitlab-workflow) |
Used to control pipeline behavior. Optional |
Add a globally defined variable to the CI configuration.
addGlobalVariables(variables: Map<string, any>): void
Map<string, any>
) The variables to add.Add additional yml/yaml files to the CI includes.
addIncludes(...includes: Include[]): void
[gitlab.Include](#projen-gitlab-include)
) The includes to add.
Array</code>) Files from another private project on the same GitLab instance. __*Optional*__
string
) Relative path from local repository root (/
) to the yaml
/yml
file template. Optionalstring
) Path to the project, e.g. group/project
, or group/sub-group/project
. Optionalstring
) Branch/Tag/Commit-hash for the target project. Optionalstring
) URL to a yaml
/yml
template file using HTTP/HTTPS. OptionalArray<[gitlab.IncludeRule](#projen-gitlab-includerule)>
) Rules allows for an array of individual rule objects to be evaluated in order, until one matches and dynamically provides attributes to the job. Optionalstring
) Use a .gitlab-ci.yml
template as a base, e.g. Nodejs.gitlab-ci.yml
. OptionalAdd jobs and their stages to the CI configuration.
addJobs(jobs: Map<string, Job>): void
Map<string, [gitlab.Job](#projen-gitlab-job)>
) Jobs to add.Add additional services.
addServices(...services: Service[]): void
[gitlab.Service](#projen-gitlab-service)
) The services to add.
string
) Full name of the image that should be used.string
) Additional alias that can be used to access the service from the job’s container. OptionalArray</code>) Command or script that should be used as the container's command. __*Optional*__
Array</code>) Command or script that should be executed as the container's entrypoint. __*Optional*__
Add stages to the CI configuration if not already present.
addStages(...stages: string[]): void
string
) stages to add.A GitLab CI for the main .gitlab-ci.yml
file.
Submodule: gitlab
Extends: gitlab.CiConfiguration
new gitlab.GitlabConfiguration(project: Project, options?: CiConfigurationOptions)
[Project](#projen-project)
) The project the configuration belongs to.[gitlab.CiConfigurationOptions](#projen-gitlab-ciconfigurationoptions)
) No description
[gitlab.Default](#projen-gitlab-default)
) Default settings for the CI Configuration. OptionalMap<string, [gitlab.Job](#projen-gitlab-job)>
) An initial set of jobs to add to the configuration. Optional[gitlab.Job](#projen-gitlab-job)
) A special job used to upload static sites to Gitlab pages. OptionalArray</code>) Groups jobs into stages. __*Optional*__
Map<string, any>
) Global variables that are passed to jobs. Optional[gitlab.Workflow](#projen-gitlab-workflow)
) Used to control pipeline behavior. OptionalName | Type | Description |
---|---|---|
nestedTemplates🔹 | Map<string, [gitlab.NestedConfiguration](#projen-gitlab-nestedconfiguration)> |
Creates and adds nested templates to the includes of the main CI.
Additionally adds their stages to the main CI if they are not already present.
You can futher customize nested templates through the nestedTemplates
property.
E.g. gitlabConfig.nestedTemplates[‘templateName’]?.addStages(‘stageName’)
createNestedTemplates(config: Map<string, CiConfigurationOptions>): void
Map<string, [gitlab.CiConfigurationOptions](#projen-gitlab-ciconfigurationoptions)>
) a record the names and configuraitons of the templates.A GitLab CI for templates that are created and included in the .gitlab-ci.yml
file.
Submodule: gitlab
Extends: gitlab.CiConfiguration
new gitlab.NestedConfiguration(project: Project, parent: GitlabConfiguration, name: string, options?: CiConfigurationOptions)
[Project](#projen-project)
) The project the configuration belongs to.[gitlab.GitlabConfiguration](#projen-gitlab-gitlabconfiguration)
) No descriptionstring
) The name of the configuration.[gitlab.CiConfigurationOptions](#projen-gitlab-ciconfigurationoptions)
) No description
[gitlab.Default](#projen-gitlab-default)
) Default settings for the CI Configuration. OptionalMap<string, [gitlab.Job](#projen-gitlab-job)>
) An initial set of jobs to add to the configuration. Optional[gitlab.Job](#projen-gitlab-job)
) A special job used to upload static sites to Gitlab pages. OptionalArray</code>) Groups jobs into stages. __*Optional*__
Map<string, any>
) Global variables that are passed to jobs. Optional[gitlab.Workflow](#projen-gitlab-workflow)
) Used to control pipeline behavior. OptionalName | Type | Description |
---|---|---|
parent🔹 | [gitlab.GitlabConfiguration](#projen-gitlab-gitlabconfiguration) |
Java project.
Submodule: java
Extends: github.GitHubProject
new java.JavaProject(options: JavaProjectOptions)
[java.JavaProjectOptions](#projen-java-javaprojectoptions)
) No description
string
) This is the name of your project.boolean
) Whether to commit the managed files by default. Default: true[IgnoreFileOptions](#projen-ignorefileoptions)
) Configuration options for .gitignore file. Optional[GitOptions](#projen-gitoptions)
) Configuration options for git. Optional[LoggerOptions](#projen-loggeroptions)
) Configure logging options such as verbosity. Default: {}string
) The root directory of the project. Default: “.”[Project](#projen-project)
) The parent project, if this project is part of a bigger project. Optionalstring
) The shell command to use in order to run the projen CLI. Default: “npx projen”boolean
) Generate (once) .projenrc.json (in JSON). Set to false
in order to disable .projenrc.json generation. Default: false[ProjenrcJsonOptions](#projen-projenrcjsonoptions)
) Options for .projenrc.json. Default: default optionsboolean
) Use renovatebot to handle dependency upgrades. Default: false[RenovatebotOptions](#projen-renovatebotoptions)
) Options for renovatebot. Default: default options[github.AutoApproveOptions](#projen-github-autoapproveoptions)
) Enable and configure the ‘auto approve’ workflow. Default: auto approve is disabledboolean
) Enable automatic merging on GitHub. Default: true[github.AutoMergeOptions](#projen-github-automergeoptions)
) Configure options for automatic merging on GitHub. Default: see defaults in AutoMergeOptions
boolean
) Add a clobber
task which resets the repo to origin. Default: true, but false for subprojectsboolean
) Add a VSCode development environment (used for GitHub Codespaces). Default: falseboolean
) Enable GitHub integration. Default: true[github.GitHubOptions](#projen-github-githuboptions)
) Options for GitHub integration. Default: see GitHubOptionsboolean
) Add a Gitpod development environment. Default: falseboolean
) Whether mergify should be enabled on this repository or not. Default: true[github.MergifyOptions](#projen-github-mergifyoptions)
) Options for mergify. Default: default options[ProjectType](#projen-projecttype)
) Which type of project this is (library/app). Default: ProjectType.UNKNOWN[github.GithubCredentials](#projen-github-githubcredentials)
) Choose a method of providing GitHub API access for projen workflows. Default: use a personal access token named PROJEN_GITHUB_TOKENstring
) The name of a secret which includes a GitHub Personal Access Token to be used by projen workflows. Default: “PROJEN_GITHUB_TOKEN”[SampleReadmeProps](#projen-samplereadmeprops)
) The README setup. Default: { filename: ‘README.md’, contents: ‘# replace this’ }boolean
) Auto-close of stale issues and pull request. Default: false[github.StaleOptions](#projen-github-staleoptions)
) Auto-close stale issues and pull requests. Default: see defaults in StaleOptions
boolean
) Enable VSCode integration. Default: truestring
) The artifactId is generally the name that the project is known by.string
) This is generally unique amongst an organization or a project.string
) This is the last piece of the naming puzzle.string
) Description of a project is always good. Default: undefinedstring
) Project packaging format. Default: “jar”string
) The URL, like the name, is not required. Default: undefined[java.MavenCompileOptions](#projen-java-mavencompileoptions)
) Compile options. Default: defaultsArray</code>) List of runtime dependencies for this project. __*Default*__: []
string
) Final artifact output directory. Default: “dist/java”boolean
) Include junit tests. Default: true[java.JunitOptions](#projen-java-junitoptions)
) junit options. Default: defaults[java.MavenPackagingOptions](#projen-java-mavenpackagingoptions)
) Packaging options. Default: defaultsboolean
) Use projenrc in java. Default: true[java.ProjenrcOptions](#projen-java-projenrcoptions)
) Options related to projenrc in java. Default: default optionsArray</code>) List of test dependencies for this project. __*Default*__: []
boolean
) Include sample code and test if the relevant directories don’t exist. Default: truestring
) The java package to use for the code sample. Default: “org.acme”Name | Type | Description |
---|---|---|
compile🔹 | [java.MavenCompile](#projen-java-mavencompile) |
Compile component. |
distdir🔹 | string |
Maven artifact output directory. |
packaging🔹 | [java.MavenPackaging](#projen-java-mavenpackaging) |
Packaging component. |
pom🔹 | [java.Pom](#projen-java-pom) |
API for managing pom.xml . |
junit?🔹 | [java.Junit](#projen-java-junit) |
JUnit component. Optional |
projenrc?🔹 | [java.Projenrc](#projen-java-projenrc) |
Projenrc component. Optional |
Adds a runtime dependency.
addDependency(spec: string): void
string
) Format <groupId>/<artifactId>@<semver>
.Adds a build plugin to the pom.
The plug in is also added as a BUILD dep to the project.
addPlugin(spec: string, options?: PluginOptions): Dependency
string
) dependency spec (group/artifact@version
).[java.PluginOptions](#projen-java-pluginoptions)
) plugin options.
Map<string, any>
) Plugin key/value configuration. Default: {}Array</code>) You could configure the dependencies for the plugin. __*Default*__: []
Array<[java.PluginExecution](#projen-java-pluginexecution)>
) Plugin executions. Default: []Returns:
[Dependency](#projen-dependency)
Adds a test dependency.
addTestDependency(spec: string): void
string
) Format <groupId>/<artifactId>@<semver>
.Implements JUnit-based testing.
Submodule: java
Extends: Component
new java.Junit(project: Project, options: JunitOptions)
[Project](#projen-project)
) No description[java.JunitOptions](#projen-java-junitoptions)
) No description
[java.Pom](#projen-java-pom)
) Java pom.string
) Java package for test sample. Default: “org.acme”string
) Junit version. Default: “5.7.0”Adds the maven-compiler plugin to a POM file and the compile
task.
Submodule: java
Extends: Component
new java.MavenCompile(project: Project, pom: Pom, options?: MavenCompileOptions)
[Project](#projen-project)
) No description[java.Pom](#projen-java-pom)
) No description[java.MavenCompileOptions](#projen-java-mavencompileoptions)
) No description
string
) Source language version. Default: “1.8”string
) Target JVM version. Default: “1.8”Configures a maven project to produce a .jar archive with sources and javadocs.
Submodule: java
Extends: Component
new java.MavenPackaging(project: Project, pom: Pom, options?: MavenPackagingOptions)
[Project](#projen-project)
) No description[java.Pom](#projen-java-pom)
) No description[java.MavenPackagingOptions](#projen-java-mavenpackagingoptions)
) No description
string
) Where to place the package output? Default: “dist/java”boolean
) Include javadocs jar in package. Default: trueArray</code>) Exclude source files from docs. __*Default*__: []
boolean
) Include sources jar in package. Default: trueName | Type | Description |
---|---|---|
distdir🔹 | string |
The directory containing the package output, relative to the project outdir. |
Java code sample.
Submodule: java
Extends: Component
new java.MavenSample(project: Project, options: MavenSampleOptions)
[Project](#projen-project)
) No description[java.MavenSampleOptions](#projen-java-mavensampleoptions)
) No description
string
) Project root java package.A Project Object Model or POM is the fundamental unit of work in Maven.
It is an XML file that contains information about the project and configuration details used by Maven to build the project.
Submodule: java
Extends: Component
new java.Pom(project: Project, options: PomOptions)
[Project](#projen-project)
) No description[java.PomOptions](#projen-java-pomoptions)
) No description
string
) The artifactId is generally the name that the project is known by.string
) This is generally unique amongst an organization or a project.string
) This is the last piece of the naming puzzle.string
) Description of a project is always good. Default: undefinedstring
) Project packaging format. Default: “jar”string
) The URL, like the name, is not required. Default: undefinedName | Type | Description |
---|---|---|
artifactId🔹 | string |
Maven artifact ID. |
fileName🔹 | string |
The name of the pom file. |
groupId🔹 | string |
Maven group ID. |
packaging🔹 | string |
Maven packaging format. |
version🔹 | string |
Project version. |
description?🔹 | string |
Project description. Optional |
name?🔹 | string |
Project display name. Optional |
url?🔹 | string |
Project URL. Optional |
Adds a runtime dependency.
addDependency(spec: string): void
string
) Format <groupId>/<artifactId>@<semver>
.Adds a build plugin to the pom.
The plug in is also added as a BUILD dep to the project.
addPlugin(spec: string, options?: PluginOptions): Dependency
string
) dependency spec (group/artifact@version
).[java.PluginOptions](#projen-java-pluginoptions)
) plugin options.
Map<string, any>
) Plugin key/value configuration. Default: {}Array</code>) You could configure the dependencies for the plugin. __*Default*__: []
Array<[java.PluginExecution](#projen-java-pluginexecution)>
) Plugin executions. Default: []Returns:
[Dependency](#projen-dependency)
Adds a key/value property to the pom.
addProperty(key: string, value: string): void
string
) the key.string
) the value.Adds a repository to the pom.
addRepository(repository: MavenRepository): void
[java.MavenRepository](#projen-java-mavenrepository)
) the repository to add.
string
) The identifier for the repository.string
) The url of the repository.string
) The layout of the repository. Optionalstring
) The name of the repository. OptionalAdds a test dependency.
addTestDependency(spec: string): void
string
) Format <groupId>/<artifactId>@<semver>
.Allows writing projenrc files in java.
This will install org.projen/projen
as a Maven dependency and will add a
synth
task which will compile & execute main()
from
src/main/java/projenrc.java
.
Submodule: java
Extends: ProjenrcFile
new java.Projenrc(project: Project, pom: Pom, options?: ProjenrcOptions)
[Project](#projen-project)
) No description[java.Pom](#projen-java-pom)
) No description[java.ProjenrcOptions](#projen-java-projenrcoptions)
) No description
string
) The name of the Java class which contains the main()
method for projen. Default: “projenrc”string
) The projen version to use. Default: current versionboolean
) Defines projenrc under the test scope instead of the main scope, which is reserved to the app. Default: trueName | Type | Description |
---|---|---|
className🔹 | string |
The name of the java class that includes the projen entrypoint. |
filePath🔹 | string |
The path of the projenrc file. |
Adds support for bundling JavaScript applications and dependencies into a single file.
In the future, this will also supports bundling websites.
Submodule: javascript
Extends: Component
Creates a Bundler
.
new javascript.Bundler(project: Project, options?: BundlerOptions)
[Project](#projen-project)
) No description[javascript.BundlerOptions](#projen-javascript-bundleroptions)
) No description
boolean
) Install the bundle
command as a pre-compile phase. Default: truestring
) Output directory for all bundles. Default: “assets”string
) The semantic version requirement for esbuild
. Default: no specific version (implies latest)Map<string, string>
) Map of file extensions (without dot) and loaders to use for this file type. OptionalName | Type | Description |
---|---|---|
bundleTask🔹 | [Task](#projen-task) |
Gets or creates the singleton “bundle” task of the project. |
bundledir🔹 | string |
Root bundle directory. |
esbuildVersion?🔹 | string |
The semantic version requirement for esbuild (if defined).Optional |
Adds a task to the project which bundles a specific entrypoint and all of its dependencies into a single javascript output file.
addBundle(entrypoint: string, options: AddBundleOptions): Bundle
string
) The relative path of the artifact within the project.[javascript.AddBundleOptions](#projen-javascript-addbundleoptions)
) Bundling options.
Array</code>) You can mark a file or a package as external to exclude it from your build. __*Default*__: []
boolean
) Include a source map in the bundle. Default: falseboolean
) In addition to the bundle:xyz
task, creates bundle:xyz:watch
task which will invoke the same esbuild command with the --watch
flag. Default: truestring
) esbuild platform.string
) esbuild target.boolean
) Mark the output file as executable. Default: falseMap<string, string>
) Map of file extensions (without dot) and loaders to use for this file type. Optionalstring
) Bundler output path relative to the asset’s output directory. Default: “index.js”string
) The path of the tsconfig.json file to use for bundling. Default: “tsconfig.json”Returns:
[javascript.Bundle](#projen-javascript-bundle)
Returns the Bundler
instance associated with a project or undefined
if there is no Bundler.
static of(project: Project): Bundler
[Project](#projen-project)
) The project.Returns:
[javascript.Bundler](#projen-javascript-bundler)
Represents eslint configuration.
Submodule: javascript
Extends: Component
new javascript.Eslint(project: NodeProject, options: EslintOptions)
[javascript.NodeProject](#projen-javascript-nodeproject)
) No description[javascript.EslintOptions](#projen-javascript-eslintoptions)
) No description
Array</code>) Files or glob patterns or directories with source files to lint (e.g. [ "src" ]).
Array</code>) Enable import alias for module paths. __*Default*__: undefined
Map<string, string>
) Enable import alias for module paths. Default: undefinedArray</code>) Files or glob patterns or directories with source files that include tests and build tools. __*Default*__: []
Array</code>) File types that should be linted (e.g. [ ".js", ".ts" ]). __*Default*__: [".ts"]
Array</code>) List of file patterns that should not be linted, using the same syntax as .gitignore patterns. __*Default*__: [ '*.js', '*.d.ts', 'node_modules/', '*.generated.ts', 'coverage' ]
boolean
) Should we lint .projenrc.js. Default: truestring
) Projenrc file to lint. Default: PROJEN_RCboolean
) Enable prettier for code formatting. Default: falseboolean
) Always try to resolve types under <root>@types
directory even it doesn’t contain any source code. Default: truestring
) Path to tsconfig.json
which should be used by eslint. Default: “./tsconfig.json”boolean
) Write eslint configuration as YAML instead of JSON. Default: falseName | Type | Description |
---|---|---|
config🔹 | any |
Direct access to the eslint configuration (escape hatch). |
eslintTask🔹 | [Task](#projen-task) |
eslint task. |
ignorePatterns🔹 | Array |
File patterns that should not be linted. |
overrides🔹 | Array<[javascript.EslintOverride](#projen-javascript-eslintoverride)> |
eslint overrides. |
rules🔹 | Map<string, Array |
eslint rules. |
Adds an extends
item to the eslint configuration.
addExtends(...extendList: string[]): void
string
) The list of “extends” to add.Do not lint these files.
addIgnorePattern(pattern: string): void
string
) No descriptionAdd a file, glob pattern or directory with source files to lint (e.g. [ “src” ]).
addLintPattern(pattern: string): void
string
) No descriptionAdd an eslint override.
addOverride(override: EslintOverride): void
[javascript.EslintOverride](#projen-javascript-eslintoverride)
) No description
Array</code>) Files or file patterns on which to apply the override.
string
) The overridden parser. OptionalMap<string, any>
) The overriden rules. OptionalAdds an eslint plugin.
addPlugins(...plugins: string[]): void
string
) The names of plugins to add.Add an eslint rule.
addRules(rules: Map<string, any>): void
Map<string, any>
) No descriptionAdd a glob file pattern which allows importing dev dependencies.
allowDevDeps(pattern: string): void
string
) glob pattern.Returns the singletone Eslint component of a project or undefined if there is none.
static of(project: Project): Eslint
[Project](#projen-project)
) No descriptionReturns:
[javascript.Eslint](#projen-javascript-eslint)
Installs the following npm scripts:.
test
, intended for testing locally and in CI. Will update snapshots unless updateSnapshot: UpdateSnapshot: NEVER
is set.test:watch
, intended for automatically rerunning tests when files change.test:update
, intended for testing locally and updating snapshots to match the latest unit under test. Only available when updateSnapshot: UpdateSnapshot: NEVER
.Submodule: javascript
Extends: Component
new javascript.Jest(project: NodeProject, options?: JestOptions)
[javascript.NodeProject](#projen-javascript-nodeproject)
) No description[javascript.JestOptions](#projen-javascript-jestoptions)
) No description
string
) Path to JSON config file for Jest. Default: No separate config file, jest settings are stored in package.jsonboolean
) Collect coverage. Default: trueboolean
) Include the text
coverage reporter, which means that coverage summary is printed at the end of the jest execution. Default: trueArray</code>) Additional options to pass to the Jest CLI invocation. __*Default*__: no extra options
Array</code>) Defines `testPathIgnorePatterns` and `coveragePathIgnorePatterns`. __*Default*__: ["/node_modules/"]
[javascript.JestConfigOptions](#projen-javascript-jestconfigoptions)
) Jest configuration. Default: default jest configurationstring
) The version of jest to use. Default: installs the latest jest versionboolean
) Result processing with jest-junit. Default: trueboolean
) Preserve the default Jest reporter when additional reporters are added. Default: true[javascript.UpdateSnapshot](#projen-javascript-updatesnapshot)
) Whether to update snapshots in task “test” (which is executed in task “build” and build workflows), or create a separate task “test:update” for updating snapshots. Default: ALWAYSName | Type | Description |
---|---|---|
config🔹 | any |
Escape hatch. |
jestVersion🔹 | string |
Jest version, including @ symbol, like @^29 . |
file?🔹 | [JsonFile](#projen-jsonfile) |
Jest config file. Optional |
addIgnorePattern(pattern: string): void
string
) No descriptionaddReporter(reporter: JestReporter): void
[javascript.JestReporter](#projen-javascript-jestreporter)
) No descriptionAdds a a setup file to Jest’s setupFiles configuration.
addSetupFile(file: string): void
string
) File path to setup file.Adds a a setup file to Jest’s setupFilesAfterEnv configuration.
addSetupFileAfterEnv(file: string): void
string
) File path to setup file.addSnapshotResolver(file: string): void
string
) No descriptionAdds a test match pattern.
addTestMatch(pattern: string): void
string
) glob pattern to match for tests.Adds a watch ignore pattern.
addWatchIgnorePattern(pattern: string): void
string
) The pattern (regular expression).Returns the singletone Jest component of a project or undefined if there is none.
static of(project: Project): Jest
[Project](#projen-project)
) No descriptionReturns:
[javascript.Jest](#projen-javascript-jest)
Submodule: javascript
new javascript.JestReporter(name: string, options?: Map<string, any>)
string
) No descriptionMap<string, any>
) No descriptionRepresents the npm package.json
file.
Submodule: javascript
Extends: Component
new javascript.NodePackage(project: Project, options?: NodePackageOptions)
[Project](#projen-project)
) No description[javascript.NodePackageOptions](#projen-javascript-nodepackageoptions)
) No description
boolean
) Allow the project to include peerDependencies
and bundledDependencies
. Default: truestring
) Author’s e-mail. Optionalstring
) Author’s name. Optionalboolean
) Is the author an organization. Optionalstring
) Author’s URL / Website. Optionalboolean
) Automatically add all executables under the bin
directory to your package.json
file under the bin
section. Default: trueMap<string, string>
) Binary programs vended with your module. Optionalstring
) The email address to which issues should be reported. Optionalstring
) The url to your project’s issue tracker. OptionalArray</code>) List of dependencies to bundle into this module. __*Optional*__
[javascript.CodeArtifactOptions](#projen-javascript-codeartifactoptions)
) Options for npm packages using AWS CodeArtifact. Default: undefinedArray</code>) Runtime dependencies of this module. __*Default*__: []
string
) The description is just a string that helps people understand the purpose of the package. OptionalArray</code>) Build dependencies for this module. __*Default*__: []
string
) Module entrypoint (main
in package.json
). Default: “lib/index.js”string
) Package’s Homepage / Website. OptionalArray</code>) Keywords to include in `package.json`. __*Optional*__
string
) License’s SPDX identifier. Default: “Apache-2.0”boolean
) Indicates if a license should be added. Default: truestring
) Minimum node.js version to require via engines
(inclusive). Default: no maxstring
) Minimum Node.js version to require via package.json engines
(inclusive). Default: no “engines” specified[javascript.NpmAccess](#projen-javascript-npmaccess)
) Access level of the npm package. Default: for scoped packages (e.g. foo@bar
), the default is NpmAccess.RESTRICTED
, for non-scoped packages, the default is NpmAccess.PUBLIC
.string
) The host name of the npm registry to publish to. Optionalstring
) The base URL of the npm package registry. Default: “https://registry.npmjs.org”string
) GitHub secret which contains the NPM token to use when publishing packages. Default: “NPM_TOKEN”[javascript.NodePackageManager](#projen-javascript-nodepackagemanager)
) The Node Package Manager used to execute scripts. Default: NodePackageManager.YARNstring
) The “name” in package.json. Default: defaults to project name[javascript.PeerDependencyOptions](#projen-javascript-peerdependencyoptions)
) Options for peerDeps
. OptionalArray</code>) Peer dependencies for this module. __*Default*__: []
string
) The version of PNPM to use if using PNPM as a package manager. Default: “7”string
) The repository is the location where the actual code for your package lives. Optionalstring
) If the package.json for your package is not in the root directory (for example if it is part of a monorepo), you can specify the directory in which it lives. OptionalArray<[javascript.ScopedPackagesOptions](#projen-javascript-scopedpackagesoptions)>
) Options for privately hosted scoped packages. Default: fetch all scoped packages from the public npm registryMap<string, string>
) npm scripts to include. Default: {}string
) Package’s Stability. OptionalName | Type | Description |
---|---|---|
allowLibraryDependencies🔹 | boolean |
Allow project to take library dependencies. |
entrypoint🔹 | string |
The module’s entrypoint (e.g. lib/index.js ). |
file🔹 | [JsonFile](#projen-jsonfile) |
The package.json file. |
installAndUpdateLockfileCommand🔹 | string |
Renders yarn install or npm install with lockfile update (not frozen). |
installCiTask🔹 | [Task](#projen-task) |
The task for installing project dependencies (frozen). |
installCommand🔹 | string |
Returns the command to execute in order to install all dependencies (always frozen). |
installTask🔹 | [Task](#projen-task) |
The task for installing project dependencies (non-frozen). |
lockFile🔹 | string |
The name of the lock file. |
manifest⚠️ | any |
|
npmAccess🔹 | [javascript.NpmAccess](#projen-javascript-npmaccess) |
npm package access level. |
npmRegistry🔹 | string |
The npm registry host (e.g. registry.npmjs.org ). |
npmRegistryUrl🔹 | string |
npm registry (e.g. https://registry.npmjs.org ). Use npmRegistryHost to get just the host name. |
packageManager🔹 | [javascript.NodePackageManager](#projen-javascript-nodepackagemanager) |
The package manager to use. |
packageName🔹 | string |
The name of the npm package. |
projenCommand🔹 | string |
The command which executes “projen”. |
codeArtifactOptions?🔹 | [javascript.CodeArtifactOptions](#projen-javascript-codeartifactoptions) |
Options for npm packages using AWS CodeArtifact. Default: undefined |
license?🔹 | string |
The SPDX license of this module. Optional |
maxNodeVersion?🔹 | string |
Maximum node version required by this package. Default: no maximum. |
minNodeVersion?🔹 | string |
Minimum node.js version required by this package. Default: no minimum |
npmTokenSecret?🔹 | string |
GitHub secret which contains the NPM token to use when publishing packages. Optional |
pnpmVersion?🔹 | string |
The version of PNPM to use if using PNPM as a package manager. Default: “7” |
scopedPackagesOptions?🔹 | Array<[javascript.ScopedPackagesOptions](#projen-javascript-scopedpackagesoptions)> |
Options for privately hosted scoped packages. Default: undefined |
addBin(bins: Map<string, string>): void
Map<string, string>
) No descriptionDefines bundled dependencies.
Bundled dependencies will be added as normal dependencies as well as to the
bundledDependencies
section of your package.json
.
addBundledDeps(...deps: string[]): void
string
) Names modules to install.Defines normal dependencies.
addDeps(...deps: string[]): void
string
) Names modules to install.Defines development/test dependencies.
addDevDeps(...deps: string[]): void
string
) Names modules to install.Adds an engines
requirement to your package.
addEngine(engine: string, version: string): void
string
) The engine (e.g. node
).string
) The semantic version requirement (e.g. ^10
).Directly set fields in package.json
.
addField(name: string, value: any): void
string
) field name.any
) field value.Adds keywords to package.json (deduplicated).
addKeywords(...keywords: string[]): void
string
) The keywords to add.Defines resolutions for dependencies to change the normally resolved version of a dependency to something else.
addPackageResolutions(...resolutions: string[]): void
string
) Names resolutions to be added.Defines peer dependencies.
When adding peer dependencies, a devDependency will also be added on the pinned version of the declared peer. This will ensure that you are testing your code against the minimum version required from your consumers.
addPeerDeps(...deps: string[]): void
string
) Names modules to install.Sets the package version.
addVersion(version: string): void
string
) Package version.Indicates if a script by the given name is defined.
hasScript(name: string): boolean
string
) The name of the script.Returns:
boolean
Called after synthesis.
Order is not guaranteed.
postSynthesize(): void
Called before synthesis.
preSynthesize(): void
Removes an npm script (always successful).
removeScript(name: string): void
string
) The name of the script.Render a package manager specific command to upgrade all requested dependencies.
renderUpgradePackagesCommand(exclude: Array<string>, include?: Array<string>): string
Array</code>) *No description*
Array</code>) *No description*
Returns:
string
Add a npm package.json script.
setScript(name: string, command: string): void
string
) The script name.string
) The command to execute.Attempt to resolve the currently installed version for a given dependency.
tryResolveDependencyVersion(dependencyName: string): string
string
) Dependency to resolve for.Returns:
string
Node.js project.
Submodule: javascript
Extends: github.GitHubProject
new javascript.NodeProject(options: NodeProjectOptions)
[javascript.NodeProjectOptions](#projen-javascript-nodeprojectoptions)
) No description
string
) This is the name of your project.boolean
) Whether to commit the managed files by default. Default: true[IgnoreFileOptions](#projen-ignorefileoptions)
) Configuration options for .gitignore file. Optional[GitOptions](#projen-gitoptions)
) Configuration options for git. Optional[LoggerOptions](#projen-loggeroptions)
) Configure logging options such as verbosity. Default: {}string
) The root directory of the project. Default: “.”[Project](#projen-project)
) The parent project, if this project is part of a bigger project. Optionalstring
) The shell command to use in order to run the projen CLI. Default: “npx projen”boolean
) Generate (once) .projenrc.json (in JSON). Set to false
in order to disable .projenrc.json generation. Default: false[ProjenrcJsonOptions](#projen-projenrcjsonoptions)
) Options for .projenrc.json. Default: default optionsboolean
) Use renovatebot to handle dependency upgrades. Default: false[RenovatebotOptions](#projen-renovatebotoptions)
) Options for renovatebot. Default: default options[github.AutoApproveOptions](#projen-github-autoapproveoptions)
) Enable and configure the ‘auto approve’ workflow. Default: auto approve is disabledboolean
) Enable automatic merging on GitHub. Default: true[github.AutoMergeOptions](#projen-github-automergeoptions)
) Configure options for automatic merging on GitHub. Default: see defaults in AutoMergeOptions
boolean
) Add a clobber
task which resets the repo to origin. Default: true, but false for subprojectsboolean
) Add a VSCode development environment (used for GitHub Codespaces). Default: falseboolean
) Enable GitHub integration. Default: true[github.GitHubOptions](#projen-github-githuboptions)
) Options for GitHub integration. Default: see GitHubOptionsboolean
) Add a Gitpod development environment. Default: falseboolean
) Whether mergify should be enabled on this repository or not. Default: true[github.MergifyOptions](#projen-github-mergifyoptions)
) Options for mergify. Default: default options[ProjectType](#projen-projecttype)
) Which type of project this is (library/app). Default: ProjectType.UNKNOWN[github.GithubCredentials](#projen-github-githubcredentials)
) Choose a method of providing GitHub API access for projen workflows. Default: use a personal access token named PROJEN_GITHUB_TOKENstring
) The name of a secret which includes a GitHub Personal Access Token to be used by projen workflows. Default: “PROJEN_GITHUB_TOKEN”[SampleReadmeProps](#projen-samplereadmeprops)
) The README setup. Default: { filename: ‘README.md’, contents: ‘# replace this’ }boolean
) Auto-close of stale issues and pull request. Default: false[github.StaleOptions](#projen-github-staleoptions)
) Auto-close stale issues and pull requests. Default: see defaults in StaleOptions
boolean
) Enable VSCode integration. Default: trueboolean
) Allow the project to include peerDependencies
and bundledDependencies
. Default: truestring
) Author’s e-mail. Optionalstring
) Author’s name. Optionalboolean
) Is the author an organization. Optionalstring
) Author’s URL / Website. Optionalboolean
) Automatically add all executables under the bin
directory to your package.json
file under the bin
section. Default: trueMap<string, string>
) Binary programs vended with your module. Optionalstring
) The email address to which issues should be reported. Optionalstring
) The url to your project’s issue tracker. OptionalArray</code>) List of dependencies to bundle into this module. __*Optional*__
[javascript.CodeArtifactOptions](#projen-javascript-codeartifactoptions)
) Options for npm packages using AWS CodeArtifact. Default: undefinedArray</code>) Runtime dependencies of this module. __*Default*__: []
string
) The description is just a string that helps people understand the purpose of the package. OptionalArray</code>) Build dependencies for this module. __*Default*__: []
string
) Module entrypoint (main
in package.json
). Default: “lib/index.js”string
) Package’s Homepage / Website. OptionalArray</code>) Keywords to include in `package.json`. __*Optional*__
string
) License’s SPDX identifier. Default: “Apache-2.0”boolean
) Indicates if a license should be added. Default: truestring
) Minimum node.js version to require via engines
(inclusive). Default: no maxstring
) Minimum Node.js version to require via package.json engines
(inclusive). Default: no “engines” specified[javascript.NpmAccess](#projen-javascript-npmaccess)
) Access level of the npm package. Default: for scoped packages (e.g. foo@bar
), the default is NpmAccess.RESTRICTED
, for non-scoped packages, the default is NpmAccess.PUBLIC
.string
) The host name of the npm registry to publish to. Optionalstring
) The base URL of the npm package registry. Default: “https://registry.npmjs.org”string
) GitHub secret which contains the NPM token to use when publishing packages. Default: “NPM_TOKEN”[javascript.NodePackageManager](#projen-javascript-nodepackagemanager)
) The Node Package Manager used to execute scripts. Default: NodePackageManager.YARNstring
) The “name” in package.json. Default: defaults to project name[javascript.PeerDependencyOptions](#projen-javascript-peerdependencyoptions)
) Options for peerDeps
. OptionalArray</code>) Peer dependencies for this module. __*Default*__: []
string
) The version of PNPM to use if using PNPM as a package manager. Default: “7”string
) The repository is the location where the actual code for your package lives. Optionalstring
) If the package.json for your package is not in the root directory (for example if it is part of a monorepo), you can specify the directory in which it lives. OptionalArray<[javascript.ScopedPackagesOptions](#projen-javascript-scopedpackagesoptions)>
) Options for privately hosted scoped packages. Default: fetch all scoped packages from the public npm registryMap<string, string>
) npm scripts to include. Default: {}string
) Package’s Stability. Optionalstring
) Version requirement of publib
which is used to publish modules to npm. Default: “latest”number
) Major version to release from the default branch. Default: Major version is not enforced.number
) Minimal Major version to release. Default: No minimum version is being enforcedstring
) The npmDistTag to use when publishing from the default branch. Default: “latest”Array<[github.workflows.JobStep](#projen-github-workflows-jobstep)>
) Steps to execute after build as part of the release workflow. Default: []string
) Bump versions from the default branch as pre-releases (e.g. “beta”, “alpha”, “pre”). Default: normal semantic versionsboolean
) Instead of actually publishing to package managers, just print the publishing command. Default: falseboolean
) Define publishing tasks that can be executed manually as well as workflows. Default: falseMap<string, [release.BranchOptions](#projen-release-branchoptions)>
) Defines additional release branches. Default: no additional branches are used for release. you can use addBranch()
to add additional branches.boolean
) Automatically release new versions every commit to one of branches in releaseBranches
. Default: trueboolean
) Create a github issue on every failed publishing task. Default: falsestring
) The label to apply to issues indicating publish failures. Default: “failed-release”string
) CRON schedule to trigger new releases. Default: no scheduled releasesstring
) Automatically add the given prefix to release tags. Useful if you are releasing on multiple branches with overlapping version numbers. Default: “v”[release.ReleaseTrigger](#projen-release-releasetrigger)
) The release trigger to use. Default: Continuous releases (ReleaseTrigger.continuous()
)string
) The name of the default release workflow. Default: “Release”Array<[github.workflows.JobStep](#projen-github-workflows-jobstep)>
) A set of workflow steps to execute in order to setup the workflow container. OptionalMap<string, any>
) Custom configuration used when creating changelog with standard-version package. Default: standard configuration applicable for GitHub repositoriesstring
) Container image to use for GitHub workflows. Default: default imageArray</code>) Github Runner selection labels. __*Default*__: ["ubuntu-latest"]
string
) The name of the main release branch.string
) A directory which will contain build artifacts. Default: “dist”boolean
) Automatically approve deps upgrade PRs, allowing them to be merged by mergify (if configued). Default: trueboolean
) Define a GitHub workflow for building PRs. Default: true if not a subproject[github.workflows.Triggers](#projen-github-workflows-triggers)
) Build workflow triggers. Default: “{ pullRequest: {}, workflowDispatch: {} }”[javascript.BundlerOptions](#projen-javascript-bundleroptions)
) Options for Bundler
. Optionalboolean
) Define a GitHub workflow step for sending code coverage metrics to https://codecov.io/ Uses codecov/codecov-action@v3 A secret is required for private repos. Configured with @codeCovTokenSecret. Default: falsestring
) Define the secret name for a specified https://codecov.io/ token A secret is required to send coverage for private repositories. Default: if this option is not specified, only public repositories are supportedstring
) License copyright owner. Default: defaults to the value of authorName or “” if authorName
is undefined.string
) The copyright years to put in the LICENSE file. Default: current yearboolean
) Use dependabot to handle dependency upgrades. Default: false[github.DependabotOptions](#projen-github-dependabotoptions)
) Options for dependabot. Default: default optionsboolean
) Use github workflows to handle dependency upgrades. Default: true[javascript.UpgradeDependenciesOptions](#projen-javascript-upgradedependenciesoptions)
) Options for UpgradeDependencies
. Default: default optionsArray</code>) Additional entries to .gitignore. __*Optional*__
boolean
) Setup jest unit tests. Default: true[javascript.JestOptions](#projen-javascript-jestoptions)
) Jest options. Default: default optionsboolean
) Automatically update files modified during builds to pull-request branches. Default: trueArray</code>) Additional entries to .npmignore. __*Optional*__
boolean
) Defines an .npmignore file. Normally this is only needed for libraries that are packaged as tarballs. Default: true[IgnoreFileOptions](#projen-ignorefileoptions)
) Configuration options for .npmignore file. Optionalboolean
) Defines a package
task that will produce an npm tarball under the artifacts directory (e.g. dist
). Default: trueboolean
) Setup prettier. Default: false[javascript.PrettierOptions](#projen-javascript-prettieroptions)
) Prettier options. Default: default optionsboolean
) Indicates of “projen” should be installed as a devDependency. Default: trueboolean
) Generate (once) .projenrc.js (in JavaScript). Set to false
in order to disable .projenrc.js generation. Default: true if projenrcJson is false[javascript.ProjenrcOptions](#projen-javascript-projenrcoptions)
) Options for .projenrc.js. Default: default optionsstring
) Version of projen to install. Default: Defaults to the latest version.boolean
) Include a GitHub pull request template. Default: trueArray</code>) The contents of the pull request template. __*Default*__: default content
boolean
) Add release management to this project. Default: true (false for subprojects)boolean
) Automatically release to npm when new versions are introduced. Default: falseboolean
) DEPRECATED: renamed to release
. Default: true if not a subprojectArray<[github.workflows.JobStep](#projen-github-workflows-jobstep)>
) Workflow steps to use in order to bootstrap this repo. Default: “yarn install –frozen-lockfile && yarn projen”[github.GitIdentity](#projen-github-gitidentity)
) The git identity to use in workflows. Default: GitHub Actionsstring
) The node version to use in GitHub workflows. Default: same as minNodeVersion
boolean
) Enable Node.js package cache in GitHub workflows. Default: falseName | Type | Description |
---|---|---|
allowLibraryDependencies⚠️ | boolean |
|
artifactsDirectory🔹 | string |
The build output directory. |
artifactsJavascriptDirectory🔹 | string |
The location of the npm tarball after build (${artifactsDirectory}/js ). |
bundler🔹 | [javascript.Bundler](#projen-javascript-bundler) |
|
entrypoint⚠️ | string |
|
manifest⚠️ | any |
|
npmrc🔹 | [javascript.NpmConfig](#projen-javascript-npmconfig) |
The .npmrc file. |
package🔹 | [javascript.NodePackage](#projen-javascript-nodepackage) |
API for managing the node package. |
packageManager⚠️ | [javascript.NodePackageManager](#projen-javascript-nodepackagemanager) |
The package manager to use. |
runScriptCommand🔹 | string |
The command to use to run scripts (e.g. yarn run or npm run depends on the package manager). |
workflowBootstrapSteps🔹 | Array<[github.workflows.JobStep](#projen-github-workflows-jobstep)> |
|
workflowPackageCache🔹 | boolean |
|
autoMerge?🔹 | [github.AutoMerge](#projen-github-automerge) |
Component that sets up mergify for merging approved pull requests. Optional |
buildWorkflow?🔹 | [build.BuildWorkflow](#projen-build-buildworkflow) |
The PR build GitHub workflow. Optional |
buildWorkflowJobId?🔹 | string |
The job ID of the build workflow. Optional |
jest?🔹 | [javascript.Jest](#projen-javascript-jest) |
The Jest configuration (if enabled). Optional |
maxNodeVersion?🔹 | string |
Maximum node version required by this package. Optional |
minNodeVersion?🔹 | string |
Minimum node.js version required by this package. Optional |
nodeVersion?🔹 | string |
Optional |
npmignore?🔹 | [IgnoreFile](#projen-ignorefile) |
The .npmignore file. Optional |
prettier?🔹 | [javascript.Prettier](#projen-javascript-prettier) |
Optional |
publisher?⚠️ | [release.Publisher](#projen-release-publisher) |
Package publisher. Optional |
release?🔹 | [release.Release](#projen-release-release) |
Release management. Optional |
upgradeWorkflow?🔹 | [javascript.UpgradeDependencies](#projen-javascript-upgradedependencies) |
The upgrade workflow. Optional |
addBins(bins: Map<string, string>): void
Map<string, string>
) No descriptionDefines bundled dependencies.
Bundled dependencies will be added as normal dependencies as well as to the
bundledDependencies
section of your package.json
.
addBundledDeps(...deps: string[]): void
string
) Names modules to install.DEPRECATED.
addCompileCommand(...commands: string[]): void
string
) No descriptionDefines normal dependencies.
addDeps(...deps: string[]): void
string
) Names modules to install.Defines development/test dependencies.
addDevDeps(...deps: string[]): void
string
) Names modules to install.Directly set fields in package.json
.
addFields(fields: Map<string, any>): void
Map<string, any>
) The fields to set.Adds keywords to package.json (deduplicated).
addKeywords(...keywords: string[]): void
string
) The keywords to add.Exclude these files from the bundled package.
Implemented by project types based on the
packaging mechanism. For example, NodeProject
delegates this to .npmignore
.
addPackageIgnore(pattern: string): void
string
) No descriptionDefines peer dependencies.
When adding peer dependencies, a devDependency will also be added on the pinned version of the declared peer. This will ensure that you are testing your code against the minimum version required from your consumers.
addPeerDeps(...deps: string[]): void
string
) Names modules to install.Replaces the contents of multiple npm package.json scripts.
addScripts(scripts: Map<string, string>): void
Map<string, string>
) The scripts to set.DEPRECATED.
addTestCommand(...commands: string[]): void
string
) No descriptionIndicates if a script by the name name is defined.
hasScript(name: string): boolean
string
) The name of the script.Returns:
boolean
Removes the npm script (always successful).
removeScript(name: string): void
string
) The name of the script.Returns the set of workflow steps which should be executed to bootstrap a workflow.
renderWorkflowSetup(options?: RenderWorkflowSetupOptions): Array<JobStep>
[javascript.RenderWorkflowSetupOptions](#projen-javascript-renderworkflowsetupoptions)
) Options.
boolean
) Should the pacakge lockfile be updated? Default: falseReturns:
Array<[github.workflows.JobStep](#projen-github-workflows-jobstep)>
Returns the shell command to execute in order to run a task.
This will
typically be npx projen TASK
.
runTaskCommand(task: Task): string
[Task](#projen-task)
) The task for which the command is required.Returns:
string
Replaces the contents of an npm package.json script.
setScript(name: string, command: string): void
string
) The script name.string
) The command to execute.File representing the local NPM config in .npmrc.
Submodule: javascript
Extends: Component
new javascript.NpmConfig(project: NodeProject, options?: NpmConfigOptions)
[javascript.NodeProject](#projen-javascript-nodeproject)
) No description[javascript.NpmConfigOptions](#projen-javascript-npmconfigoptions)
) No description
boolean
) Omits empty objects and arrays. Default: falsestring
) URL of the registry mirror to use. Default: use npmjs default registryconfigure a generic property.
addConfig(name: string, value: string): void
string
) the name of the property.string
) the value of the property.configure a scoped registry.
addRegistry(url: string, scope?: string): void
string
) the URL of the registry to use.string
) the scope the registry is used for;Represents prettier configuration.
Submodule: javascript
Extends: Component
new javascript.Prettier(project: NodeProject, options: PrettierOptions)
[javascript.NodeProject](#projen-javascript-nodeproject)
) No description[javascript.PrettierOptions](#projen-javascript-prettieroptions)
) No description
boolean
) Defines an .prettierIgnore file. Default: true[IgnoreFileOptions](#projen-ignorefileoptions)
) Configuration options for .prettierignore file. OptionalArray<[javascript.PrettierOverride](#projen-javascript-prettieroverride)>
) Provide a list of patterns to override prettier configuration. Default: [][javascript.PrettierSettings](#projen-javascript-prettiersettings)
) Prettier settings. Default: default settingsboolean
) Write prettier configuration as YAML instead of JSON. Default: falseName | Type | Description |
---|---|---|
overrides🔹 | Array<[javascript.PrettierOverride](#projen-javascript-prettieroverride)> |
Returns all Prettier overrides. |
settings🔹 | [javascript.PrettierSettings](#projen-javascript-prettiersettings) |
Direct access to the prettier settings. |
ignoreFile?🔹 | [IgnoreFile](#projen-ignorefile) |
The .prettierIgnore file. Optional |
Defines Prettier ignore Patterns these patterns will be added to the file .prettierignore.
addIgnorePattern(pattern: string): void
string
) filepatterns so exclude from prettier formatting.Add a prettier override.
addOverride(override: PrettierOverride): void
[javascript.PrettierOverride](#projen-javascript-prettieroverride)
) No description
string | Array</code>) Include these files in this override.
[javascript.PrettierSettings](#projen-javascript-prettiersettings)
) The options to apply for this override.string | Array</code>) Exclude these files from this override. __*Optional*__
Called before synthesis.
preSynthesize(): void
static of(project: Project): Prettier
[Project](#projen-project)
) No descriptionReturns:
[javascript.Prettier](#projen-javascript-prettier)
Sets up a javascript project to use TypeScript for projenrc.
Submodule: javascript
Extends: ProjenrcFile
new javascript.Projenrc(project: Project, options?: ProjenrcOptions)
[Project](#projen-project)
) No description[javascript.ProjenrcOptions](#projen-javascript-projenrcoptions)
) No description
string
) The name of the projenrc file. Default: “.projenrc.js”Name | Type | Description |
---|---|---|
filePath🔹 | string |
The path of the projenrc file. |
Called before synthesis.
preSynthesize(): void
Submodule: javascript
new javascript.Transform(name: string, options?: any)
string
) No descriptionany
) No descriptionSubmodule: javascript
Extends: Component
new javascript.TypescriptConfig(project: Project, options: TypescriptConfigOptions)
[Project](#projen-project)
) No description[javascript.TypescriptConfigOptions](#projen-javascript-typescriptconfigoptions)
) No description
[javascript.TypeScriptCompilerOptions](#projen-javascript-typescriptcompileroptions)
) Compiler options to use.Array</code>) Filters results from the "include" option. __*Default*__: node_modules is excluded by default
[javascript.TypescriptConfigExtends](#projen-javascript-typescriptconfigextends)
) Base tsconfig.json
configuration(s) to inherit from. Optionalstring
) No description Default: “tsconfig.json”Array</code>) Specifies a list of glob patterns that match TypeScript files to be included in compilation. __*Default*__: all .ts files recursively
Name | Type | Description |
---|---|---|
compilerOptions🔹 | [javascript.TypeScriptCompilerOptions](#projen-javascript-typescriptcompileroptions) |
|
exclude🔹 | Array |
|
extends🔹 | Array |
Array of base tsconfig.json paths. Any absolute paths are resolved relative to this instance, while any relative paths are used as is. |
file🔹 | [JsonFile](#projen-jsonfile) |
|
fileName🔹 | string |
|
include🔹 | Array |
addExclude(pattern: string): void
string
) No descriptionExtend from base TypescriptConfig
instance.
addExtends(value: TypescriptConfig): void
[javascript.TypescriptConfig](#projen-javascript-typescriptconfig)
) Base TypescriptConfig
instance.addInclude(pattern: string): void
string
) No descriptionCalled before synthesis.
preSynthesize(): void
Resolve valid TypeScript extends paths relative to this config.
resolveExtendsPath(configPath: string): string
string
) Path to resolve against.Returns:
string
Container for TypescriptConfig
tsconfig.json
base configuration(s). Extending from more than one base config file requires TypeScript 5.0+.
Submodule: javascript
toJSON(): Array<string>
Returns:
Array</code>
Factory for creation from array of file paths.
static fromPaths(paths: Array<string>): TypescriptConfigExtends
Array</code>) Absolute or relative paths to base `tsconfig.json` files.
Returns:
[javascript.TypescriptConfigExtends](#projen-javascript-typescriptconfigextends)
Factory for creation from array of other TypescriptConfig
instances.
static fromTypescriptConfigs(configs: Array<TypescriptConfig>): TypescriptConfigExtends
Array<[javascript.TypescriptConfig](#projen-javascript-typescriptconfig)>
) Base TypescriptConfig
instances.Returns:
[javascript.TypescriptConfigExtends](#projen-javascript-typescriptconfigextends)
Upgrade node project dependencies.
Submodule: javascript
Extends: Component
new javascript.UpgradeDependencies(project: NodeProject, options?: UpgradeDependenciesOptions)
[javascript.NodeProject](#projen-javascript-nodeproject)
) No description[javascript.UpgradeDependenciesOptions](#projen-javascript-upgradedependenciesoptions)
) No description
Array</code>) List of package names to exclude during the upgrade. __*Default*__: Nothing is excluded.
Array</code>) List of package names to include during the upgrade. __*Default*__: Everything is included.
string
) Title of the pull request to use (should be all lower-case). Default: “upgrade dependencies”boolean
) Add Signed-off-by line by the committer at the end of the commit log message. Default: truestring
) The name of the task that will be created. Default: “upgrade”.boolean
) Include a github workflow for creating PR’s that upgrades the required dependencies, either by manual dispatch, or by a schedule. Default: true for root projects, false for sub-projects.[javascript.UpgradeDependenciesWorkflowOptions](#projen-javascript-upgradedependenciesworkflowoptions)
) Options for the github workflow. Default: default options.Name | Type | Description |
---|---|---|
postUpgradeTask🔹 | [Task](#projen-task) |
A task run after the upgrade task. |
upgradeTask🔹 | [Task](#projen-task) |
The upgrade task. |
workflows🔹 | Array<[github.GithubWorkflow](#projen-github-githubworkflow)> |
The workflows that execute the upgrades. |
containerOptions?🔹 | [github.workflows.ContainerOptions](#projen-github-workflows-containeroptions) |
Container definitions for the upgrade workflow. Optional |
Add steps to execute a successful build.
addPostBuildSteps(...steps: JobStep[]): void
[github.workflows.JobStep](#projen-github-workflows-jobstep)
) workflow steps.
Map<string, string>
) Sets environment variables for steps to use in the runner environment. Optionalstring
) A unique identifier for the step. Optionalstring
) You can use the if conditional to prevent a job from running unless a condition is met. Optionalstring
) A name for your step to display on GitHub. Optionalstring
) Runs command-line programs using the operating system’s shell. Optionalstring
) Selects an action to run as part of a step in your job. OptionalMap<string, any>
) A map of the input parameters defined by the action. Optionalstring
) Specifies a working directory for a step. Optionalboolean
) Prevents a job from failing when a step fails. Optionalnumber
) The maximum number of minutes to run the step before killing the process. OptionalHow often to check for new versions and raise pull requests for version upgrades.
Submodule: javascript
Name | Type | Description |
---|---|---|
cron🔹 | Array |
|
static DAILY🔹 | [javascript.UpgradeDependenciesSchedule](#projen-javascript-upgradedependenciesschedule) |
At 00:00. |
static MONTHLY🔹 | [javascript.UpgradeDependenciesSchedule](#projen-javascript-upgradedependenciesschedule) |
At 00:00 on day-of-month 1. |
static NEVER🔹 | [javascript.UpgradeDependenciesSchedule](#projen-javascript-upgradedependenciesschedule) |
Disables automatic upgrades. |
static WEEKDAY🔹 | [javascript.UpgradeDependenciesSchedule](#projen-javascript-upgradedependenciesschedule) |
At 00:00 on every day-of-week from Monday through Friday. |
static WEEKLY🔹 | [javascript.UpgradeDependenciesSchedule](#projen-javascript-upgradedependenciesschedule) |
At 00:00 on Monday. |
Create a schedule from a raw cron expression.
static expressions(cron: Array<string>): UpgradeDependenciesSchedule
Array</code>) *No description*
Returns:
[javascript.UpgradeDependenciesSchedule](#projen-javascript-upgradedependenciesschedule)
Submodule: javascript
new javascript.WatchPlugin(name: string, options?: any)
string
) No descriptionany
) No descriptionManages dependencies using a requirements.txt file and the pip CLI tool.
Implements: python.IPythonDeps Submodule: python
Extends: Component
new python.Pip(project: Project, _options?: PipOptions)
[Project](#projen-project)
) No description[python.PipOptions](#projen-python-pipoptions)
) No descriptionName | Type | Description |
---|---|---|
installTask🔹 | [Task](#projen-task) |
A task that installs and updates dependencies. |
Adds a runtime dependency.
addDependency(spec: string): void
string
) Format <module>@<semver>
.Adds a dev dependency.
addDevDependency(spec: string): void
string
) Format <module>@<semver>
.Installs dependencies (called during post-synthesis).
installDependencies(): void
Manage project dependencies, virtual environments, and packaging through the poetry CLI tool.
Implements: python.IPythonDeps, python.IPythonEnv, python.IPythonPackaging Submodule: python
Extends: Component
new python.Poetry(project: Project, options: PythonPackagingOptions)
[Project](#projen-project)
) No description[python.PythonPackagingOptions](#projen-python-pythonpackagingoptions)
) No description
string
) Author’s e-mail.string
) Author’s name.string
) Version of the package.Array</code>) A list of PyPI trove classifiers that describe the project. __*Optional*__
string
) A short description of the package. Optionalstring
) A URL to the website of the project. Optionalstring
) License of this package as an SPDX identifier. Optionalstring
) Package name. Optional[python.PoetryPyprojectOptionsWithoutDeps](#projen-python-poetrypyprojectoptionswithoutdeps)
) Additional options to set for poetry if using poetry. OptionalMap<string, any>
) Additional fields to pass in the setup() function if using setuptools. OptionalName | Type | Description |
---|---|---|
installTask🔹 | [Task](#projen-task) |
A task that installs and updates dependencies. |
publishTask🔹 | [Task](#projen-task) |
A task that uploads the package to a package repository. |
publishTestTask🔹 | [Task](#projen-task) |
A task that uploads the package to the Test PyPI repository. |
Adds a runtime dependency.
addDependency(spec: string): void
string
) Format <module>@<semver>
.Adds a dev dependency.
addDevDependency(spec: string): void
string
) Format <module>@<semver>
.Installs dependencies (called during post-synthesis).
installDependencies(): void
Initializes the virtual environment if it doesn’t exist (called during post-synthesis).
setupEnvironment(): void
Represents configuration of a pyproject.toml file for a Poetry project.
Submodule: python
Extends: Component
new python.PoetryPyproject(project: Project, options: PoetryPyprojectOptions)
[Project](#projen-project)
) No description[python.PoetryPyprojectOptions](#projen-python-poetrypyprojectoptions)
) No description
Array</code>) The authors of the package. __*Optional*__
Array</code>) A list of PyPI trove classifiers that describe the project. __*Optional*__
string
) A short description of the package (required). Optionalstring
) A URL to the documentation of the project. OptionalArray</code>) A list of patterns that will be excluded in the final package. __*Optional*__
Map<string, Array></code>) Package extras. __*Optional*__
string
) A URL to the website of the project. OptionalArray</code>) A list of patterns that will be included in the final package. __*Optional*__
Array</code>) A list of keywords (max: 5) that the package is related to. __*Optional*__
string
) License of this package as an SPDX identifier. OptionalArray</code>) the maintainers of the package. __*Optional*__
string
) Name of the package (required). OptionalArray</code>) A list of packages and modules to include in the final distribution. __*Optional*__
any
) Plugins. Optionalstring
) The name of the readme file of the package. Optionalstring
) A URL to the repository of the project. OptionalMap<string, any>
) The scripts or executables that will be installed when installing the package. OptionalArray</code>) Source registries from which packages are retrieved. __*Optional*__
Map<string, string>
) Project custom URLs, in addition to homepage, repository and documentation. Optionalstring
) Version of the package (required). OptionalMap<string, any>
) A list of dependencies for the project. OptionalMap<string, any>
) A list of development dependencies for the project. OptionalName | Type | Description |
---|---|---|
file🔹 | [TomlFile](#projen-tomlfile) |
Allows writing projenrc files in python.
This will install projen
as a Python dependency and will add a
synth
task which will run .projenrc.py
.
Submodule: python
Extends: ProjenrcFile
new python.Projenrc(project: Project, options?: ProjenrcOptions)
[Project](#projen-project)
) No description[python.ProjenrcOptions](#projen-python-projenrcoptions)
) No description
string
) The name of the projenrc file. Default: “.projenrc.py”string
) The projen version to use. Default: current versionstring
) Path to the python executable to use. Default: “python”Name | Type | Description |
---|---|---|
filePath🔹 | string |
The name of the projenrc file. |
pythonExec🔹 | string |
Path to the python executable to use. |
Submodule: python
Extends: Component
new python.Pytest(project: Project, options?: PytestOptions)
[Project](#projen-project)
) No description[python.PytestOptions](#projen-python-pytestoptions)
) No description
number
) Stop the testing process after the first N failures. Optionalstring
) Directory with tests. Default: ‘tests’string
) Pytest version. Default: “6.2.1”Name | Type | Description |
---|---|---|
testdir🔹 | string |
Python test code sample.
Submodule: python
Extends: Component
new python.PytestSample(project: Project, options: PytestSampleOptions)
[Project](#projen-project)
) No description[python.PytestSampleOptions](#projen-python-pytestsampleoptions)
) No description
string
) Name of the python package as used in imports and filenames.string
) Test directory.Python project.
Submodule: python
Extends: github.GitHubProject
new python.PythonProject(options: PythonProjectOptions)
[python.PythonProjectOptions](#projen-python-pythonprojectoptions)
) No description
string
) This is the name of your project.boolean
) Whether to commit the managed files by default. Default: true[IgnoreFileOptions](#projen-ignorefileoptions)
) Configuration options for .gitignore file. Optional[GitOptions](#projen-gitoptions)
) Configuration options for git. Optional[LoggerOptions](#projen-loggeroptions)
) Configure logging options such as verbosity. Default: {}string
) The root directory of the project. Default: “.”[Project](#projen-project)
) The parent project, if this project is part of a bigger project. Optionalstring
) The shell command to use in order to run the projen CLI. Default: “npx projen”boolean
) Generate (once) .projenrc.json (in JSON). Set to false
in order to disable .projenrc.json generation. Default: false[ProjenrcJsonOptions](#projen-projenrcjsonoptions)
) Options for .projenrc.json. Default: default optionsboolean
) Use renovatebot to handle dependency upgrades. Default: false[RenovatebotOptions](#projen-renovatebotoptions)
) Options for renovatebot. Default: default options[github.AutoApproveOptions](#projen-github-autoapproveoptions)
) Enable and configure the ‘auto approve’ workflow. Default: auto approve is disabledboolean
) Enable automatic merging on GitHub. Default: true[github.AutoMergeOptions](#projen-github-automergeoptions)
) Configure options for automatic merging on GitHub. Default: see defaults in AutoMergeOptions
boolean
) Add a clobber
task which resets the repo to origin. Default: true, but false for subprojectsboolean
) Add a VSCode development environment (used for GitHub Codespaces). Default: falseboolean
) Enable GitHub integration. Default: true[github.GitHubOptions](#projen-github-githuboptions)
) Options for GitHub integration. Default: see GitHubOptionsboolean
) Add a Gitpod development environment. Default: falseboolean
) Whether mergify should be enabled on this repository or not. Default: true[github.MergifyOptions](#projen-github-mergifyoptions)
) Options for mergify. Default: default options[ProjectType](#projen-projecttype)
) Which type of project this is (library/app). Default: ProjectType.UNKNOWN[github.GithubCredentials](#projen-github-githubcredentials)
) Choose a method of providing GitHub API access for projen workflows. Default: use a personal access token named PROJEN_GITHUB_TOKENstring
) The name of a secret which includes a GitHub Personal Access Token to be used by projen workflows. Default: “PROJEN_GITHUB_TOKEN”[SampleReadmeProps](#projen-samplereadmeprops)
) The README setup. Default: { filename: ‘README.md’, contents: ‘# replace this’ }boolean
) Auto-close of stale issues and pull request. Default: false[github.StaleOptions](#projen-github-staleoptions)
) Auto-close stale issues and pull requests. Default: see defaults in StaleOptions
boolean
) Enable VSCode integration. Default: truestring
) Author’s e-mail.string
) Author’s name.string
) Version of the package.Array</code>) A list of PyPI trove classifiers that describe the project. __*Optional*__
string
) A short description of the package. Optionalstring
) A URL to the website of the project. Optionalstring
) License of this package as an SPDX identifier. Optionalstring
) Package name. Optional[python.PoetryPyprojectOptionsWithoutDeps](#projen-python-poetrypyprojectoptionswithoutdeps)
) Additional options to set for poetry if using poetry. OptionalMap<string, any>
) Additional fields to pass in the setup() function if using setuptools. Optionalstring
) Name of the python package as used in imports and filenames.Array</code>) List of runtime dependencies for this project. __*Default*__: []
Array</code>) List of dev dependencies for this project. __*Default*__: []
boolean
) Use pip with a requirements.txt file to track project dependencies. Default: true, unless poetry is true, then falseboolean
) Use poetry to manage your project dependencies, virtual environment, and (optional) packaging/publishing. Default: falseboolean
) Use projenrc in javascript. Default: false[javascript.ProjenrcOptions](#projen-javascript-projenrcoptions)
) Options related to projenrc in JavaScript. Default: default optionsboolean
) Use projenrc in Python. Default: true[python.ProjenrcOptions](#projen-python-projenrcoptions)
) Options related to projenrc in python. Default: default optionsboolean
) Use projenrc in TypeScript. Default: false[typescript.ProjenrcTsOptions](#projen-typescript-projenrctsoptions)
) Options related to projenrc in TypeScript. Default: default optionsboolean
) Include pytest tests. Default: true[python.PytestOptions](#projen-python-pytestoptions)
) pytest options. Default: defaultsstring
) Path to the python executable to use. Default: “python”boolean
) Include sample code and test if the relevant directories don’t exist. Default: trueboolean
) Use setuptools with a setup.py script for packaging and publishing. Default: true, unless poetry is true, then falseboolean
) Use venv to manage a virtual environment for installing dependencies inside. Default: true, unless poetry is true, then false[python.VenvOptions](#projen-python-venvoptions)
) Venv options. Default: defaultsName | Type | Description |
---|---|---|
depsManager🔹 | [python.IPythonDeps](#projen-python-ipythondeps) |
API for managing dependencies. |
envManager🔹 | [python.IPythonEnv](#projen-python-ipythonenv) |
API for mangaging the Python runtime environment. |
moduleName🔹 | string |
Python module name (the project name, with any hyphens or periods replaced with underscores). |
version🔹 | string |
Version of the package for distribution (should follow semver). |
packagingManager?🔹 | [python.IPythonPackaging](#projen-python-ipythonpackaging) |
API for managing packaging the project as a library. Optional |
pytest?🔹 | [python.Pytest](#projen-python-pytest) |
Pytest component. Optional |
Adds a runtime dependency.
addDependency(spec: string): void
string
) Format <module>@<semver>
.Adds a dev dependency.
addDevDependency(spec: string): void
string
) Format <module>@<semver>
.Called after all components are synthesized.
Order is not guaranteed.
postSynthesize(): void
Python code sample.
Submodule: python
Extends: Component
new python.PythonSample(project: Project, options: PythonSampleOptions)
[Project](#projen-project)
) No description[python.PythonSampleOptions](#projen-python-pythonsampleoptions)
) No description
string
) Sample code directory.Specifies a list of packages to be installed using pip.
Submodule: python
Extends: FileBase
new python.RequirementsFile(project: Project, filePath: string, options: RequirementsFileOptions)
[Project](#projen-project)
) No descriptionstring
) No description[python.RequirementsFileOptions](#projen-python-requirementsfileoptions)
) No description
[python.IPackageProvider](#projen-python-ipackageprovider)
) Provide a list of packages that can be dynamically updated. OptionalAdds the specified packages provided in semver format.
Comment lines (start with #
) are ignored.
addPackages(...packages: string[]): void
string
) Package version in format <module>@<semver>
.Implemented by derived classes and returns the contents of the file to emit.
protected synthesizeContent(resolver: IResolver): string
[IResolver](#projen-iresolver)
) No descriptionReturns:
string
Python packaging script where package metadata can be placed.
Submodule: python
Extends: FileBase
new python.SetupPy(project: Project, options: SetupPyOptions)
[Project](#projen-project)
) No description[python.SetupPyOptions](#projen-python-setuppyoptions)
) No description
Map<string, any>
) Escape hatch to allow any value. Optionalstring
) Author’s e-mail. Optionalstring
) Author’s name. OptionalArray</code>) A list of PyPI trove classifiers that describe the project. __*Optional*__
string
) A short project description. Optionalstring
) Package’s Homepage / Website. Optionalstring
) The project license. Optionalstring
) Name of the package. OptionalArray</code>) List of submodules to be packaged. __*Optional*__
string
) Manually specify package version. OptionalImplemented by derived classes and returns the contents of the file to emit.
protected synthesizeContent(resolver: IResolver): string
[IResolver](#projen-iresolver)
) No descriptionReturns:
string
Manages packaging through setuptools with a setup.py script.
Implements: python.IPythonPackaging Submodule: python
Extends: Component
new python.Setuptools(project: Project, options: PythonPackagingOptions)
[Project](#projen-project)
) No description[python.PythonPackagingOptions](#projen-python-pythonpackagingoptions)
) No description
string
) Author’s e-mail.string
) Author’s name.string
) Version of the package.Array</code>) A list of PyPI trove classifiers that describe the project. __*Optional*__
string
) A short description of the package. Optionalstring
) A URL to the website of the project. Optionalstring
) License of this package as an SPDX identifier. Optionalstring
) Package name. Optional[python.PoetryPyprojectOptionsWithoutDeps](#projen-python-poetrypyprojectoptionswithoutdeps)
) Additional options to set for poetry if using poetry. OptionalMap<string, any>
) Additional fields to pass in the setup() function if using setuptools. OptionalName | Type | Description |
---|---|---|
publishTask🔹 | [Task](#projen-task) |
A task that uploads the package to a package repository. |
publishTestTask🔹 | [Task](#projen-task) |
A task that uploads the package to the Test PyPI repository. |
Manages a virtual environment through the Python venv module.
Implements: python.IPythonEnv Submodule: python
Extends: Component
new python.Venv(project: Project, options?: VenvOptions)
[Project](#projen-project)
) No description[python.VenvOptions](#projen-python-venvoptions)
) No description
string
) Name of directory to store the environment in. Default: “.env”string
) Path to the python executable to use. Default: “python”Initializes the virtual environment if it doesn’t exist (called during post-synthesis).
setupEnvironment(): void
Implements GitHub jobs for publishing modules to package managers.
Under the hood, it uses https://github.com/aws/publib
Submodule: release
Extends: Component
new release.Publisher(project: Project, options: PublisherOptions)
[Project](#projen-project)
) No description[release.PublisherOptions](#projen-release-publisheroptions)
) No description
string
) The name of the artifact to download (e.g. dist
).string
) The job ID that produces the build artifacts.string
) A GitHub workflow expression used as a condition for publishers. Default: no conditionboolean
) Do not actually publish, only print the commands that would be executed instead. Optionalboolean
) Create an issue when a publish task fails. Default: falsestring
) The label to apply to the issue marking failed publish tasks. Default: “failed-release”string
) No description Optionalstring
) Version requirement for publib
. Default: “latest”boolean
) Define publishing tasks that can be executed manually as well as workflows. Default: falsestring
) Container image to use for GitHub workflows. Default: default imagestring
) Node version to setup in GitHub workflows if any node-based CLI utilities are needed. Default: 16.xArray</code>) Github Runner selection labels. __*Default*__: ["ubuntu-latest"]
Name | Type | Description |
---|---|---|
artifactName🔹 | string |
|
buildJobId🔹 | string |
|
jsiiReleaseVersion⚠️ | string |
|
publibVersion🔹 | string |
|
condition?🔹 | string |
Optional |
static PUBLISH_GIT_TASK_NAME🔹 | string |
Adds pre publishing steps for the GitHub release job.
addGitHubPrePublishingSteps(...steps: JobStep[]): void
[github.workflows.JobStep](#projen-github-workflows-jobstep)
) The steps.
Map<string, string>
) Sets environment variables for steps to use in the runner environment. Optionalstring
) A unique identifier for the step. Optionalstring
) You can use the if conditional to prevent a job from running unless a condition is met. Optionalstring
) A name for your step to display on GitHub. Optionalstring
) Runs command-line programs using the operating system’s shell. Optionalstring
) Selects an action to run as part of a step in your job. OptionalMap<string, any>
) A map of the input parameters defined by the action. Optionalstring
) Specifies a working directory for a step. Optionalboolean
) Prevents a job from failing when a step fails. Optionalnumber
) The maximum number of minutes to run the step before killing the process. OptionalPublish to git.
This includes generating a project-level changelog and release tags.
publishToGit(options: GitPublishOptions): Task
[release.GitPublishOptions](#projen-release-gitpublishoptions)
) Options.
string
) The location of an .md file (relative to dist/
) that includes the changelog for the release.string
) The location of a text file (relative to dist/
) that contains the release tag.string
) The location of a text file (relative to dist/
) that contains the version number.string
) Branch to push to. Default: “main”string
) Override git-push command. Optionalstring
) The location of an .md file that includes the project-level changelog. OptionalReturns:
[Task](#projen-task)
Creates a GitHub Release.
publishToGitHubReleases(options: GitHubReleasesPublishOptions): void
[release.GitHubReleasesPublishOptions](#projen-release-githubreleasespublishoptions)
) Options.
Array<[github.workflows.JobStep](#projen-github-workflows-jobstep)>
) Steps to execute before executing the publishing command. These can be used to prepare the artifact for publishing if neede. Optional[github.workflows.Tools](#projen-github-workflows-tools)
) Additional tools to install in the publishing job. Default: no additional tools are installedstring
) The location of an .md file (relative to dist/
) that includes the changelog for the release.string
) The location of a text file (relative to dist/
) that contains the release tag.string
) The location of a text file (relative to dist/
) that contains the version number.Adds a go publishing job.
publishToGo(options?: GoPublishOptions): void
[release.GoPublishOptions](#projen-release-gopublishoptions)
) Options.
Array<[github.workflows.JobStep](#projen-github-workflows-jobstep)>
) Steps to execute before executing the publishing command. These can be used to prepare the artifact for publishing if neede. Optional[github.workflows.Tools](#projen-github-workflows-tools)
) Additional tools to install in the publishing job. Default: no additional tools are installedstring
) Branch to push to. Default: “main”string
) The commit message. Default: “chore(release): $VERSION”string
) The name of the secret that includes a GitHub deploy key used to push to the GitHub repository. Default: “GO_GITHUB_DEPLOY_KEY”string
) GitHub repository to push to. Default: derived from moduleName
string
) The name of the secret that includes a personal GitHub access token used to push to the GitHub repository. Default: “GO_GITHUB_TOKEN”boolean
) Use SSH to push to GitHub instead of a personal accses token. Default: falsestring
) The email to use in the release git commit. Default: “github-actions@github.com”string
) The user name to use for the release git commit. Default: “github-actions”Publishes artifacts from java/**
to Maven.
publishToMaven(options?: MavenPublishOptions): void
[release.MavenPublishOptions](#projen-release-mavenpublishoptions)
) Options.
Array<[github.workflows.JobStep](#projen-github-workflows-jobstep)>
) Steps to execute before executing the publishing command. These can be used to prepare the artifact for publishing if neede. Optional[github.workflows.Tools](#projen-github-workflows-tools)
) Additional tools to install in the publishing job. Default: no additional tools are installedstring
) URL of Nexus repository. Default: “https://oss.sonatype.org”string
) GitHub secret name which contains the GPG private key or file that includes it. Default: “MAVEN_GPG_PRIVATE_KEY_PASSPHRASE” or not set when using GitHub Packagesstring
) GitHub secret name which contains the GPG private key or file that includes it. Default: “MAVEN_GPG_PRIVATE_KEY” or not set when using GitHub Packagesstring
) GitHub secret name which contains the Password for maven repository. Default: “MAVEN_PASSWORD” or “GITHUB_TOKEN” when using GitHub Packagesstring
) Deployment repository when not deploying to Maven Central. Default: not setstring
) Used in maven settings for credential lookup (e.g. use github when publishing to GitHub). Default: “ossrh” (Maven Central) or “github” when using GitHub Packagesstring
) GitHub secret name which contains the Maven Central (sonatype) staging profile ID (e.g. 68a05363083174). Staging profile ID can be found in the URL of the “Releases” staging profile under “Staging Profiles” in https://oss.sonatype.org (e.g. https://oss.sonatype.org/#stagingProfiles;11a33451234521). Default: “MAVEN_STAGING_PROFILE_ID” or not set when using GitHub Packagesstring
) GitHub secret name which contains the Username for maven repository. Default: “MAVEN_USERNAME” or the GitHub Actor when using GitHub PackagesPublishes artifacts from js/**
to npm.
publishToNpm(options?: NpmPublishOptions): void
[release.NpmPublishOptions](#projen-release-npmpublishoptions)
) Options.
Array<[github.workflows.JobStep](#projen-github-workflows-jobstep)>
) Steps to execute before executing the publishing command. These can be used to prepare the artifact for publishing if neede. Optional[github.workflows.Tools](#projen-github-workflows-tools)
) Additional tools to install in the publishing job. Default: no additional tools are installed[release.CodeArtifactOptions](#projen-release-codeartifactoptions)
) Options for publishing npm package to AWS CodeArtifact. Default: undefinedstring
) Tags can be used to provide an alias instead of version numbers. Default: “latest”string
) GitHub secret which contains the NPM token to use when publishing packages. Default: “NPM_TOKEN” or “GITHUB_TOKEN” if registry
is set to npm.pkg.github.com
.string
) The domain name of the npm package registry. Default: “registry.npmjs.org”Publishes artifacts from dotnet/**
to NuGet Gallery.
publishToNuget(options?: NugetPublishOptions): void
[release.NugetPublishOptions](#projen-release-nugetpublishoptions)
) Options.
Array<[github.workflows.JobStep](#projen-github-workflows-jobstep)>
) Steps to execute before executing the publishing command. These can be used to prepare the artifact for publishing if neede. Optional[github.workflows.Tools](#projen-github-workflows-tools)
) Additional tools to install in the publishing job. Default: no additional tools are installedstring
) GitHub secret which contains the API key for NuGet. Default: “NUGET_API_KEY”string
) NuGet Server URL (defaults to nuget.org). OptionalPublishes wheel artifacts from python
to PyPI.
publishToPyPi(options?: PyPiPublishOptions): void
[release.PyPiPublishOptions](#projen-release-pypipublishoptions)
) Options.
Array<[github.workflows.JobStep](#projen-github-workflows-jobstep)>
) Steps to execute before executing the publishing command. These can be used to prepare the artifact for publishing if neede. Optional[github.workflows.Tools](#projen-github-workflows-tools)
) Additional tools to install in the publishing job. Default: no additional tools are installedstring
) The GitHub secret which contains PyPI password. Default: “TWINE_PASSWORD”string
) The registry url to use when releasing packages. Default: twine defaultstring
) The GitHub secret which contains PyPI user name. Default: “TWINE_USERNAME”Manages releases (currently through GitHub workflows).
By default, no branches are released. To add branches, call addBranch()
.
Submodule: release
Extends: Component
new release.Release(project: GitHubProject, options: ReleaseOptions)
[github.GitHubProject](#projen-github-githubproject)
) No description[release.ReleaseOptions](#projen-release-releaseoptions)
) No description
string
) Version requirement of publib
which is used to publish modules to npm. Default: “latest”number
) Major version to release from the default branch. Default: Major version is not enforced.number
) Minimal Major version to release. Default: No minimum version is being enforcedstring
) The npmDistTag to use when publishing from the default branch. Default: “latest”Array<[github.workflows.JobStep](#projen-github-workflows-jobstep)>
) Steps to execute after build as part of the release workflow. Default: []string
) Bump versions from the default branch as pre-releases (e.g. “beta”, “alpha”, “pre”). Default: normal semantic versionsboolean
) Instead of actually publishing to package managers, just print the publishing command. Default: falseboolean
) Define publishing tasks that can be executed manually as well as workflows. Default: falseMap<string, [release.BranchOptions](#projen-release-branchoptions)>
) Defines additional release branches. Default: no additional branches are used for release. you can use addBranch()
to add additional branches.boolean
) Automatically release new versions every commit to one of branches in releaseBranches
. Default: trueboolean
) Create a github issue on every failed publishing task. Default: falsestring
) The label to apply to issues indicating publish failures. Default: “failed-release”string
) CRON schedule to trigger new releases. Default: no scheduled releasesstring
) Automatically add the given prefix to release tags. Useful if you are releasing on multiple branches with overlapping version numbers. Default: “v”[release.ReleaseTrigger](#projen-release-releasetrigger)
) The release trigger to use. Default: Continuous releases (ReleaseTrigger.continuous()
)string
) The name of the default release workflow. Default: “Release”Array<[github.workflows.JobStep](#projen-github-workflows-jobstep)>
) A set of workflow steps to execute in order to setup the workflow container. OptionalMap<string, any>
) Custom configuration used when creating changelog with standard-version package. Default: standard configuration applicable for GitHub repositoriesstring
) Container image to use for GitHub workflows. Default: default imageArray</code>) Github Runner selection labels. __*Default*__: ["ubuntu-latest"]
string
) A directory which will contain build artifacts.string
) The default branch name to release from.[Task](#projen-task)
) The task to execute in order to create the release artifacts.string
) A name of a .json file to set the version
field in after a bump.boolean
) Create a GitHub release for each release. Default: truestring
) Node version to setup in GitHub workflows if any node-based CLI utilities are needed. Default: 16.x[github.workflows.JobPermissions](#projen-github-workflows-jobpermissions)
) Permissions granted to the release workflow job. Default: { contents: JobPermission.WRITE }
Name | Type | Description |
---|---|---|
artifactsDirectory🔹 | string |
Location of build artifacts. |
branches🔹 | Array |
Retrieve all release branch names. |
publisher🔹 | [release.Publisher](#projen-release-publisher) |
Package publisher. |
static ANTI_TAMPER_CMD🔹 | string |
Adds a release branch.
It is a git branch from which releases are published. If a project has more than one release
branch, we require that majorVersion
is also specified for the primary branch in order to
ensure branches always release the correct version.
addBranch(branch: string, options: BranchOptions): void
string
) The branch to monitor (e.g. main
, v2.x
).[release.BranchOptions](#projen-release-branchoptions)
) Branch definition.
number
) The major versions released from this branch.number
) The minimum major version to release. Optionalstring
) The npm distribution tag to use for this branch. Default: “latest”string
) Bump the version as a pre-release tag. Default: normal releasesstring
) Automatically add the given prefix to release tags. Useful if you are releasing on multiple branches with overlapping version numbers. Default: no prefixstring
) The name of the release workflow. Default: “release-BRANCH”Adds jobs to all release workflows.
addJobs(jobs: Map<string, Job>): void
Map<string, [github.workflows.Job](#projen-github-workflows-job)>
) The jobs to add (name => job).Called before synthesis.
preSynthesize(): void
Returns the Release
component of a project or undefined
if the project does not have a Release component.
static of(project: GitHubProject): Release
[github.GitHubProject](#projen-github-githubproject)
) No descriptionReturns:
[release.Release](#projen-release-release)
Used to manage release strategies.
This includes release and release artifact automation
Submodule: release
Name | Type | Description |
---|---|---|
isContinuous🔹 | boolean |
Whether or not this is a continuous release. |
isManual🔹 | boolean |
Whether or not this is a manual release trigger. |
changelogPath?🔹 | string |
Project-level changelog file path. Optional |
gitPushCommand?🔹 | string |
Override git-push command used when releasing manually. Optional |
schedule?🔹 | string |
Cron schedule for releases. Optional |
Creates a continuous release trigger.
Automated releases will occur on every commit.
static continuous(): ReleaseTrigger
Returns:
[release.ReleaseTrigger](#projen-release-releasetrigger)
Creates a manual release trigger.
Use this option if you want totally manual releases.
This will give you a release task that, in addition to the normal
release activities will trigger a publish:git
task. This task will
handle project-level changelog management, release tagging, and pushing
these artifacts to origin.
The command used for pushing can be customised by specifying
gitPushCommand
. Set to an empty string to disable pushing entirely.
Simply run yarn release
to trigger a manual release.
static manual(options?: ManualReleaseOptions): ReleaseTrigger
[release.ManualReleaseOptions](#projen-release-manualreleaseoptions)
) release options.
boolean
) Maintain a project-level changelog. Default: truestring
) Project-level changelog file path. Default: ‘CHANGELOG.md’string
) Override git-push command. OptionalReturns:
[release.ReleaseTrigger](#projen-release-releasetrigger)
Creates a scheduled release trigger.
Automated releases will occur based on the provided cron schedule.
static scheduled(options: ScheduledReleaseOptions): ReleaseTrigger
[release.ScheduledReleaseOptions](#projen-release-scheduledreleaseoptions)
) release options.
string
) Cron schedule for releases.Returns:
[release.ReleaseTrigger](#projen-release-releasetrigger)
Sets up a typescript project to use TypeScript for projenrc.
Submodule: typescript
Extends: ProjenrcFile
new typescript.Projenrc(project: TypeScriptProject, options?: ProjenrcOptions)
[typescript.TypeScriptProject](#projen-typescript-typescriptproject)
) No description[typescript.ProjenrcOptions](#projen-typescript-projenrcoptions)
) No description
string
) The name of the projenrc file. Default: “.projenrc.ts”string
) A directory tree that may contain *.ts files that can be referenced from your projenrc typescript file. Default: “projenrc”boolean
) Whether to use SWC
for ts-node. Default: falseName | Type | Description |
---|---|---|
filePath🔹 | string |
The path of the projenrc file. |
Called before synthesis.
preSynthesize(): void
A projenrc file written in TypeScript.
This component can be instantiated in any type of project and has no expectations around the project’s main language.
Requires that npx
is available.
Submodule: typescript
Extends: ProjenrcFile
new typescript.ProjenrcTs(project: Project, options?: ProjenrcTsOptions)
[Project](#projen-project)
) No description[typescript.ProjenrcTsOptions](#projen-typescript-projenrctsoptions)
) No description
string
) The name of the projenrc file. Default: “.projenrc.ts”string
) A directory tree that may contain *.ts files that can be referenced from your projenrc typescript file. Default: “projenrc”string
) The name of the tsconfig file that will be used by ts-node when compiling projen source files. Default: “tsconfig.projen.json”Name | Type | Description |
---|---|---|
filePath🔹 | string |
The path of the projenrc file. |
tsconfig🔹 | [javascript.TypescriptConfig](#projen-javascript-typescriptconfig) |
TypeScript configuration file used to compile projen source files. |
Called before synthesis.
preSynthesize(): void
TypeScript app.
Submodule: typescript
Extends: typescript.TypeScriptProject
new typescript.TypeScriptAppProject(options: TypeScriptProjectOptions)
[typescript.TypeScriptProjectOptions](#projen-typescript-typescriptprojectoptions)
) No description
string
) This is the name of your project.boolean
) Whether to commit the managed files by default. Default: true[IgnoreFileOptions](#projen-ignorefileoptions)
) Configuration options for .gitignore file. Optional[GitOptions](#projen-gitoptions)
) Configuration options for git. Optional[LoggerOptions](#projen-loggeroptions)
) Configure logging options such as verbosity. Default: {}string
) The root directory of the project. Default: “.”[Project](#projen-project)
) The parent project, if this project is part of a bigger project. Optionalstring
) The shell command to use in order to run the projen CLI. Default: “npx projen”boolean
) Generate (once) .projenrc.json (in JSON). Set to false
in order to disable .projenrc.json generation. Default: false[ProjenrcJsonOptions](#projen-projenrcjsonoptions)
) Options for .projenrc.json. Default: default optionsboolean
) Use renovatebot to handle dependency upgrades. Default: false[RenovatebotOptions](#projen-renovatebotoptions)
) Options for renovatebot. Default: default options[github.AutoApproveOptions](#projen-github-autoapproveoptions)
) Enable and configure the ‘auto approve’ workflow. Default: auto approve is disabledboolean
) Enable automatic merging on GitHub. Default: true[github.AutoMergeOptions](#projen-github-automergeoptions)
) Configure options for automatic merging on GitHub. Default: see defaults in AutoMergeOptions
boolean
) Add a clobber
task which resets the repo to origin. Default: true, but false for subprojectsboolean
) Add a VSCode development environment (used for GitHub Codespaces). Default: falseboolean
) Enable GitHub integration. Default: true[github.GitHubOptions](#projen-github-githuboptions)
) Options for GitHub integration. Default: see GitHubOptionsboolean
) Add a Gitpod development environment. Default: falseboolean
) Whether mergify should be enabled on this repository or not. Default: true[github.MergifyOptions](#projen-github-mergifyoptions)
) Options for mergify. Default: default options[ProjectType](#projen-projecttype)
) Which type of project this is (library/app). Default: ProjectType.UNKNOWN[github.GithubCredentials](#projen-github-githubcredentials)
) Choose a method of providing GitHub API access for projen workflows. Default: use a personal access token named PROJEN_GITHUB_TOKENstring
) The name of a secret which includes a GitHub Personal Access Token to be used by projen workflows. Default: “PROJEN_GITHUB_TOKEN”[SampleReadmeProps](#projen-samplereadmeprops)
) The README setup. Default: { filename: ‘README.md’, contents: ‘# replace this’ }boolean
) Auto-close of stale issues and pull request. Default: false[github.StaleOptions](#projen-github-staleoptions)
) Auto-close stale issues and pull requests. Default: see defaults in StaleOptions
boolean
) Enable VSCode integration. Default: trueboolean
) Allow the project to include peerDependencies
and bundledDependencies
. Default: truestring
) Author’s e-mail. Optionalstring
) Author’s name. Optionalboolean
) Is the author an organization. Optionalstring
) Author’s URL / Website. Optionalboolean
) Automatically add all executables under the bin
directory to your package.json
file under the bin
section. Default: trueMap<string, string>
) Binary programs vended with your module. Optionalstring
) The email address to which issues should be reported. Optionalstring
) The url to your project’s issue tracker. OptionalArray</code>) List of dependencies to bundle into this module. __*Optional*__
[javascript.CodeArtifactOptions](#projen-javascript-codeartifactoptions)
) Options for npm packages using AWS CodeArtifact. Default: undefinedArray</code>) Runtime dependencies of this module. __*Default*__: []
string
) The description is just a string that helps people understand the purpose of the package. OptionalArray</code>) Build dependencies for this module. __*Default*__: []
string
) Module entrypoint (main
in package.json
). Default: “lib/index.js”string
) Package’s Homepage / Website. OptionalArray</code>) Keywords to include in `package.json`. __*Optional*__
string
) License’s SPDX identifier. Default: “Apache-2.0”boolean
) Indicates if a license should be added. Default: truestring
) Minimum node.js version to require via engines
(inclusive). Default: no maxstring
) Minimum Node.js version to require via package.json engines
(inclusive). Default: no “engines” specified[javascript.NpmAccess](#projen-javascript-npmaccess)
) Access level of the npm package. Default: for scoped packages (e.g. foo@bar
), the default is NpmAccess.RESTRICTED
, for non-scoped packages, the default is NpmAccess.PUBLIC
.string
) The host name of the npm registry to publish to. Optionalstring
) The base URL of the npm package registry. Default: “https://registry.npmjs.org”string
) GitHub secret which contains the NPM token to use when publishing packages. Default: “NPM_TOKEN”[javascript.NodePackageManager](#projen-javascript-nodepackagemanager)
) The Node Package Manager used to execute scripts. Default: NodePackageManager.YARNstring
) The “name” in package.json. Default: defaults to project name[javascript.PeerDependencyOptions](#projen-javascript-peerdependencyoptions)
) Options for peerDeps
. OptionalArray</code>) Peer dependencies for this module. __*Default*__: []
string
) The version of PNPM to use if using PNPM as a package manager. Default: “7”string
) The repository is the location where the actual code for your package lives. Optionalstring
) If the package.json for your package is not in the root directory (for example if it is part of a monorepo), you can specify the directory in which it lives. OptionalArray<[javascript.ScopedPackagesOptions](#projen-javascript-scopedpackagesoptions)>
) Options for privately hosted scoped packages. Default: fetch all scoped packages from the public npm registryMap<string, string>
) npm scripts to include. Default: {}string
) Package’s Stability. Optionalstring
) Version requirement of publib
which is used to publish modules to npm. Default: “latest”number
) Major version to release from the default branch. Default: Major version is not enforced.number
) Minimal Major version to release. Default: No minimum version is being enforcedstring
) The npmDistTag to use when publishing from the default branch. Default: “latest”Array<[github.workflows.JobStep](#projen-github-workflows-jobstep)>
) Steps to execute after build as part of the release workflow. Default: []string
) Bump versions from the default branch as pre-releases (e.g. “beta”, “alpha”, “pre”). Default: normal semantic versionsboolean
) Instead of actually publishing to package managers, just print the publishing command. Default: falseboolean
) Define publishing tasks that can be executed manually as well as workflows. Default: falseMap<string, [release.BranchOptions](#projen-release-branchoptions)>
) Defines additional release branches. Default: no additional branches are used for release. you can use addBranch()
to add additional branches.boolean
) Automatically release new versions every commit to one of branches in releaseBranches
. Default: trueboolean
) Create a github issue on every failed publishing task. Default: falsestring
) The label to apply to issues indicating publish failures. Default: “failed-release”string
) CRON schedule to trigger new releases. Default: no scheduled releasesstring
) Automatically add the given prefix to release tags. Useful if you are releasing on multiple branches with overlapping version numbers. Default: “v”[release.ReleaseTrigger](#projen-release-releasetrigger)
) The release trigger to use. Default: Continuous releases (ReleaseTrigger.continuous()
)string
) The name of the default release workflow. Default: “Release”Array<[github.workflows.JobStep](#projen-github-workflows-jobstep)>
) A set of workflow steps to execute in order to setup the workflow container. OptionalMap<string, any>
) Custom configuration used when creating changelog with standard-version package. Default: standard configuration applicable for GitHub repositoriesstring
) Container image to use for GitHub workflows. Default: default imageArray</code>) Github Runner selection labels. __*Default*__: ["ubuntu-latest"]
string
) The name of the main release branch.string
) A directory which will contain build artifacts. Default: “dist”boolean
) Automatically approve deps upgrade PRs, allowing them to be merged by mergify (if configued). Default: trueboolean
) Define a GitHub workflow for building PRs. Default: true if not a subproject[github.workflows.Triggers](#projen-github-workflows-triggers)
) Build workflow triggers. Default: “{ pullRequest: {}, workflowDispatch: {} }”[javascript.BundlerOptions](#projen-javascript-bundleroptions)
) Options for Bundler
. Optionalboolean
) Define a GitHub workflow step for sending code coverage metrics to https://codecov.io/ Uses codecov/codecov-action@v3 A secret is required for private repos. Configured with @codeCovTokenSecret. Default: falsestring
) Define the secret name for a specified https://codecov.io/ token A secret is required to send coverage for private repositories. Default: if this option is not specified, only public repositories are supportedstring
) License copyright owner. Default: defaults to the value of authorName or “” if authorName
is undefined.string
) The copyright years to put in the LICENSE file. Default: current yearboolean
) Use dependabot to handle dependency upgrades. Default: false[github.DependabotOptions](#projen-github-dependabotoptions)
) Options for dependabot. Default: default optionsboolean
) Use github workflows to handle dependency upgrades. Default: true[javascript.UpgradeDependenciesOptions](#projen-javascript-upgradedependenciesoptions)
) Options for UpgradeDependencies
. Default: default optionsArray</code>) Additional entries to .gitignore. __*Optional*__
boolean
) Setup jest unit tests. Default: true[javascript.JestOptions](#projen-javascript-jestoptions)
) Jest options. Default: default optionsboolean
) Automatically update files modified during builds to pull-request branches. Default: trueArray</code>) Additional entries to .npmignore. __*Optional*__
boolean
) Defines an .npmignore file. Normally this is only needed for libraries that are packaged as tarballs. Default: true[IgnoreFileOptions](#projen-ignorefileoptions)
) Configuration options for .npmignore file. Optionalboolean
) Defines a package
task that will produce an npm tarball under the artifacts directory (e.g. dist
). Default: trueboolean
) Setup prettier. Default: false[javascript.PrettierOptions](#projen-javascript-prettieroptions)
) Prettier options. Default: default optionsboolean
) Indicates of “projen” should be installed as a devDependency. Default: trueboolean
) Generate (once) .projenrc.js (in JavaScript). Set to false
in order to disable .projenrc.js generation. Default: true if projenrcJson is false[javascript.ProjenrcOptions](#projen-javascript-projenrcoptions)
) Options for .projenrc.js. Default: default optionsstring
) Version of projen to install. Default: Defaults to the latest version.boolean
) Include a GitHub pull request template. Default: trueArray</code>) The contents of the pull request template. __*Default*__: default content
boolean
) Add release management to this project. Default: true (false for subprojects)boolean
) Automatically release to npm when new versions are introduced. Default: falseboolean
) DEPRECATED: renamed to release
. Default: true if not a subprojectArray<[github.workflows.JobStep](#projen-github-workflows-jobstep)>
) Workflow steps to use in order to bootstrap this repo. Default: “yarn install –frozen-lockfile && yarn projen”[github.GitIdentity](#projen-github-gitidentity)
) The git identity to use in workflows. Default: GitHub Actionsstring
) The node version to use in GitHub workflows. Default: same as minNodeVersion