Skip to content

Commit 8bd7113

Browse files
[FIX] #484 Comment Action for Automated Conference Issues (#485)
* Create a Comment Action for Automated Conference Issues #442 * adds comment only if the issue is created by a bot * fixes * fixes * Update conference.yml * fixes
1 parent 692adae commit 8bd7113

File tree

2 files changed

+23
-3
lines changed

2 files changed

+23
-3
lines changed

.github/workflows/conference.yml

Lines changed: 21 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,9 +57,29 @@ jobs:
5757
runs-on: ubuntu-latest
5858

5959
steps:
60+
- name: Checkout repository
61+
uses: actions/checkout@v4
62+
with:
63+
token: ${{ env.GITHUB_TOKEN }}
64+
65+
- name: Setup Python environment
66+
uses: actions/setup-python@v4
67+
with:
68+
python-version: "3.11"
69+
70+
- name: Install dependencies
71+
run: pip install PyGithub PyYAML pre-commit
72+
73+
- name: Run script
74+
env:
75+
GITHUB_TOKEN: ${{ env.GITHUB_TOKEN }}
76+
run: |
77+
python _conferences
78+
pre-commit run --all-files --show-diff-on-failure
79+
6080
- name: Add comment to the issue
6181
uses: actions/github-script@v6
62-
if: ${{ github.event.issue.user.type != 'User' }} #adds comment only if the issue is created by a bot
82+
if: ${{ github.event.action == 'opened' && startsWith(github.event.issue.title, '[CONFERENCE]') && contains(github.event.issue.labels.*.name, 'conference') }} #adds comment only if the issue is created by a user
6383
with:
6484
github-token: ${{ secrets.GITHUB_TOKEN }}
6585
script: |

.github/workflows/scorecard.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,9 +10,9 @@ on:
1010
# To guarantee Maintained check is occasionally updated. See
1111
# https://github.com/ossf/scorecard/blob/main/docs/checks.md#maintained
1212
schedule:
13-
- cron: '22 15 * * 4'
13+
- cron: "22 15 * * 4"
1414
push:
15-
branches: [ "gh-pages" ]
15+
branches: ["gh-pages"]
1616

1717
# Declare default permissions as read only.
1818
permissions: read-all

0 commit comments

Comments
 (0)