Skip to content

Commit

Permalink
Push to production whenever main is updated (#744)
Browse files Browse the repository at this point in the history
  • Loading branch information
nex3 authored Jun 24, 2023
1 parent cc565d6 commit 467243a
Showing 1 changed file with 18 additions and 1 deletion.
19 changes: 18 additions & 1 deletion .github/workflows/test.yml → .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
name: Lint & Test
name: CI

on:
push:
branches: [main, 'feature.*']
pull_request:
types: [reopened]

Expand Down Expand Up @@ -39,3 +40,19 @@ jobs:
run: npm ci
- name: Lint
run: npm run lint:ci

release:
name: Deploy
runs-on: ubuntu-latest
if:
github.event_name == 'push' &&
github.ref == 'refs/heads/main' &&
github.repository == 'sass/sass-site'

steps:
- uses: actions/checkout@v3
with:
token: ${{ secrets.GH_TOKEN }}

# Pushing to the production branch will trigger Netlify's release process.
- run: git push -f origin main:production

0 comments on commit 467243a

Please sign in to comment.