pipx is used to install tools like copier independent of other tools' or projects' dependencies:
- install
pipxaccording to the documentation here. - install
copierwith pipx:pipx install copier(tested withcopier==9.7.1). - it's recommended to use a virtual environment. If you don't have
virtualenvinstalled, install it with:pipx install virtualenv. - if you want to use Poetry for managing your project's dependencies, install Poetry:
pipx install poetry(tested withpoetry==2.2.1). - if you want to use uv for managing your project's dependencies, install uv:
pipx install uv(tested withuv==0.9.7) or see here for instructions.
- generate your project:
copier copy git@github.com:zauberzeug/nicegui-template.git path/to/project- explore your new project:
cd path/to/project- initialize a git repo:
git initNow you can connect your local repository to GitHub by creating a new repository. Pay attention to not add a README.md, etc. since your project already has all of this. GitHub then gives you the necessary commands to connect the origin to your local project. Look out for the part "…or push an existing repository from the command line" and run those commands.
- create a virtual environment (you can skip this if you're using uv):
virtualenv .venv
# add -p $PATH_TO_PYTHON_EXECUTABLE to specify a python version, for example:
virtualenv .venv -p $PYENV_ROOT/versions/3.12.10/bin/python
source .venv/bin/activate # to activate your virtual environment- install standard dependencies to start working:
# with Poetry run first:
poetry lock
# then for all dependency management tools:
make sync- if you added pre-commit in step 1, do:
pre-commit install
git add .
git commit -m "initial commit"- start your project:
./main.py| name | type | options | default | explanation |
|---|---|---|---|---|
| project name | str | - | the project's name as stated in the pyproject.toml | |
| module name | str | same as project name | the name of the main module in the root directory of the project | |
| project description | str | - | used in the pyproject.toml | |
| dependency management | str | uv / pip / poetry | uv | choose a dependency management tool: uv, Poetry or just pip |
| use poetry dynamic versioning | boolean | true / false | false | use dynamic versioning for Poetry |
| python versions | str | 3.9 to 3.15 | [3.11, 3.12, 3.13, 3.14] | defines the required and supported python versions |
| use precommit | boolean | true / false | false | use pre-commit to check your changes before committing |
| use rosys | boolean | true / false | false | add RoSys framework to dependencies |
| include contributing | boolean | true / false | true | include CONTRIBUTING.md with development guidelines (only asked if AI instructions disabled) |
| include ai instructions | boolean | true / false | true | include AI agent instructions (AGENT.md, .github/copilot-instructions.md, .cursor/*, CONTRIBUTING.md) |
To update your project from the template or change settings run:
copier updateThis will prompt you to review and update your template settings interactively.
You can add --skip-answered if you just want the new version, but keep your previous answers.
If you changed a lot of the original template files and have the feeling that not everything you expected to update was updated, you can also run:
copier recopy ./path_to_your_projectBe careful with this command, as it will overwrite any local changes you made to the template files. It's recommended to run this without uncommitted changes and then thoroughly review the changes generated by copier with git.
When include_contributing is enabled (default when AI instructions are disabled), a CONTRIBUTING.md file is generated with:
- Development setup instructions
- Coding style guidelines
- Workflow and testing guidelines
- Pull request checklist
When include_ai_instructions is enabled (default), the template generates files to help AI coding assistants (GitHub Copilot, Cursor, etc.) understand your project better:
CONTRIBUTING.md- Development guidelines and coding standards (mandatory, serves as the detailed reference)AGENTS.md- Focused AI agent guidelines with principles and AI-specific patterns.github/copilot-instructions.md- Brief GitHub Copilot instructions that reference the main files plus detailed review instructions (because it's the most common and straight forward AI review tool when using GitHub).cursor/rules- Brief Cursor AI quick reference.cursor/commands/*.md- Custom Cursor commands (review-code, check-style, suggest-tests, explain-code, simplify)
Structure Philosophy: Following the NiceGUI approach, CONTRIBUTING.md contains the comprehensive coding standards and workflow, while AGENTS.md focuses on AI-specific principles. Tool-specific files (.cursor/rules, .github/copilot-instructions.md) are kept brief and reference the main files.