Skip to content

joaopalmeiro/cookiecutter-templates

Repository files navigation

cookiecutter-templates

Templates

  • Awesome list: cookiecutter https://github.com/joaopalmeiro/cookiecutter-templates.git --directory="awesome"
  • Python CLI: cookiecutter https://github.com/joaopalmeiro/cookiecutter-templates.git --directory="python-cli"
  • Python package: cookiecutter https://github.com/joaopalmeiro/cookiecutter-templates.git --directory="python-pkg"

References

Notes

  • cookiecutter . --directory="python-pkg".
  • "project_slug": "{{ cookiecutter.project_name.lower().replace(' ', '-') }}", "module_name": "{{ cookiecutter.project_name.lower().replace(' ', '_').replace('-', '_') }}".
  • Installing the classic Jupyter Notebook interface: pip install jupyter.
  • Jupytext.
  • jupyter notebook --version.
  • pipx (JavaScript's npx for Python).
  • James Q Quick's Fancy Blinking Cursor In VS Code tutorial.
  • "project_cli_name": "{{ cookiecutter.project_name.lower().replace(' ', '-') }}".
  • Alternative: Copier.
  • .npmrc file: package-lock=false.

Python naming conventions (source):

python_package_distribution_name:
  type: str
  help: Your Python package distribution name (for `pip install NAME`)
  default: "[[ project_name|lower|replace('_', '-')|replace(' ', '-') ]]"

python_package_import_name:
  type: str
  help: Your Python package import name (for `import NAME` in Python code)
  default: "[[ project_name|lower|replace('-', '_')|replace(' ', '_') ]]"

python_package_command_line_name:
  type: str
  help: Your CLI name if any (for use in the shell)
  default: "[[ project_name|lower|replace('_', '-')|replace(' ', '-') ]]"