ci: cache pip wheels, npm deps, and embedded Python in release workflow
- Add pip and npm caching to build-windows and build-linux jobs - Cache embedded Python zip and Windows wheels across runs - Collapse per-dep pip download loop into a single resolver call First run after this lands populates the caches; subsequent release builds should drop from ~11min to ~3-5min.
This commit is contained in:
@@ -105,6 +105,7 @@ jobs:
|
||||
- uses: actions/setup-node@v4
|
||||
with:
|
||||
node-version: '20'
|
||||
cache: 'npm'
|
||||
|
||||
- name: Build frontend
|
||||
run: npm ci && npm run build
|
||||
@@ -112,6 +113,20 @@ jobs:
|
||||
- uses: actions/setup-python@v5
|
||||
with:
|
||||
python-version: '3.11'
|
||||
cache: 'pip'
|
||||
cache-dependency-path: pyproject.toml
|
||||
|
||||
- name: Cache embedded Python
|
||||
uses: actions/cache@v4
|
||||
with:
|
||||
path: build/python-embed.zip
|
||||
key: python-embed-3.11.9
|
||||
|
||||
- name: Cache Windows wheels
|
||||
uses: actions/cache@v4
|
||||
with:
|
||||
path: build/win-wheels
|
||||
key: win-wheels-${{ hashFiles('build-dist-windows.sh', 'pyproject.toml') }}
|
||||
|
||||
- name: Install build tools
|
||||
run: sudo apt-get update && sudo apt-get install -y --no-install-recommends nsis zip
|
||||
@@ -179,6 +194,7 @@ jobs:
|
||||
- uses: actions/setup-node@v4
|
||||
with:
|
||||
node-version: '20'
|
||||
cache: 'npm'
|
||||
|
||||
- name: Build frontend
|
||||
run: npm ci && npm run build
|
||||
@@ -186,6 +202,8 @@ jobs:
|
||||
- uses: actions/setup-python@v5
|
||||
with:
|
||||
python-version: '3.11'
|
||||
cache: 'pip'
|
||||
cache-dependency-path: pyproject.toml
|
||||
|
||||
- name: Build Linux distribution
|
||||
run: |
|
||||
|
||||
Reference in New Issue
Block a user