fix: Remove unused npm pakcages #1438
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: GitHub Actions Workflow | |
on: [push] | |
jobs: | |
build: | |
name: Build | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Setup Ruby environment | |
uses: ruby/setup-ruby@v1 | |
with: | |
ruby-version: '3.3' # Not needed with a .ruby-version file | |
bundler-cache: true # runs 'bundle install' and caches installed gems automatically | |
- name: Setup Node.js environment | |
uses: actions/setup-node@v4 | |
- name: Cache node modules | |
id: cache-npm | |
uses: actions/cache@v4 | |
env: | |
cache-name: cache-node-modules | |
with: | |
# npm cache files are stored in `~/.npm` on Linux/macOS | |
path: | | |
~/.npm | |
./node_modules | |
key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('**/package*.json') }} | |
restore-keys: | | |
${{ runner.os }}-build-${{ env.cache-name }}- | |
${{ runner.os }}-build- | |
${{ runner.os }}- | |
- if: ${{ steps.cache-npm.outputs.cache-hit != 'true' }} | |
name: List the state of node modules cache | |
continue-on-error: true | |
run: npm list | |
- if: ${{ steps.cache-npm.outputs.cache-hit != 'true' }} | |
name: Install npm dependencies | |
run: | | |
npm ci | |
- name: Download icon fonts | |
run: | | |
npm run download-icons --if-present | |
ls -la _assets/styles/icons | |
- name: Formatting Rules | |
run: npm run prettier --if-present | |
- name: Code-Quality Rules | |
run: npm run lint --if-present | |
- name: Compile website | |
run: | | |
npm run build --if-present | |
npm run test --if-present |