Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
51 changes: 51 additions & 0 deletions .github/workflows/docs_pages.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
name: Publish Documentation

on:
push:
branches:
- main
tags:
- "v*"
workflow_dispatch:

permissions:
contents: write

jobs:
deploy-docs:
runs-on: ubuntu-latest

steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
fetch-depth: 0

- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: "3.11"

- name: Install documentation dependencies
run: |
python -m pip install --upgrade pip
python -m pip install -e ".[docs]"

- name: Validate documentation build
run: mkdocs build --strict

- name: Configure git identity for mike
run: |
git config user.name "github-actions[bot]"
git config user.email "github-actions[bot]@users.noreply.github.com"

- name: Deploy dev and latest aliases from main
if: github.ref == 'refs/heads/main'
run: mike deploy --push --branch gh-pages --update-aliases dev latest

- name: Deploy release version from tag and update stable alias
if: startsWith(github.ref, 'refs/tags/v')
run: |
VERSION="${GITHUB_REF_NAME#v}"
mike deploy --push --branch gh-pages --update-aliases "${VERSION}" stable
mike set-default --push --branch gh-pages stable
11 changes: 11 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,17 @@
All notable changes to this project will be documented in this file.


## [2.0.1] - 2026-02-16

### Added
- Documentation and CI for github-pages

### Changed
- Bumped project version to `2.0.1`.
- Updated API version metadata and root welcome message to `v2.0.1`.



## [2.0.0] - 2025-10-07

### Added
Expand Down
42 changes: 42 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,48 @@ python src/main.py --url https://github.com/qchapp/lungs-segmentation --output_p

If no arguments are provided, it will use the default repository and output path.

## Versioned documentation (GitHub Pages)

The repository includes a versioned documentation site under `docs/` powered by MkDocs Material + Mike.

Install docs dependencies:

```bash
uv pip install -e ".[docs]"
```

Local docs preview:

```bash
just docs-serve
```

Strict docs build:

```bash
just docs-build
```

Manual publish commands:

```bash
# Publish dev/latest from current branch
just docs-deploy-dev

# Publish a release version and update stable alias
just docs-deploy-release 2.0.1

# Set default version in selector
just docs-set-default stable
```

Automation:

- `.github/workflows/docs_pages.yml` publishes docs on:
- Pushes to `main` (`dev` + `latest`)
- Pushes of tags matching `v*` (release version + `stable`)
- Configure GitHub Pages to serve from the `gh-pages` branch root.

## How to run the tool using Docker?

1. You need to build the image.
Expand Down
Loading