Skip to main content

Example of a Python Library

Project description

nicks-pylib

Example of a Python library

Start poetry shell

$ poetry shell

Install Dependencies

$ poetry install

Run Tests With Poetry

$ poetry run pytest

Build the Package

$ poetry build

Useful Poetry Commands

  • poetry show —Lists the packages installed in your current project’s virtual environment. You can use poetry show --tree to view dependencies in a tree format to help understand the hierarchical structure of package dependencies.
  • poetry add — Add new dependencies to your project. It automatically updates your pyproject.toml and poetry.lock files.
  • poetry install — Reads the pyproject.toml file from the current project, resolves the dependencies, and installs them. If a poetry.lock file exists, it will use the exact versions from there instead of resolving them.
  • poetry env — Shows information about the current environment or even removes virtual environments associated with the project. poetry shell— Spawns a shell, like bash or zsh, within the virtual environment created by Poetry.
  • poetry remove— Removes a package that is no longer necessary from the pyproject.toml and lock file. poetry version minor— Bumps the minor version of your project (according to semantic versioning). Similar for MAJOR or PATCH .
  • poetry publish — Publishes a project to PyPI or another configured repository.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

nickspylib-0.1.1.tar.gz (1.7 kB view hashes)

Uploaded Source

Built Distribution

nickspylib-0.1.1-py3-none-any.whl (2.1 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page