Run unit tests on pull requests targeting master.
Keep deploy limited to pushes on master so PR CI validates changes without deploying.
This commit is contained in:
@@ -3,6 +3,8 @@ name: Deploy Company Site
|
||||
on:
|
||||
push:
|
||||
branches: [master]
|
||||
pull_request:
|
||||
branches: [master]
|
||||
|
||||
jobs:
|
||||
test:
|
||||
@@ -24,6 +26,7 @@ jobs:
|
||||
|
||||
deploy:
|
||||
needs: test
|
||||
if: gitea.event_name == 'push' && gitea.ref == 'refs/heads/master'
|
||||
runs-on: self-hosted
|
||||
steps:
|
||||
- name: Checkout
|
||||
|
||||
Reference in New Issue
Block a user