Skip to content

Commit 66bf1db

Browse files
author
Alessio Perilli
committed
Add basic CI workflow: lint + dependency check
1 parent fbdc4e3 commit 66bf1db

1 file changed

Lines changed: 49 additions & 0 deletions

File tree

.github/workflows/ci.yml

Lines changed: 49 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,49 @@
1+
name: CI
2+
3+
on:
4+
push:
5+
branches: [ main ]
6+
pull_request:
7+
branches: [ main ]
8+
9+
jobs:
10+
check:
11+
runs-on: ubuntu-latest
12+
13+
steps:
14+
- uses: actions/checkout@v4
15+
16+
- name: Set up Python 3.11
17+
uses: actions/setup-python@v5
18+
with:
19+
python-version: "3.11"
20+
21+
- name: Install dependencies
22+
run: |
23+
python -m pip install --upgrade pip
24+
if [ -f requirements.txt ]; then
25+
pip install -r requirements.txt
26+
fi
27+
28+
- name: Lint with pyflakes
29+
run: |
30+
pip install pyflakes
31+
pyflakes src/*.py
32+
33+
- name: Check Python syntax
34+
run: |
35+
python -m py_compile src/*.py
36+
37+
- name: Verify project structure
38+
run: |
39+
echo "Checking project structure..."
40+
for dir in "1 easy" "2 medium" "3 hard" "songs" "src"; do
41+
if [ -d "$dir" ]; then
42+
echo "OK $dir/"
43+
else
44+
echo "WARN $dir/ not found (non-critical)"
45+
fi
46+
done
47+
echo "README: $([ -f README.md ] && echo OK || echo MISSING)"
48+
echo "LICENSE: $([ -f LICENSE ] && echo OK || echo MISSING)"
49+
echo "requirements.txt: $([ -f requirements.txt ] && echo OK || echo MISSING)"

0 commit comments

Comments
 (0)