Skip to content

Commit 8fbde73

Browse files
dreamiurgclaude
andauthored
ci: add badges and GitHub Actions CI workflow (#20)
* chore: add py.typed marker for PEP 561 compliance Signal that package supports type hints for downstream consumers. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com> * ci: add GitHub Actions workflow with cross-platform testing Configure matrix testing: Python 3.12/3.13/3.14 on Linux, smoke tests on macOS/Windows. Include ruff, mypy, pytest with coverage upload to Codecov. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com> * docs: add badges to README Add CI status, OpenSSF scorecard, coverage, license, and type safety badges to demonstrate project credibility. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com> --------- Co-authored-by: Claude <noreply@anthropic.com>
1 parent cc9053c commit 8fbde73

File tree

4 files changed

+69
-0
lines changed

4 files changed

+69
-0
lines changed

.github/workflows/ci.yml

Lines changed: 59 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,59 @@
1+
name: CI
2+
3+
on:
4+
push:
5+
branches: [main]
6+
pull_request:
7+
branches: [main]
8+
9+
jobs:
10+
test:
11+
name: Test on ${{ matrix.os }} - Python ${{ matrix.python-version }}
12+
runs-on: ${{ matrix.os }}
13+
14+
strategy:
15+
fail-fast: false
16+
matrix:
17+
os: [ubuntu-latest]
18+
python-version: ["3.12", "3.13", "3.14"]
19+
include:
20+
# Smoke tests on macOS and Windows with latest Python
21+
- os: macos-latest
22+
python-version: "3.14"
23+
- os: windows-latest
24+
python-version: "3.14"
25+
26+
steps:
27+
- uses: actions/checkout@v4
28+
29+
- name: Set up Python ${{ matrix.python-version }}
30+
uses: actions/setup-python@v5
31+
with:
32+
python-version: ${{ matrix.python-version }}
33+
34+
- name: Install uv
35+
uses: astral-sh/setup-uv@v5
36+
37+
- name: Install dependencies
38+
run: uv sync --extra dev
39+
40+
- name: Run ruff check
41+
run: uv run ruff check peakbagger tests
42+
43+
- name: Run ruff format check
44+
run: uv run ruff format --check peakbagger tests
45+
46+
- name: Run mypy
47+
run: uv run mypy peakbagger --pretty
48+
continue-on-error: true
49+
50+
- name: Run tests with coverage
51+
run: uv run pytest --cov=peakbagger --cov-report=xml --cov-report=term
52+
53+
- name: Upload coverage to Codecov
54+
if: matrix.os == 'ubuntu-latest' && matrix.python-version == '3.14'
55+
uses: codecov/codecov-action@v4
56+
with:
57+
token: ${{ secrets.CODECOV_TOKEN }}
58+
file: ./coverage.xml
59+
fail_ci_if_error: false

README.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,11 @@
11
# peakbagger-cli
22

3+
[![CI](https://github.com/dreamiurg/peakbagger-cli/actions/workflows/ci.yml/badge.svg)](https://github.com/dreamiurg/peakbagger-cli/actions/workflows/ci.yml)
4+
[![OpenSSF Scorecard](https://api.securityscorecards.dev/projects/github.com/dreamiurg/peakbagger-cli/badge)](https://securityscorecards.dev/viewer/?uri=github.com/dreamiurg/peakbagger-cli)
5+
[![codecov](https://codecov.io/gh/dreamiurg/peakbagger-cli/branch/main/graph/badge.svg)](https://codecov.io/gh/dreamiurg/peakbagger-cli)
6+
[![License: MIT](https://img.shields.io/badge/license-MIT-blue.svg)](https://github.com/dreamiurg/peakbagger-cli/blob/main/LICENSE)
7+
[![Types: Typed](https://img.shields.io/badge/types-typed-brightgreen.svg)](https://github.com/dreamiurg/peakbagger-cli/blob/main/peakbagger)
8+
39
A modern command-line interface for searching and retrieving mountain peak data from [PeakBagger.com](https://www.peakbagger.com).
410

511
Python 3.12+, Click, and Rich deliver a beautiful terminal experience.

peakbagger/py.typed

Whitespace-only changes.

pyproject.toml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,8 +34,12 @@ dependencies = [
3434
dev = [
3535
"pytest>=7.0.0",
3636
"pytest-cov>=4.0.0",
37+
"pytest-vcr>=1.0.2",
3738
"ruff>=0.8.0",
3839
"pre-commit>=3.0.0",
40+
"mypy>=1.18.2",
41+
"types-beautifulsoup4>=4.12.0.20250516",
42+
"vcrpy>=7.0.0",
3943
]
4044

4145
[project.scripts]

0 commit comments

Comments
 (0)