Skip to content

Commit

Permalink
Configure Webpack stats file to calculate bundle evolution (#1240)
Browse files Browse the repository at this point in the history
  • Loading branch information
Pierre-Gilles authored Jul 15, 2021
1 parent 4841cd1 commit bb7601b
Show file tree
Hide file tree
Showing 6 changed files with 586 additions and 2 deletions.
32 changes: 32 additions & 0 deletions .github/workflows/docker-master-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,38 @@ jobs:
working-directory: ./front
run: |
npm run compare-translations
build-front:
name: Front build
needs:
- test-front
runs-on: ubuntu-20.04
steps:
- name: ⬇️ Checkout code
uses: actions/checkout@v2
- name: 💽 Setup nodejs
uses: actions/setup-node@v2
with:
node-version: '14'
- name: 📇 Use npm cache
uses: c-hive/gha-npm-cache@v1
- name: 📦 Install NPM front packages
working-directory: ./front
run: |
npm ci
- name: 🏗️ Build front
working-directory: ./front
run: |
npm run build-with-stats
- name: Upload bundle ci
working-directory: ./front
run: npx relative-ci-agent
env:
RELATIVE_CI_KEY: ${{ secrets.RELATIVE_CI_KEY }}
- name: ↗️ Upload build artifact
uses: actions/upload-artifact@v2
with:
name: static
path: front/build
test-server:
name: Server test
runs-on: ubuntu-20.04
Expand Down
7 changes: 6 additions & 1 deletion .github/workflows/docker-pr-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,12 @@ jobs:
- name: 🏗️ Build front
working-directory: ./front
run: |
npm run build
npm run build-with-stats
- name: Upload bundle ci
working-directory: ./front
run: npx relative-ci-agent
env:
RELATIVE_CI_KEY: ${{ secrets.RELATIVE_CI_KEY }}
- name: ↗️ Upload build artifact
uses: actions/upload-artifact@v2
with:
Expand Down
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ static
gladys-backups
qemu-*
coverage

stats.json
# VSCode
.vscode
.tmp
Expand Down
Loading

0 comments on commit bb7601b

Please sign in to comment.