Metadata-Version: 2.1
Name: hexdoc
Version: 0.9.5.1.0.dev15
Summary: Python web book docgen for Patchouli and Hex Casting.
Project-URL: Homepage, https://object-object.github.io/HexMod/
Project-URL: Source, https://github.com/object-Object/HexMod/tree/docgen-2-1.20/doc
Author: object-Object, Alwinfy
License: MIT License
        
        Copyright (c) 2023 object-Object, gamma-delta
        
        Permission is hereby granted, free of charge, to any person obtaining a copy
        of this software and associated documentation files (the "Software"), to deal
        in the Software without restriction, including without limitation the rights
        to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
        copies of the Software, and to permit persons to whom the Software is
        furnished to do so, subject to the following conditions:
        
        The above copyright notice and this permission notice shall be included in all
        copies or substantial portions of the Software.
        
        THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
        IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
        FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
        AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
        LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
        OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
        SOFTWARE.
License-File: LICENSE.txt
Keywords: hexdoc
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: MIT License
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Java
Classifier: Programming Language :: JavaScript
Classifier: Programming Language :: Kotlin
Classifier: Programming Language :: Python :: 3.11
Classifier: Topic :: Documentation
Classifier: Topic :: File Formats :: JSON
Classifier: Topic :: Games/Entertainment
Classifier: Topic :: Internet :: WWW/HTTP :: Dynamic Content
Classifier: Topic :: Software Development :: Libraries :: Python Modules
Classifier: Topic :: Software Development :: Localization
Classifier: Topic :: Text Processing :: Markup :: HTML
Classifier: Typing :: Typed
Requires-Python: >=3.11
Requires-Dist: importlib-resources<7,>=6.0.1
Requires-Dist: jinja2<4,>=3.1.2
Requires-Dist: more-itertools<11,>=10.1.0
Requires-Dist: pluggy<2,>=1.3.0
Requires-Dist: pydantic!=2.4.0,<3,>=2.3.0
Requires-Dist: pydantic-settings<3,>=2.0.3
Requires-Dist: pyjson5<2,>=1.6.3
Requires-Dist: typer[all]<1,>=0.9.0
Requires-Dist: typing-extensions<5,>=4.6.1
Provides-Extra: dev
Requires-Dist: black==23.7.0; extra == 'dev'
Requires-Dist: build; extra == 'dev'
Requires-Dist: hatch; extra == 'dev'
Requires-Dist: isort==5.12.0; extra == 'dev'
Requires-Dist: pytest>=7.3.1; extra == 'dev'
Requires-Dist: syrupy>=4.0.2; extra == 'dev'
Description-Content-Type: text/markdown

# hexdoc

This is the Python docgen for Hex Casting.

## Version scheme

We use [hatch-gradle-version](https://pypi.org/project/hatch-gradle-version) to generate the version number based on whichever mod version the docgen was built with.

The version is in this format: `mod-version.python-version.mod-pre.python-dev.python-post`

For example:
* Mod version: `0.11.1-7`
* 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.
- Fill in the TODOs in `doc/properties.toml` (mostly paths to files/folders in your mod so hexdoc can find the data it needs).
- Try running the docgen locally by following the instructions in `doc/README.md`.
- If it doesn't already exist, create an empty `gh-pages` branch and push it.
- On GitHub, under `Settings > Pages`, set the source to `Deploy from a branch`, the branch to `gh-pages`, and the folder to `docs/`.
- Commit and push the docgen, and see if the CI works.
- 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.
  - If you like to live dangerously, this step is optional - you can remove the `publish-testpypi` job and the `TestPyPI` release choice from your workflow without impacting the rest of the CI.

## Setup

```sh
python -m venv venv

.\venv\Scripts\activate  # Windows
source venv/bin/activate # anything other than Windows

# run from the repo root, not doc/
pip install -e .[dev]
```

## Usage

For local testing, create a file called `.env` following this template:
```sh
GITHUB_REPOSITORY=gamma-delta/HexMod
GITHUB_SHA=main
GITHUB_PAGES_URL=https://gamma-delta.github.io/HexMod
```

Then run these commands to generate the book:
```sh
# run from the repo root, not doc/
hexdoc render doc/properties.toml _site/src/docs
hexdoc merge --src _site/src/docs --dst _site/dst/docs
```

Or, run this command to render the book and start a local web server:
```sh
hexdoc serve doc/properties.toml --src _site/src/docs --dst _site/dst/docs
```
