Skip to content

Commit

Permalink
update CI
Browse files Browse the repository at this point in the history
  • Loading branch information
HandyS11 committed Mar 29, 2024
1 parent 024db5a commit e6716e3
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 15 deletions.
16 changes: 3 additions & 13 deletions .github/workflows/CD.yml
Original file line number Diff line number Diff line change
@@ -1,20 +1,10 @@
name: Continuous Deployment

on:
workflow_run:
workflows: ["CI.yml Continuous Integration"]
types:
- completed
push:
branches: [ "main" ]

jobs:
check_branch:
runs-on: ubuntu-latest
outputs:
is_main: ${{ steps.check.outputs.is_main }}
steps:
- id: check
run: echo "::set-output name=is_main::${{ github.event.workflow_run.head_branch == 'main' }}"

jobs:
build-and-deploy:
runs-on: ubuntu-latest

Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/CI.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@ name: Continuous Integration

on:
push:
branches: [ "main", "develop" ]
branches: [ "develop" ]
pull_request:
branches: [ "main", "develop"]
branches: [ "develop" ]

jobs:
build-and-deploy:
Expand Down

0 comments on commit e6716e3

Please sign in to comment.