Skip to content

Commit 89017be

Browse files
JackyST0cursoragent
andcommitted
chore: add project support section
Co-authored-by: Cursor <cursoragent@cursor.com>
1 parent 38833a3 commit 89017be

5 files changed

Lines changed: 45 additions & 3 deletions

File tree

.github/workflows/check-feeds.yml

Lines changed: 25 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -44,15 +44,20 @@ jobs:
4444
const broken = status.feeds.filter(f => !f.valid);
4545
const issueTitle = '📊 RSS 订阅源健康状态报告';
4646
47-
// 查找是否已存在状态报告 Issue
47+
// 查找是否已存在状态报告 Issue,并固定复用同一个
4848
const issues = await github.rest.issues.listForRepo({
4949
owner: context.repo.owner,
5050
repo: context.repo.repo,
5151
state: 'open',
52-
labels: 'feed-status'
52+
labels: 'feed-status',
53+
per_page: 100
5354
});
5455
55-
const existingIssue = issues.data.find(i => i.title === issueTitle);
56+
const statusIssues = issues.data
57+
.filter(i => !i.pull_request && i.title === issueTitle)
58+
.sort((a, b) => b.number - a.number);
59+
const existingIssue = statusIssues[0];
60+
const duplicateIssues = statusIssues.slice(1);
5661
5762
// 生成报告内容
5863
let body = `## 📊 RSS 订阅源健康状态\n\n`;
@@ -85,6 +90,23 @@ jobs:
8590
body: body
8691
});
8792
console.log(`Updated issue #${existingIssue.number}`);
93+
94+
// 关闭重复的状态报告 Issue,之后固定复用最新的一个
95+
for (const issue of duplicateIssues) {
96+
await github.rest.issues.createComment({
97+
owner: context.repo.owner,
98+
repo: context.repo.repo,
99+
issue_number: issue.number,
100+
body: `已改为固定复用 #${existingIssue.number} 作为 RSS 订阅源健康状态报告,此重复报告自动关闭。`
101+
});
102+
await github.rest.issues.update({
103+
owner: context.repo.owner,
104+
repo: context.repo.repo,
105+
issue_number: issue.number,
106+
state: 'closed'
107+
});
108+
console.log(`Closed duplicate issue #${issue.number}`);
109+
}
88110
} else {
89111
// 创建新 Issue
90112
await github.rest.issues.create({

README.md

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -408,3 +408,12 @@ Simply copy the feed URL into your RSS reader. No assembly required.
408408

409409
See [contributing.md](contributing.md) for guidelines on adding feeds.
410410

411+
## Support This Project
412+
413+
If this project saves you time finding quality RSS feeds, you can support it by buying me a coffee.
414+
415+
<p>
416+
<img src="./assets/sponsor-alipay.png" width="160" alt="Alipay">
417+
<img src="./assets/sponsor-wechat.png" width="160" alt="WeChat Pay">
418+
</p>
419+

assets/sponsor-alipay.png

92.6 KB
Loading

assets/sponsor-wechat.png

76.1 KB
Loading

readme-zh.md

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -492,6 +492,17 @@
492492

493493
---
494494

495+
## ☕ 支持项目
496+
497+
如果这个项目帮你节省了寻找优质 RSS 订阅源的时间,欢迎请我喝杯咖啡。
498+
499+
<p>
500+
<img src="./assets/sponsor-alipay.png" width="160" alt="支付宝收款码">
501+
<img src="./assets/sponsor-wechat.png" width="160" alt="微信收款码">
502+
</p>
503+
504+
---
505+
495506
## 📜 相关资源
496507

497508
- [RSSHub 官方文档](https://docs.rsshub.app/)

0 commit comments

Comments
 (0)