Skip to content

Commit cc918df

Browse files
Upload built whl in CI (#43)
* upload whl * fix yaml * always build whl * use hatch * set build backend * set python path * use packages * no need for PYTHONPATH * upload whl artifact
1 parent 30e6f5c commit cc918df

File tree

2 files changed

+21
-7
lines changed

2 files changed

+21
-7
lines changed

.github/workflows/tests.yml

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,3 +21,17 @@ jobs:
2121
run: uv venv
2222
- name: Run tests
2323
run: make test
24+
# build and store whl as artifact
25+
- name: Build and store whl
26+
if: matrix.os == 'ubuntu-latest'
27+
run: |
28+
make build
29+
mkdir -p ${{ github.workspace }}/artifacts
30+
cp dist/*.whl ${{ github.workspace }}/artifacts/
31+
- name: Upload whl artifact for this build
32+
if: matrix.os == 'ubuntu-latest'
33+
uses: actions/upload-artifact@v4
34+
with:
35+
name: mcp-scan-latest.whl
36+
path: ${{ github.workspace }}/artifacts/*.whl
37+

pyproject.toml

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[project]
22
name = "mcp-scan"
3-
version = "0.2.0.2"
3+
version = "0.2.0.3"
44
description = "MCP Scan tool"
55
readme = "README.md"
66
requires-python = ">=3.10"
@@ -29,13 +29,13 @@ dependencies = [
2929

3030
[project.scripts]
3131
mcp-scan = "mcp_scan.run:run"
32+
3233
[build-system]
33-
requires = ["setuptools>=61.0", "wheel"]
34-
build-backend = "setuptools.build_meta"
34+
requires = ["hatchling"]
35+
build-backend = "hatchling.build"
3536

36-
[tool.setuptools]
37-
package-dir = {"" = "src"}
38-
packages = ["mcp_scan","mcp_scan_server","mcp_scan_server.routes"]
37+
[tool.hatch.build.targets.wheel]
38+
packages = ["src/mcp_scan","src/mcp_scan_server"]
3939

4040
[project.optional-dependencies]
4141
test = [
@@ -101,4 +101,4 @@ section-order = ["future", "standard-library", "third-party", "first-party", "lo
101101
quote-style = "double"
102102
indent-style = "space"
103103
skip-magic-trailing-comma = false
104-
line-ending = "auto"
104+
line-ending = "auto"

0 commit comments

Comments
 (0)