Skip to content

Commit ba35f5e

Browse files
authored
docs: šŸ“ Introduce mkdocs-material to sahi project to have documentation page (#1213)
Co-authored-by: fatih akyon <34196005+fcakyon@users.noreply.github.com>
2 parents 3a418f2 + 8e0fdb9 commit ba35f5e

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

56 files changed

+1307
-218
lines changed

ā€Ž.github/dependabot.ymlā€Ž

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
version: 2
2+
updates:
3+
# GitHub Actions
4+
- package-ecosystem: "github-actions"
5+
directory: "/"
6+
schedule:
7+
interval: "weekly"
8+
commit-message:
9+
prefix: šŸ‘·
10+
target-branch: "main"
11+

ā€Ž.github/workflows/ci.ymlā€Ž

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ jobs:
6060
- name: Install dependencies
6161
run: |
6262
set -e
63-
uv sync --extra dev --extra ci
63+
uv sync --group dev --extra ci
6464
- name: List installed packages
6565
run: |
6666
echo "=== Installed Python packages ==="

ā€Ž.github/workflows/mmdet.ymlā€Ž

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,7 @@ jobs:
9393
# Activate virtual environment
9494
source .venv/bin/activate
9595
# Install dev and mmdet dependencies
96-
uv sync --extra dev --extra mmdet
96+
uv sync --group dev --extra mmdet
9797
# Install specific torch version for MMDet compatibility AFTER uv sync
9898
uv pip install torch==2.1.2+cpu torchvision==0.16.2+cpu --index-url https://download.pytorch.org/whl/cpu
9999
- name: Verify .venv Activation
Lines changed: 54 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,54 @@
1+
name: šŸ› ļø Build and šŸ“š Publish Docs
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
workflow_dispatch:
8+
release:
9+
types: [published]
10+
11+
# Ensure only one concurrent deployment
12+
concurrency:
13+
group: ${{ github.workflow }}-${{ github.event_name == 'push' && github.ref}}
14+
cancel-in-progress: true
15+
16+
# Restrict permissions by default
17+
permissions:
18+
contents: write # Required for committing to gh-pages
19+
pages: write # Required for deploying to Pages
20+
pull-requests: write # Required for PR comments
21+
22+
jobs:
23+
deploy:
24+
name: šŸ“š Publish Docs
25+
runs-on: ubuntu-latest
26+
timeout-minutes: 10
27+
strategy:
28+
matrix:
29+
python-version: ["3.10"]
30+
steps:
31+
- name: šŸ“„ Checkout the repository
32+
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
33+
with:
34+
fetch-depth: 0
35+
36+
- name: šŸ Install uv and set Python ${{ matrix.python-version }}
37+
uses: astral-sh/setup-uv@e92bafb6253dcd438e0484186d7669ea7a8ca1cc # v6.4.3
38+
with:
39+
python-version: ${{ matrix.python-version }}
40+
activate-environment: true
41+
42+
- name: šŸ—ļø Install dependencies
43+
run: |
44+
uv pip install -r pyproject.toml --group docs
45+
46+
- name: āš™ļø Configure git for github-actions
47+
run: |
48+
git config --global user.name "github-actions[bot]"
49+
git config --global user.email "41898282+github-actions[bot]@users.noreply.github.com"
50+
51+
- name: šŸ“š Build and Publish Docs
52+
if: (github.event_name == 'push' && github.ref == 'refs/heads/main') || github.event_name == 'workflow_dispatch'
53+
run: |
54+
uv run mkdocs gh-deploy --force

ā€Ž.github/workflows/ruff.yamlā€Ž

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ jobs:
3030
- name: Install dependencies
3131
run: |
3232
uv venv --python 3.10
33-
uv sync --extra dev
33+
uv sync --group dev
3434
- name: Check code formatting
3535
id: ruff_check
3636
run: |
@@ -59,4 +59,4 @@ jobs:
5959
echo " git push"
6060
echo ""
6161
echo "For more details, see CONTRIBUTING.md"
62-
exit 1
62+
exit 1

0 commit comments

Comments
Ā (0)