Skip to content

Commit 24f7886

Browse files
committed
update badges
1 parent 2f67cbc commit 24f7886

File tree

5 files changed

+70
-12797
lines changed

5 files changed

+70
-12797
lines changed

.github/workflows/basic-tests-uv.yml renamed to .github/workflows/basic-tests-linux-uv.yml

+2-40
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: Code tests (uv)
1+
name: Code tests Linux
22

33
on:
44
push:
@@ -24,7 +24,7 @@ concurrency:
2424
cancel-in-progress: true
2525

2626
jobs:
27-
uv-tests-linux:
27+
uv-tests:
2828
name: Code tests (Linux)
2929
runs-on: ubuntu-latest
3030
steps:
@@ -61,41 +61,3 @@ jobs:
6161
pytest --ruff --nbval ch02/01_main-chapter-code/dataloader.ipynb
6262
pytest --ruff --nbval ch03/01_main-chapter-code/multihead-attention.ipynb
6363
pytest --ruff --nbval ch02/04_bonus_dataloader-intuition/dataloader-intuition.ipynb
64-
65-
uv-tests-macos:
66-
name: Code tests (macOS)
67-
runs-on: macos-latest
68-
steps:
69-
- uses: actions/checkout@v4
70-
71-
- name: Set up Python (uv)
72-
uses: actions/setup-python@v5
73-
with:
74-
python-version: "3.10"
75-
76-
- name: Install uv and dependencies
77-
shell: bash
78-
run: |
79-
curl -LsSf https://astral.sh/uv/install.sh | sh
80-
uv python install 3.10
81-
uv add . --dev
82-
uv pip install -r ch05/07_gpt_to_llama/tests/test-requirements-extra.txt
83-
uv add pytest-ruff nbval
84-
85-
- name: Test Selected Python Scripts (uv)
86-
shell: bash
87-
run: |
88-
source .venv/bin/activate
89-
pytest --ruff setup/02_installing-python-libraries/tests.py
90-
pytest --ruff ch04/01_main-chapter-code/tests.py
91-
pytest --ruff ch05/01_main-chapter-code/tests.py
92-
pytest --ruff ch05/07_gpt_to_llama/tests/tests.py
93-
pytest --ruff ch06/01_main-chapter-code/tests.py
94-
95-
- name: Validate Selected Jupyter Notebooks (uv)
96-
shell: bash
97-
run: |
98-
source .venv/bin/activate
99-
pytest --ruff --nbval ch02/01_main-chapter-code/dataloader.ipynb
100-
pytest --ruff --nbval ch03/01_main-chapter-code/multihead-attention.ipynb
101-
pytest --ruff --nbval ch02/04_bonus_dataloader-intuition/dataloader-intuition.ipynb
+63
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,63 @@
1+
name: Code tests macOS
2+
3+
on:
4+
push:
5+
branches: [ main ]
6+
paths:
7+
- '**/*.py'
8+
- '**/*.ipynb'
9+
- '**/*.yaml'
10+
- '**/*.yml'
11+
- '**/*.sh'
12+
pull_request:
13+
branches: [ main ]
14+
paths:
15+
- '**/*.py'
16+
- '**/*.ipynb'
17+
- '**/*.yaml'
18+
- '**/*.yml'
19+
- '**/*.sh'
20+
workflow_dispatch:
21+
22+
concurrency:
23+
group: ${{ github.workflow }}-${{ github.ref }}
24+
cancel-in-progress: true
25+
26+
jobs:
27+
uv-tests:
28+
name: Code tests (macOS)
29+
runs-on: macos-latest
30+
steps:
31+
- uses: actions/checkout@v4
32+
33+
- name: Set up Python (uv)
34+
uses: actions/setup-python@v5
35+
with:
36+
python-version: "3.10"
37+
38+
- name: Install uv and dependencies
39+
shell: bash
40+
run: |
41+
curl -LsSf https://astral.sh/uv/install.sh | sh
42+
uv python install 3.10
43+
uv add . --dev
44+
uv pip install -r ch05/07_gpt_to_llama/tests/test-requirements-extra.txt
45+
uv add pytest-ruff nbval
46+
47+
- name: Test Selected Python Scripts (uv)
48+
shell: bash
49+
run: |
50+
source .venv/bin/activate
51+
pytest --ruff setup/02_installing-python-libraries/tests.py
52+
pytest --ruff ch04/01_main-chapter-code/tests.py
53+
pytest --ruff ch05/01_main-chapter-code/tests.py
54+
pytest --ruff ch05/07_gpt_to_llama/tests/tests.py
55+
pytest --ruff ch06/01_main-chapter-code/tests.py
56+
57+
- name: Validate Selected Jupyter Notebooks (uv)
58+
shell: bash
59+
run: |
60+
source .venv/bin/activate
61+
pytest --ruff --nbval ch02/01_main-chapter-code/dataloader.ipynb
62+
pytest --ruff --nbval ch03/01_main-chapter-code/multihead-attention.ipynb
63+
pytest --ruff --nbval ch02/04_bonus_dataloader-intuition/dataloader-intuition.ipynb

.gitignore

+1
Original file line numberDiff line numberDiff line change
@@ -246,6 +246,7 @@ celerybeat.pid
246246
.venv
247247
.python-version
248248
uv.lock
249+
pixi.lock
249250
env/
250251
venv/
251252
ENV/

README.md

+4-3
Original file line numberDiff line numberDiff line change
@@ -54,9 +54,10 @@ You can alternatively view this and other files on GitHub at [https://github.com
5454
<br>
5555
<br>
5656

57-
[![Code tests (Linux)](https://github.com/rasbt/LLMs-from-scratch/actions/workflows/basic-tests-uv.yml/badge.svg?job=uv-tests-linux)](https://github.com/rasbt/LLMs-from-scratch/actions/workflows/basic-tests-uv.yml)
58-
[![Code tests (Windows)](https://github.com/rasbt/LLMs-from-scratch/actions/workflows/basic-tests-windows-uv-pip.yml/badge.svg)](https://github.com/rasbt/LLMs-from-scratch/actions/workflows/basic-tests-windows-uv-pip.yml)
59-
[![Code tests (macOS)](https://github.com/rasbt/LLMs-from-scratch/actions/workflows/basic-tests-uv.yml/badge.svg?job=uv-tests-macos)](https://github.com/rasbt/LLMs-from-scratch/actions/workflows/basic-tests-uv.yml)
57+
[![Code tests Linux](https://github.com/rasbt/LLMs-from-scratch/actions/workflows/basic-tests-uv-linux.yml/badge.svg)](https://github.com/rasbt/LLMs-from-scratch/actions/workflows/basic-tests-uv-linux.yml)
58+
[![Code tests Windows](https://github.com/rasbt/LLMs-from-scratch/actions/workflows/basic-tests-windows-uv-pip.yml/badge.svg)](https://github.com/rasbt/LLMs-from-scratch/actions/workflows/basic-tests-windows-uv-pip.yml)
59+
[![Code tests macOS](https://github.com/rasbt/LLMs-from-scratch/actions/workflows/basic-tests-uv-macos.yml/badge.svg)](https://github.com/rasbt/LLMs-from-scratch/actions/workflows/basic-tests-uv-macos.yml)
60+
6061

6162

6263

0 commit comments

Comments
 (0)