mirror of
https://github.com/polaroi8d/cactoide.git
synced 2026-03-22 06:05:28 +00:00
44 lines
960 B
YAML
44 lines
960 B
YAML
name: test & build
|
|
|
|
on:
|
|
push:
|
|
branches: [main]
|
|
pull_request:
|
|
branches: ['**']
|
|
|
|
jobs:
|
|
test:
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
- name: Checkout repository
|
|
uses: actions/checkout@v4
|
|
|
|
- name: Setup Node.js
|
|
uses: actions/setup-node@v4
|
|
with:
|
|
node-version: '20'
|
|
cache: 'npm'
|
|
|
|
- name: Install dependencies
|
|
run: npm ci
|
|
|
|
- name: Run linting
|
|
run: npm run lint
|
|
|
|
- name: Build application
|
|
run: npm run build
|
|
env:
|
|
FEDERATION_INSTANCE: ${{ vars.FEDERATION_INSTANCE }}
|
|
PUBLIC_LANDING_INFO: ${{ vars.PUBLIC_LANDING_INFO }}
|
|
LOG_PRETTY: ${{ vars.LOG_PRETTY }}
|
|
LOG_LEVEL: ${{ vars.LOG_LEVEL }}
|
|
|
|
- name: Test build output
|
|
run: |
|
|
if [ ! -d "build" ]; then
|
|
echo "Build directory not found!"
|
|
exit 1
|
|
fi
|
|
echo "Build successful! Build directory exists."
|