Skip to content

Commit b8bd19b

Browse files
authored
Merge pull request #129 from OpenSemanticLab/uv-zensical-migration
Migrate repository structure, tooling, CI/CD and docs to the uv zensical stack
2 parents f21b5d5 + 80c9353 commit b8bd19b

101 files changed

Lines changed: 6075 additions & 2115 deletions

File tree

Some content is hidden

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

.coveragerc

Lines changed: 0 additions & 28 deletions
This file was deleted.
Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
name: "Setup Python Environment"
2+
description: "Set up Python and uv, then install the locked dependencies"
3+
4+
inputs:
5+
python-version:
6+
description: "Python version to use"
7+
required: true
8+
default: "3.12"
9+
uv-version:
10+
description: "uv version to use"
11+
required: true
12+
default: "0.9.9"
13+
14+
runs:
15+
using: "composite"
16+
steps:
17+
- uses: actions/setup-python@v5
18+
with:
19+
python-version: ${{ inputs.python-version }}
20+
21+
- name: Install uv
22+
uses: astral-sh/setup-uv@v6
23+
with:
24+
version: ${{ inputs.uv-version }}
25+
enable-cache: true
26+
cache-suffix: ${{ matrix.python-version }}
27+
28+
- name: Install Python dependencies
29+
run: uv sync --frozen
30+
shell: bash

.github/workflows/ci.yml

Lines changed: 0 additions & 120 deletions
This file was deleted.

.github/workflows/docs.yml

Lines changed: 29 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,31 +1,41 @@
1-
# This is a basic workflow to help you get started with Actions
1+
# Deploys the documentation with mike (versioned docs on the gh-pages
2+
# branch; repo setting: Pages source = "Deploy from a branch: gh-pages").
3+
#
4+
# push to main -> version "dev"
5+
# tag vX.Y.Z -> version "X.Y.Z" + "latest" alias (on-release-main.yml)
26

37
name: Docs
48

5-
# Controls when the workflow will run
69
on:
7-
# Triggers the workflow on push or pull request events but only for the master branch
810
push:
9-
branches: [ main ]
10-
11-
# Allows you to run this workflow manually from the Actions tab
11+
branches: [main]
1212
workflow_dispatch:
1313

14-
# A workflow run is made up of one or more jobs that can run sequentially or in parallel
14+
permissions:
15+
# mike commits the built site to the gh-pages branch
16+
contents: write
17+
18+
concurrency:
19+
group: pages
20+
cancel-in-progress: false
21+
1522
jobs:
16-
# This workflow contains a single job called "build"
17-
build:
18-
# The type of runner that the job will run on
23+
deploy-docs:
1924
runs-on: ubuntu-latest
20-
21-
# Steps represent a sequence of tasks that will be executed as part of the job
2225
steps:
23-
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
24-
- uses: actions/checkout@v2
26+
- name: Check out
27+
uses: actions/checkout@v4
2528
with:
29+
# deep clone incl. tags: hatch-vcs needs them and mike needs gh-pages
2630
fetch-depth: 0
27-
- uses: actions/setup-python@v2
28-
- run: pip install --upgrade pip && pip install mkdocs mkdocs-gen-files "mkdocstrings[python]" mkdocs-material
29-
- run: git config user.name 'github-actions[bot]' && git config user.email 'github-actions[bot]@users.noreply.github.com'
30-
- name: Publish docs
31-
run: mkdocs gh-deploy
31+
32+
- name: Set up the environment
33+
uses: ./.github/actions/setup-python-env
34+
35+
- name: Configure git identity
36+
run: |
37+
git config user.name 'github-actions[bot]'
38+
git config user.email 'github-actions[bot]@users.noreply.github.com'
39+
40+
- name: Deploy dev documentation
41+
run: uv run mike deploy --push dev

.github/workflows/integration.yml

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
# Integration tests against a live test wiki. Credentials come from the
2+
# INTEGR_TEST_* secrets; where they are unavailable (e.g. forks), the
3+
# credential fixtures make the tests skip instead of fail.
4+
#
5+
# Runs on every pull request into main, so breaking changes surface before the
6+
# release job (gated separately by required review on the pypi environment)
7+
# ever starts. No push trigger: a push to main is already covered by the PR
8+
# that preceded it, so a second run would add nothing.
9+
10+
name: Integration
11+
12+
on:
13+
pull_request:
14+
branches: [main]
15+
workflow_dispatch:
16+
17+
concurrency:
18+
# runs mutate the shared test wiki, so never run two in parallel
19+
group: integration
20+
cancel-in-progress: false
21+
22+
jobs:
23+
integration-tests:
24+
runs-on: ubuntu-latest
25+
steps:
26+
- name: Check out
27+
uses: actions/checkout@v4
28+
with:
29+
# deep clone incl. tags so hatch-vcs can derive the version
30+
fetch-depth: 0
31+
32+
- name: Set up the environment
33+
uses: ./.github/actions/setup-python-env
34+
35+
- name: Run integration tests
36+
env:
37+
WIKI_DOMAIN: ${{ secrets.INTEGR_TEST_WIKI_DOMAIN }}
38+
WIKI_USERNAME: ${{ secrets.INTEGR_TEST_WIKI_USERNAME }}
39+
WIKI_PASSWORD: ${{ secrets.INTEGR_TEST_WIKI_PASSWORD }}
40+
run: make test-integration

0 commit comments

Comments
 (0)