Merge branch 'main' into patterned-territory

This commit is contained in:
Scott Anderson
2025-05-20 01:00:27 -04:00
committed by GitHub
5 changed files with 34 additions and 55 deletions
+31 -3
View File
@@ -1,11 +1,15 @@
name: 🧪 CI
on: [push, pull_request]
on:
pull_request:
push:
branches: [main]
permissions: {}
jobs:
build:
name: Build
name: 🏗️ Build
runs-on: ubuntu-latest
steps:
- name: Checkout repository
@@ -23,7 +27,7 @@ jobs:
path: out/index.html
retention-days: 1
test:
name: Test
name: 🔬 Test
runs-on: ubuntu-latest
steps:
- name: Checkout repository
@@ -36,3 +40,27 @@ jobs:
node-version: 20
- run: npm ci
- run: npm test
eslint:
name: 🔍 ESLint
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: "20"
cache: "npm"
- run: npm ci
- run: npx eslint --format gha
prettier:
name: 🎨 Prettier
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: "20"
cache: "npm"
- run: npm ci
- run: npx prettier --check .
+2 -9
View File
@@ -41,16 +41,9 @@ jobs:
# Don't deploy on push if this is a fork
if: ${{ github.event_name == 'workflow_dispatch' || github.repository == 'openfrontio/OpenFrontIO' }}
# Use different logic based on event type
name: ${{
github.event_name == 'push'
&& (github.ref_name == 'main' && 'openfront.dev'
|| format('{0}.openfront.dev', github.ref_name))
|| inputs.target_subdomain && format('{0}.{1}', inputs.target_subdomain, inputs.target_domain)
|| inputs.target_domain
|| 'openfront.dev'
}}
name: Deploy to ${{ inputs.target_domain || 'openfront.dev' }}
runs-on: ubuntu-latest
environment: ${{ inputs.target_domain == 'openfront.io' && 'prod' || '' }}
environment: ${{ inputs.target_domain == 'openfront.io' && 'prod' || 'staging' }}
env:
DOMAIN: ${{ inputs.target_domain || 'openfront.dev' }}
SUBDOMAIN: ${{ github.event_name == 'push' && github.ref_name || inputs.target_subdomain || 'main' }}
-21
View File
@@ -1,21 +0,0 @@
name: 🔍 ESLint
on:
pull_request:
push:
branches: [main]
permissions: {}
jobs:
eslint:
name: Check
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: "20"
cache: "npm"
- run: npm ci
- run: npx eslint --format gha
+1 -1
View File
@@ -8,7 +8,7 @@ permissions: {}
jobs:
validate-description:
name: Check
name: Validate Description
runs-on: ubuntu-latest
steps:
- uses: actions/github-script@v7
-21
View File
@@ -1,21 +0,0 @@
name: 🎨 Prettier
on:
pull_request:
push:
branches: [main]
permissions: {}
jobs:
prettier:
name: Check
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: "20"
cache: "npm"
- run: npm ci
- run: npx prettier --check .