fixed CI workflow

This commit is contained in:
vabene1111
2025-07-03 17:04:27 +02:00
parent 7266ff8978
commit dd921f1555
2 changed files with 11 additions and 8 deletions

View File

@@ -9,8 +9,8 @@ jobs:
strategy: strategy:
max-parallel: 4 max-parallel: 4
matrix: matrix:
python-version: ["3.10"] python-version: ["3.12"]
node-version: ["18"] node-version: ["22"]
steps: steps:
- uses: actions/checkout@v4 - uses: actions/checkout@v4
- uses: awalsh128/cache-apt-pkgs-action@v1.4.3 - uses: awalsh128/cache-apt-pkgs-action@v1.4.3
@@ -36,7 +36,6 @@ jobs:
with: with:
path: | path: |
./cookbook/static ./cookbook/static
./vue/webpack-stats.json
./staticfiles ./staticfiles
key: | key: |
${{ runner.os }}-${{ matrix.python-version }}-${{ matrix.node-version }}-collectstatic-${{ hashFiles('**/*.css', '**/*.js', 'vue/src/*') }} ${{ runner.os }}-${{ matrix.python-version }}-${{ matrix.node-version }}-collectstatic-${{ hashFiles('**/*.css', '**/*.js', 'vue/src/*') }}
@@ -48,30 +47,28 @@ jobs:
with: with:
node-version: ${{ matrix.node-version }} node-version: ${{ matrix.node-version }}
cache: "yarn" cache: "yarn"
cache-dependency-path: ./vue/yarn.lock cache-dependency-path: ./vue3/yarn.lock
- name: Install Vue dependencies - name: Install Vue dependencies
if: steps.django_cache.outputs.cache-hit != 'true' if: steps.django_cache.outputs.cache-hit != 'true'
working-directory: ./vue working-directory: ./vue3
run: yarn install run: yarn install
- name: Build Vue dependencies - name: Build Vue dependencies
if: steps.django_cache.outputs.cache-hit != 'true' if: steps.django_cache.outputs.cache-hit != 'true'
working-directory: ./vue working-directory: ./vue3
run: yarn build run: yarn build
- name: Compile Django StaticFiles - name: Compile Django StaticFiles
if: steps.django_cache.outputs.cache-hit != 'true' if: steps.django_cache.outputs.cache-hit != 'true'
run: | run: |
python3 manage.py collectstatic --noinput python3 manage.py collectstatic --noinput
python3 manage.py collectstatic_js_reverse
- uses: actions/cache/save@v4 - uses: actions/cache/save@v4
if: steps.django_cache.outputs.cache-hit != 'true' if: steps.django_cache.outputs.cache-hit != 'true'
with: with:
path: | path: |
./cookbook/static ./cookbook/static
./vue/webpack-stats.json
./staticfiles ./staticfiles
key: | key: |
${{ runner.os }}-${{ matrix.python-version }}-${{ matrix.node-version }}-collectstatic-${{ hashFiles('**/*.css', '**/*.js', 'vue/src/*') }} ${{ runner.os }}-${{ matrix.python-version }}-${{ matrix.node-version }}-collectstatic-${{ hashFiles('**/*.css', '**/*.js', 'vue/src/*') }}

View File

@@ -38,6 +38,12 @@
"vite-plugin-pwa": "^1.0.0", "vite-plugin-pwa": "^1.0.0",
"workbox-build": "^7.3.0", "workbox-build": "^7.3.0",
"workbox-window": "^7.3.0", "workbox-window": "^7.3.0",
"workbox-background-sync": "^7.0.0",
"workbox-expiration": "^7.0.0",
"workbox-navigation-preload": "^7.0.0",
"workbox-precaching": "^7.0.0",
"workbox-routing": "^7.0.0",
"workbox-strategies": "^6.2.4",
"vite-plugin-vuetify": "^2.1.1", "vite-plugin-vuetify": "^2.1.1",
"vue-tsc": "^2.2.8" "vue-tsc": "^2.2.8"
} }