Skip to content

Commit

Permalink
manual action triggers
Browse files Browse the repository at this point in the history
  • Loading branch information
tadaspetra committed Dec 6, 2024
1 parent 703e625 commit 06b606d
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 9 deletions.
16 changes: 10 additions & 6 deletions .github/workflows/create-discussions.yml
Original file line number Diff line number Diff line change
@@ -1,11 +1,12 @@
name: Create GitHub Discussions

on:
push:
branches:
- main
paths:
- "src/content/apps/**"
# pull_request:
# types: [closed]
# branches:
# - main
# paths:
# - "src/content/apps/**"
workflow_dispatch:
inputs:
name:
Expand All @@ -23,7 +24,10 @@ on:

jobs:
create-discussion:
if: github.event_name == 'workflow_dispatch' || (github.event_name == 'push' && github.ref == 'refs/heads/main')
if: >
github.event_name == 'workflow_dispatch' ||
(github.event_name == 'pull_request' &&
github.event.pull_request.merged == true)
runs-on: ubuntu-latest
permissions:
discussions: write
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/update-votes.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@ on:
schedule:
- cron: "0 */1 * * *" # Run every 6 hours
workflow_dispatch: # Allow manual triggers
push:
branches:
- main
# push:
# branches:
# - main

jobs:
update-votes:
Expand Down

0 comments on commit 06b606d

Please sign in to comment.