@Stability(value=Experimental) public static final class PythonProject.Builder extends Object implements software.amazon.jsii.Builder<PythonProject>
PythonProject.| Modifier and Type | Method and Description |
|---|---|
PythonProject.Builder |
authorEmail(String authorEmail)
(experimental) Author's e-mail.
|
PythonProject.Builder |
authorName(String authorName)
(experimental) Author's name.
|
PythonProject.Builder |
autoApproveOptions(AutoApproveOptions autoApproveOptions)
(experimental) Enable and configure the 'auto approve' workflow.
|
PythonProject.Builder |
autoMergeOptions(AutoMergeOptions autoMergeOptions)
(experimental) Configure options for automatic merging on GitHub.
|
PythonProject |
build() |
PythonProject.Builder |
classifiers(List<String> classifiers)
(experimental) A list of PyPI trove classifiers that describe the project.
|
PythonProject.Builder |
clobber(Boolean clobber)
(experimental) Add a `clobber` task which resets the repo to origin.
|
static PythonProject.Builder |
create() |
PythonProject.Builder |
deps(List<String> deps)
(experimental) List of runtime dependencies for this project.
|
PythonProject.Builder |
description(String description)
(experimental) A short description of the package.
|
PythonProject.Builder |
devContainer(Boolean devContainer)
(experimental) Add a VSCode development environment (used for GitHub Codespaces).
|
PythonProject.Builder |
devDeps(List<String> devDeps)
(experimental) List of dev dependencies for this project.
|
PythonProject.Builder |
github(Boolean github)
(experimental) Enable GitHub integration.
|
PythonProject.Builder |
githubOptions(GitHubOptions githubOptions)
(experimental) Options for GitHub integration.
|
PythonProject.Builder |
gitpod(Boolean gitpod)
(experimental) Add a Gitpod development environment.
|
PythonProject.Builder |
homepage(String homepage)
(experimental) A URL to the website of the project.
|
PythonProject.Builder |
license(String license)
(experimental) License of this package as an SPDX identifier.
|
PythonProject.Builder |
logging(LoggerOptions logging)
(experimental) Configure logging options such as verbosity.
|
PythonProject.Builder |
mergify(Boolean mergify)
Deprecated.
use `githubOptions.mergify` instead
|
PythonProject.Builder |
mergifyOptions(MergifyOptions mergifyOptions)
Deprecated.
use `githubOptions.mergifyOptions` instead
|
PythonProject.Builder |
moduleName(String moduleName)
(experimental) Name of the python package as used in imports and filenames.
|
PythonProject.Builder |
name(String name)
(experimental) This is the name of your project.
|
PythonProject.Builder |
outdir(String outdir)
(experimental) The root directory of the project.
|
PythonProject.Builder |
parent(Project parent)
(experimental) The parent project, if this project is part of a bigger project.
|
PythonProject.Builder |
pip(Boolean pip)
(experimental) Use pip with a requirements.txt file to track project dependencies.
|
PythonProject.Builder |
poetry(Boolean poetry)
(experimental) Use poetry to manage your project dependencies, virtual environment, and (optional) packaging/publishing.
|
PythonProject.Builder |
poetryOptions(PoetryPyprojectOptionsWithoutDeps poetryOptions)
(experimental) Additional options to set for poetry if using poetry.
|
PythonProject.Builder |
projectType(ProjectType projectType)
Deprecated.
no longer supported at the base project level
|
PythonProject.Builder |
projenCommand(String projenCommand)
(experimental) The shell command to use in order to run the projen CLI.
|
PythonProject.Builder |
projenrcJson(Boolean projenrcJson)
(experimental) Generate (once) .projenrc.json (in JSON).
|
PythonProject.Builder |
projenrcJsonOptions(ProjenrcOptions projenrcJsonOptions)
(experimental) Options for .projenrc.json.
|
PythonProject.Builder |
projenrcPython(Boolean projenrcPython)
(experimental) Use projenrc in python.
|
PythonProject.Builder |
projenrcPythonOptions(ProjenrcOptions projenrcPythonOptions)
(experimental) Options related to projenrc in python.
|
PythonProject.Builder |
pytest(Boolean pytest)
(experimental) Include pytest tests.
|
PythonProject.Builder |
pytestOptions(PytestOptions pytestOptions)
(experimental) pytest options.
|
PythonProject.Builder |
readme(SampleReadmeProps readme)
(experimental) The README setup.
|
PythonProject.Builder |
sample(Boolean sample)
(experimental) Include sample code and test if the relevant directories don't exist.
|
PythonProject.Builder |
setupConfig(Map<String,? extends Object> setupConfig)
(experimental) Additional fields to pass in the setup() function if using setuptools.
|
PythonProject.Builder |
setuptools(Boolean setuptools)
(experimental) Use setuptools with a setup.py script for packaging and publishing.
|
PythonProject.Builder |
stale(Boolean stale)
(experimental) Auto-close of stale issues and pull request.
|
PythonProject.Builder |
staleOptions(StaleOptions staleOptions)
(experimental) Auto-close stale issues and pull requests.
|
PythonProject.Builder |
venv(Boolean venv)
(experimental) Use venv to manage a virtual environment for installing dependencies inside.
|
PythonProject.Builder |
venvOptions(VenvOptions venvOptions)
(experimental) Venv options.
|
PythonProject.Builder |
version(String version)
(experimental) Version of the package.
|
PythonProject.Builder |
vscode(Boolean vscode)
(experimental) Enable VSCode integration.
|
@Stability(value=Experimental) public static PythonProject.Builder create()
PythonProject.Builder.@Stability(value=Experimental) public PythonProject.Builder name(String name)
Default: $BASEDIR
name - This is the name of your project. This parameter is required.this@Stability(value=Experimental) public PythonProject.Builder logging(LoggerOptions logging)
Default: {}
logging - Configure logging options such as verbosity. This parameter is required.this@Stability(value=Experimental) public PythonProject.Builder outdir(String outdir)
Relative to this directory, all files are synthesized.
If this project has a parent, this directory is relative to the parent directory and it cannot be the same as the parent or any of it's other sub-projects.
Default: "."
outdir - The root directory of the project. This parameter is required.this@Stability(value=Experimental) public PythonProject.Builder parent(Project parent)
parent - The parent project, if this project is part of a bigger project. This parameter is required.this@Stability(value=Experimental) public PythonProject.Builder projenCommand(String projenCommand)
Can be used to customize in special environments.
Default: "npx projen"
projenCommand - The shell command to use in order to run the projen CLI. This parameter is required.this@Stability(value=Experimental) public PythonProject.Builder projenrcJson(Boolean projenrcJson)
Default: false
projenrcJson - Generate (once) .projenrc.json (in JSON). Set to `false` in order to disable .projenrc.json generation. This parameter is required.this@Stability(value=Experimental) public PythonProject.Builder projenrcJsonOptions(ProjenrcOptions projenrcJsonOptions)
Default: - default options
projenrcJsonOptions - Options for .projenrc.json. This parameter is required.this@Stability(value=Experimental) public PythonProject.Builder autoApproveOptions(AutoApproveOptions autoApproveOptions)
Default: - auto approve is disabled
autoApproveOptions - Enable and configure the 'auto approve' workflow. This parameter is required.this@Stability(value=Experimental) public PythonProject.Builder autoMergeOptions(AutoMergeOptions autoMergeOptions)
Has no effect if
github.mergify is set to false.
Default: - see defaults in `AutoMergeOptions`
autoMergeOptions - Configure options for automatic merging on GitHub. This parameter is required.this@Stability(value=Experimental) public PythonProject.Builder clobber(Boolean clobber)
Default: true
clobber - Add a `clobber` task which resets the repo to origin. This parameter is required.this@Stability(value=Experimental) public PythonProject.Builder devContainer(Boolean devContainer)
Default: false
devContainer - Add a VSCode development environment (used for GitHub Codespaces). This parameter is required.this@Stability(value=Experimental) public PythonProject.Builder github(Boolean github)
Enabled by default for root projects. Disabled for non-root projects.
Default: true
github - Enable GitHub integration. This parameter is required.this@Stability(value=Experimental) public PythonProject.Builder githubOptions(GitHubOptions githubOptions)
Default: - see GitHubOptions
githubOptions - Options for GitHub integration. This parameter is required.this@Stability(value=Experimental) public PythonProject.Builder gitpod(Boolean gitpod)
Default: false
gitpod - Add a Gitpod development environment. This parameter is required.this@Stability(value=Deprecated) @Deprecated public PythonProject.Builder mergify(Boolean mergify)
Default: true
mergify - Whether mergify should be enabled on this repository or not. This parameter is required.this@Stability(value=Deprecated) @Deprecated public PythonProject.Builder mergifyOptions(MergifyOptions mergifyOptions)
Default: - default options
mergifyOptions - Options for mergify. This parameter is required.this@Stability(value=Deprecated) @Deprecated public PythonProject.Builder projectType(ProjectType projectType)
Default: ProjectType.UNKNOWN
projectType - Which type of project this is (library/app). This parameter is required.this@Stability(value=Experimental) public PythonProject.Builder readme(SampleReadmeProps readme)
Default: - { filename: 'README.md', contents: '# replace this' }
Example:
// Example automatically generated from non-compiling source. May contain errors.
"{ filename: 'readme.md', contents: '# title' }"
readme - The README setup. This parameter is required.this@Stability(value=Experimental) public PythonProject.Builder stale(Boolean stale)
See staleOptions for options.
Default: true
stale - Auto-close of stale issues and pull request. This parameter is required.this@Stability(value=Experimental) public PythonProject.Builder staleOptions(StaleOptions staleOptions)
To disable set stale to false.
Default: - see defaults in `StaleOptions`
staleOptions - Auto-close stale issues and pull requests. This parameter is required.this@Stability(value=Experimental) public PythonProject.Builder vscode(Boolean vscode)
Enabled by default for root projects. Disabled for non-root projects.
Default: true
vscode - Enable VSCode integration. This parameter is required.this@Stability(value=Experimental) public PythonProject.Builder authorEmail(String authorEmail)
Default: $GIT_USER_EMAIL
authorEmail - Author's e-mail. This parameter is required.this@Stability(value=Experimental) public PythonProject.Builder authorName(String authorName)
Default: $GIT_USER_NAME
authorName - Author's name. This parameter is required.this@Stability(value=Experimental) public PythonProject.Builder version(String version)
Default: "0.1.0"
version - Version of the package. This parameter is required.this@Stability(value=Experimental) public PythonProject.Builder classifiers(List<String> classifiers)
classifiers - A list of PyPI trove classifiers that describe the project. This parameter is required.thishttps://pypi.org/classifiers/@Stability(value=Experimental) public PythonProject.Builder description(String description)
description - A short description of the package. This parameter is required.this@Stability(value=Experimental) public PythonProject.Builder homepage(String homepage)
homepage - A URL to the website of the project. This parameter is required.this@Stability(value=Experimental) public PythonProject.Builder license(String license)
license - License of this package as an SPDX identifier. This parameter is required.this@Stability(value=Experimental) public PythonProject.Builder poetryOptions(PoetryPyprojectOptionsWithoutDeps poetryOptions)
poetryOptions - Additional options to set for poetry if using poetry. This parameter is required.this@Stability(value=Experimental) public PythonProject.Builder setupConfig(Map<String,? extends Object> setupConfig)
setupConfig - Additional fields to pass in the setup() function if using setuptools. This parameter is required.this@Stability(value=Experimental) public PythonProject.Builder moduleName(String moduleName)
Must only consist of alphanumeric characters and underscores.
Default: $PYTHON_MODULE_NAME
moduleName - Name of the python package as used in imports and filenames. This parameter is required.this@Stability(value=Experimental) public PythonProject.Builder deps(List<String> deps)
Dependencies use the format: <module>@<semver>
Additional dependencies can be added via project.addDependency().
Default: []
deps - List of runtime dependencies for this project. This parameter is required.this@Stability(value=Experimental) public PythonProject.Builder devDeps(List<String> devDeps)
Dependencies use the format: <module>@<semver>
Additional dependencies can be added via project.addDevDependency().
Default: []
devDeps - List of dev dependencies for this project. This parameter is required.this@Stability(value=Experimental) public PythonProject.Builder pip(Boolean pip)
Default: true
pip - Use pip with a requirements.txt file to track project dependencies. This parameter is required.this@Stability(value=Experimental) public PythonProject.Builder poetry(Boolean poetry)
Default: false
poetry - Use poetry to manage your project dependencies, virtual environment, and (optional) packaging/publishing. This parameter is required.this@Stability(value=Experimental) public PythonProject.Builder projenrcPython(Boolean projenrcPython)
This will install projen as a python dependency and will add a synth
task which will run .projenrc.py.
Default: true
projenrcPython - Use projenrc in python. This parameter is required.this@Stability(value=Experimental) public PythonProject.Builder projenrcPythonOptions(ProjenrcOptions projenrcPythonOptions)
Default: - default options
projenrcPythonOptions - Options related to projenrc in python. This parameter is required.this@Stability(value=Experimental) public PythonProject.Builder pytest(Boolean pytest)
Default: true
pytest - Include pytest tests. This parameter is required.this@Stability(value=Experimental) public PythonProject.Builder pytestOptions(PytestOptions pytestOptions)
Default: - defaults
pytestOptions - pytest options. This parameter is required.this@Stability(value=Experimental) public PythonProject.Builder sample(Boolean sample)
Default: true
sample - Include sample code and test if the relevant directories don't exist. This parameter is required.this@Stability(value=Experimental) public PythonProject.Builder setuptools(Boolean setuptools)
Default: - true if the project type is library
setuptools - Use setuptools with a setup.py script for packaging and publishing. This parameter is required.this@Stability(value=Experimental) public PythonProject.Builder venv(Boolean venv)
Default: true
venv - Use venv to manage a virtual environment for installing dependencies inside. This parameter is required.this@Stability(value=Experimental) public PythonProject.Builder venvOptions(VenvOptions venvOptions)
Default: - defaults
venvOptions - Venv options. This parameter is required.this@Stability(value=Experimental) public PythonProject build()
build in interface software.amazon.jsii.Builder<PythonProject>Copyright © 2021. All rights reserved.