Skip to content

Commit

Permalink
Add notes on how to create a release for Umberto
Browse files Browse the repository at this point in the history
  • Loading branch information
JDBetteridge committed Nov 8, 2024
1 parent 652d57b commit febeac3
Showing 1 changed file with 54 additions and 0 deletions.
54 changes: 54 additions & 0 deletions docs/release.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
# Poetry notes for Umberto

## Poetry
Remember that poetry cannot be installed in the same environment as the project.
Create a virtual environment somewhere permanent and you can use a bash alias to drive poetry:

```bash
python -m venv ~/.poetry
source ~/.poetry/bin/activate
pip install poetry

# check location of executable with
which poetry

# create alias (could be added to ~/.bash_profile)
alias poetry="$HOME/.poetry/bin/poetry"
```

When carrying out any of the below tasks create a new empty virtual environment!
```bash
python -m venv temp
source temp/bin/activate
```

## Add a dependency
[Docs](https://python-poetry.org/docs/cli/#add)
```bash
poetry add numpy@^2
```

## Build ngsPETSc
[Docs](https://python-poetry.org/docs/cli/#build)
```bash
poetry build
```

## Create a release
Follow these steps to create a release:
```bash
# For a bug fix:
poetry version patch
# OR for a minor version bump:
poetry version minor
# OR for a major release:
poetry version minor

git add pyproject.toml
git commit -m "Release $(poetry version)"

git tag -a -m "Release $(poetry version)" $(poetry version)

git push
git push origin $(poetry version)
```

0 comments on commit febeac3

Please sign in to comment.