docs: add installation and publishing instructions for Gitea package registry
This commit is contained in:
@@ -37,6 +37,38 @@ From outside the checkout, point `PYTHONPATH` at it:
|
|||||||
PYTHONPATH=/path/to/mailinabox python3 -m mailinabox.cli.miab --help
|
PYTHONPATH=/path/to/mailinabox python3 -m mailinabox.cli.miab --help
|
||||||
```
|
```
|
||||||
|
|
||||||
|
### Install from the Gitea package registry
|
||||||
|
|
||||||
|
```sh
|
||||||
|
pip install --index-url https://<username>:<token>@<gitea-host>/api/packages/<owner>/pypi/simple mailinabox
|
||||||
|
```
|
||||||
|
|
||||||
|
> **Note** `python-helpers` is resolved from the same registry. If it is published elsewhere,
|
||||||
|
> install it first and add `--no-deps` here.
|
||||||
|
|
||||||
|
## Publishing
|
||||||
|
|
||||||
|
Add the registry to `~/.pypirc`:
|
||||||
|
|
||||||
|
```
|
||||||
|
[distutils]
|
||||||
|
index-servers = gitea
|
||||||
|
|
||||||
|
[gitea]
|
||||||
|
repository = https://<gitea-host>/api/packages/<owner>/pypi
|
||||||
|
username = <username>
|
||||||
|
password = <token>
|
||||||
|
```
|
||||||
|
|
||||||
|
```sh
|
||||||
|
pip install build twine
|
||||||
|
python3 -m build
|
||||||
|
python3 -m twine upload --repository gitea dist/*
|
||||||
|
```
|
||||||
|
|
||||||
|
> **Note** a name and version already in the registry cannot be republished. Raise `version`
|
||||||
|
> in `pyproject.toml` before each upload.
|
||||||
|
|
||||||
## Library
|
## Library
|
||||||
|
|
||||||
```python
|
```python
|
||||||
|
|||||||
Reference in New Issue
Block a user