Skip to content

Merge pull request #216 from sparkoo/readme #85

Merge pull request #216 from sparkoo/readme

Merge pull request #216 from sparkoo/readme #85

# This workflow will build the FACEIT browser extension for Chrome and Firefox
# It installs dependencies, builds the extension, and packages it for distribution
name: Node.js CI - browser plugin
permissions:
contents: read
on:
push:
branches: ["master", "dev"]
pull_request:
branches: ["master", "dev"]
paths:
- "browserplugin/faceit/**"
- ".github/workflows/nodejs_browserplugin.yml"
jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [lts/*]
browser: [chrome, firefox]
steps:
- uses: actions/checkout@v4
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
cache: "npm"
cache-dependency-path: browserplugin/faceit/package-lock.json
- name: Install dependencies
run: npm ci
working-directory: ./browserplugin/faceit
- name: Build for ${{ matrix.browser }}
run: npm run build:${{ matrix.browser }}
working-directory: ./browserplugin/faceit
- name: Package extension
run: npm run package:${{ matrix.browser }}
working-directory: ./browserplugin/faceit
- name: Upload build artifacts
uses: actions/upload-artifact@v4
with:
name: faceit-extension-${{ matrix.browser }}-${{ github.sha }}
path: browserplugin/faceit/dist/
retention-days: 30