Slightly better docs

This commit is contained in:
object-Object 2023-09-08 01:29:00 -04:00
parent 5362d11bef
commit 61763592ee
3 changed files with 23 additions and 17 deletions

View file

@ -13,6 +13,20 @@ For example:
* Python package version: `1.0.dev0`
* Full version: `0.11.1.1.0rc7.dev0`
## Creating a plugin / addon
WIP.
- Run these commands, then follow the prompts:
```sh
pip install cookiecutter
cookiecutter gh:object-Object/HexMod --directory doc
```
- Note: if you run this from within an existing mod repo, add the flag `-f` and leave `output_directory` blank
- On GitHub, under Settings > Environments, create two new environments called `pypi` and `testpypi`
- Follow these instructions for PyPI and TestPyPI: https://docs.pypi.org/trusted-publishers/creating-a-project-through-oidc/
- TestPyPI is a duplicate of PyPI which can be used for testing package publishing without affecting the real index. The CI workflow includes a manual execution option to publish to TestPyPI.
## Setup
```sh
@ -25,13 +39,6 @@ source venv/bin/activate # anything other than Windows
pip install -e .[dev]
```
### CI/CD
WIP.
- Under Settings > Environments, create a new environment called `pypi` (and optionally `testpypi`)
- Follow these instructions: https://docs.pypi.org/trusted-publishers/creating-a-project-through-oidc/
## Usage
```sh

View file

@ -32,6 +32,7 @@ on:
env:
PYPI_PACKAGE: {% endraw %}{{ cookiecutter.__project_name }}{% raw %}
USE_TESTPYPI_INDEX: true
permissions:
contents: read
@ -113,7 +114,12 @@ jobs:
path: _checkout
- name: Install docgen from source
run: pip install . hatch
run: |
if [[ $USE_TESTPYPI_INDEX ]]; then
pip install . hatch --extra-index-url https://test.pypi.org/simple/
else
pip install . hatch
fi
- name: List book languages
id: list-langs

View file

@ -1,6 +1,6 @@
# {{ cookiecutter.modid }}
# {{ cookiecutter.__project_name }}
This is the Python docgen for {{ cookiecutter.modid }}.
This is the Python docgen for {{ cookiecutter.mod_name }}.
## Version scheme
@ -25,13 +25,6 @@ source venv/bin/activate # anything other than Windows
pip install -e .[dev]
```
### CI/CD
WIP.
- Under Settings > Environments, create a new environment called `pypi` (and optionally `testpypi`)
- Follow these instructions: https://docs.pypi.org/trusted-publishers/creating-a-project-through-oidc/
## Usage
```sh