File tree Expand file tree Collapse file tree 6 files changed +162
-0
lines changed
scripts/scaffold/.github/workflows Expand file tree Collapse file tree 6 files changed +162
-0
lines changed Original file line number Diff line number Diff line change 1+ name : Pre-commit checks
2+
3+ on :
4+ push :
5+ branches : [main]
6+ pull_request :
7+ branches : [main]
8+
9+ jobs :
10+ pre-commit :
11+ runs-on : ubuntu-latest
12+ steps :
13+ - uses : actions/checkout@v4
14+ with :
15+ fetch-depth : 0
16+
17+ - name : Install UV and Python
18+ uses : astral-sh/setup-uv@v5
19+ with :
20+ version : " latest"
21+ python-version : " 3.11"
22+ - name : Symlink uv to expected path for pre-commit-uv
23+ run : |
24+ mkdir -p ~/.local/bin
25+ ln -s $(which uv) ~/.local/bin/uv
26+ - run : uv venv
27+ - run : uv sync --dev
28+ - run : uv add pytest==7.4.3
29+ - uses : tox-dev/action-pre-commit-uv@v1
30+ with :
31+ extra_args : --all-files
Original file line number Diff line number Diff line change 1+ # name: Publish (PyPI)
2+ #
3+ # on:
4+ # release:
5+ # types: [published]
6+ # workflow_dispatch:
7+ #
8+ # jobs:
9+ # build-publish:
10+ # runs-on: ubuntu-latest
11+ # permissions:
12+ # id-token: write
13+ # contents: read
14+ # steps:
15+ # - uses: actions/checkout@v4
16+ # - uses: astral-sh/setup-uv@v5
17+ # with:
18+ # version: "latest"
19+ # python-version: "3.11"
20+ # - run: uv venv
21+ # - run: uv pip install -e .[dev]
22+ # - run: uv run pytest -q
23+ # - run: uv build
24+ # - name: Verify package
25+ # run: uv run --with twine twine check dist/*
26+ # - name: Publish to PyPI
27+ # uses: pypa/gh-action-pypi-publish@release/v1
28+ # with:
29+ # print-hash: true
Original file line number Diff line number Diff line change 1+ name : Tests
2+
3+ on :
4+ push :
5+ branches : [main]
6+ pull_request :
7+
8+ jobs :
9+ test :
10+ runs-on : ubuntu-latest
11+ strategy :
12+ matrix :
13+ python-version : ["3.10", "3.12"]
14+
15+ steps :
16+ - uses : actions/checkout@v4
17+
18+ - name : Install UV and Python
19+ uses : astral-sh/setup-uv@v5
20+ with :
21+ version : " latest"
22+ python-version : ${{ matrix.python-version }}
23+
24+ - name : Create virtual environment
25+ run : uv venv
26+
27+ - name : Install dependencies
28+ run : |
29+ uv sync --all-groups
30+ uv add pytest==7.4.3
31+
32+ - name : Run tests
33+ run : uv run pytest -v
Original file line number Diff line number Diff line change 1+ name : Pre-commit
2+
3+ on :
4+ push :
5+ branches : [main]
6+ pull_request :
7+ branches : [main]
8+
9+ jobs :
10+ pre-commit :
11+ runs-on : ubuntu-latest
12+ steps :
13+ - uses : actions/checkout@v4
14+ - uses : astral-sh/setup-uv@v5
15+ with :
16+ version : " latest"
17+ python-version : " 3.11"
18+ - run : uv venv
19+ - run : uv pip install -e .[dev]
20+ - run : uv run pre-commit run --all-files
Original file line number Diff line number Diff line change 1+ name : Publish (PyPI)
2+
3+ on :
4+ release :
5+ types : [published]
6+ workflow_dispatch :
7+
8+ jobs :
9+ build-publish :
10+ runs-on : ubuntu-latest
11+ permissions :
12+ id-token : write
13+ contents : read
14+ steps :
15+ - uses : actions/checkout@v4
16+ - uses : astral-sh/setup-uv@v5
17+ with :
18+ version : " latest"
19+ python-version : " 3.11"
20+ - run : uv venv
21+ - run : uv pip install -e .[dev]
22+ - run : uv run pytest -q
23+ - run : uv build
24+ - name : Verify package
25+ run : uv run --with twine twine check dist/*
26+ - name : Publish to PyPI
27+ uses : pypa/gh-action-pypi-publish@release/v1
28+ with :
29+ print-hash : true
Original file line number Diff line number Diff line change 1+ name : Tests
2+
3+ on :
4+ push :
5+ branches : [main]
6+ pull_request :
7+
8+ jobs :
9+ test :
10+ runs-on : ubuntu-latest
11+ steps :
12+ - uses : actions/checkout@v4
13+ - uses : astral-sh/setup-uv@v5
14+ with :
15+ version : " latest"
16+ python-version : " 3.11"
17+ - run : uv venv
18+ - run : uv pip install -e .[dev]
19+ - run : uv pip install MCPStack
20+ - run : uv run pytest -q
You can’t perform that action at this time.
0 commit comments