Skip to content

Commit

Permalink
Add a small section describing pyproject.toml (#231)
Browse files Browse the repository at this point in the history
  • Loading branch information
yakutovicha committed May 4, 2024
1 parent b686300 commit bb38e3c
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions modules_and_packages.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -731,6 +731,14 @@
"\n",
"To make the package installable, we need to do a few more things.\n",
"Typically, this is done by creating the `pyproject.toml` file.\n",
"`pyproject.toml` is a configuration file that contains the build system requirements and the package metadata.\n",
"It is used by the build tools like `flit` or `poetry` to build and install the package.\n",
"It is also used by other tools like `black` and `mypy` to configure their behaviour.\n",
"\n",
"The [`toml` format](https://toml.io/) is a configuration file format that is easy to read and write for humans (unlike `json`).\n",
"It is quite flexible but not as complex as the `yaml` format.\n",
"Another advangtage of the `toml` format is that it is pre-installed in Python, so you don't need to install any additional packages to use it.\n",
"\n",
"\n",
"Here is a minimal example of the `pyproject.toml`: \n",
"\n",
Expand Down Expand Up @@ -814,7 +822,6 @@
]
},
{
"attachments": {},
"cell_type": "markdown",
"metadata": {},
"source": [
Expand All @@ -839,7 +846,6 @@
]
},
{
"attachments": {},
"cell_type": "markdown",
"metadata": {
"tags": []
Expand Down

0 comments on commit bb38e3c

Please sign in to comment.