Skip to content

Commit 9495307

Browse files
committed
Use workflow templates for minimizer and no-response
1 parent c0c8a56 commit 9495307

File tree

3 files changed

+10
-189
lines changed

3 files changed

+10
-189
lines changed

.github/workflows/image-minimizer.js

Lines changed: 0 additions & 148 deletions
This file was deleted.

.github/workflows/image-minimizer.yml

Lines changed: 4 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -9,26 +9,7 @@ on:
99
types: [opened, edited]
1010

1111
jobs:
12-
try-minimize:
13-
runs-on: ubuntu-latest
14-
15-
steps:
16-
- uses: actions/checkout@v4
17-
with:
18-
token: ${{ secrets.FOSSIFYBOT_TOKEN }}
19-
20-
- uses: actions/setup-node@v4
21-
with:
22-
node-version: 16
23-
24-
- name: Install probe-image-size
25-
run: npm i probe-image-size@7.2.3 --ignore-scripts
26-
27-
- name: Minimize simple images
28-
uses: actions/github-script@v7
29-
timeout-minutes: 3
30-
with:
31-
github-token: ${{ secrets.FOSSIFYBOT_TOKEN }}
32-
script: |
33-
const script = require('.github/workflows/image-minimizer.js');
34-
await script({github, context});
12+
call-image-minimizer-workflow:
13+
uses: FossifyOrg/.github/.github/workflows/image-minimizer.yml@main
14+
secrets:
15+
FOSSIFYBOT_TOKEN: ${{ secrets.FOSSIFYBOT_TOKEN }}

.github/workflows/no-response.yml

Lines changed: 6 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,24 +1,12 @@
1-
name: no-response
1+
name: No Response
22

33
on:
44
schedule:
5-
- cron: '0 0 * * *' # Runs daily at midnight
5+
- cron: '0 12 * * *' # Runs daily at noon
66
workflow_dispatch:
77

88
jobs:
9-
noResponse:
10-
runs-on: ubuntu-latest
11-
steps:
12-
- uses: actions/stale@v9
13-
with:
14-
repo-token: ${{ secrets.FOSSIFYBOT_TOKEN }}
15-
days-before-stale: -1
16-
# Number of days of inactivity before an issue is closed for lack of response.
17-
days-before-close: 14
18-
only-labels: 'waiting for author'
19-
stale-issue-label: 'waiting for author'
20-
stale-pr-label: 'waiting for author'
21-
remove-stale-when-updated: false
22-
ignore-updates: true
23-
close-issue-message: This issue has been automatically closed due to inactivity. We requested additional information but have not received a response from the original author. Without the requested details, we cannot proceed. If you have or find the information needed, please comment so we can reopen the issue.
24-
close-pr-message: This pull request has been automatically closed due to inactivity. We requested additional information but have not received a response from the original author. Without the requested details, we cannot proceed. If you have the needed information or updates, please reopen the PR or comment so we can continue the review.
9+
call-no-response-workflow:
10+
uses: FossifyOrg/.github/.github/workflows/no-response.yml@main
11+
secrets:
12+
FOSSIFYBOT_TOKEN: ${{ secrets.FOSSIFYBOT_TOKEN }}

0 commit comments

Comments
 (0)