Skip to content

Commit 842b10d

Browse files
authored
Merge pull request #7 from AptS-1547/enchancement-logo
refactor: 更新 README 和介绍文档,调整布局并添加项目 logo
2 parents c4a5c4e + 7f45fe6 commit 842b10d

File tree

10 files changed

+131
-711
lines changed

10 files changed

+131
-711
lines changed

LICENSE

Lines changed: 10 additions & 671 deletions
Large diffs are not rendered by default.

NOTICE

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
OneBot GitHub Webhook
2+
Copyright 2025 AptS-1547
3+
4+
This product includes software developed by AptS-1547 (https://github.com/AptS-1547).
5+
6+
This software uses the following third-party libraries that are distributed
7+
under their own licenses:
8+
9+
- FastAPI (https://fastapi.tiangolo.com/) - MIT License
10+
- Pydantic (https://pydantic-docs.helpmanual.io/) - MIT License
11+
- Pydantic-settings (https://github.com/pydantic/pydantic-settings) - MIT License
12+
- aiohttp (https://docs.aiohttp.org/) - Apache License 2.0
13+
- PyYAML (https://pyyaml.org/) - MIT License
14+
- Uvicorn (https://www.uvicorn.org/) - BSD License
15+
- fnmatch (Python Standard Library) - Python Software Foundation License
16+
17+
All dependencies and their transitive dependencies are subject to their own licenses.
18+
Please see each project for full licensing details.

README.md

Lines changed: 21 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,24 +1,27 @@
1-
<h1 align="center">
2-
OneBot GitHub Webhook
3-
</h1>
1+
<div align="center">
2+
<img src="./docs/src/resources/logo.png" alt="OneBot GitHub Webhook Logo">
3+
</div>
44

5-
<p align="center">
6-
一个用于接收 GitHub Webhook 并通过 OneBot 协议将推送通知转发到 QQ 群的服务。
7-
</p>
5+
<div align="center">
86

9-
<p align="center">
10-
<a href="https://www.codefactor.io/repository/github/AptS-1547/onebot-github-webhook/">
11-
<img src="https://www.codefactor.io/repository/github/AptS-1547/onebot-github-webhook/badge" alt="CodeFactor" />
12-
</a>
7+
# OneBot GitHub Webhook
138

14-
<a href="https://github.com/AptS-1547/onebot-github-webhook/activity">
15-
<img src="https://img.shields.io/github/last-commit/AptS-1547/onebot-github-webhook/master" alt="Last Commit"/>
16-
</a>
9+
_✨ GitHub Webhook 推送消息到 QQ 群 ✨_
1710

18-
<a href="./LICENSE">
19-
<img src="https://img.shields.io/github/license/AptS-1547/onebot-github-webhook" alt="GPL-3.0\"/>
20-
</a>
21-
</p>
11+
<a href="https://www.codefactor.io/repository/github/AptS-1547/onebot-github-webhook/">
12+
<img src="https://www.codefactor.io/repository/github/AptS-1547/onebot-github-webhook/badge" alt="CodeFactor" />
13+
</a>
14+
15+
<a href="https://github.com/AptS-1547/onebot-github-webhook/activity">
16+
<img src="https://img.shields.io/github/last-commit/AptS-1547/onebot-github-webhook/master" alt="Last Commit"/>
17+
</a>
18+
19+
<a href="./LICENSE">
20+
<img src="https://img.shields.io/github/license/AptS-1547/onebot-github-webhook" alt="Apache License 2.0" />
21+
</a>
22+
23+
<img src="https://img.shields.io/badge/python-3.9+-blue.svg" alt="python">
24+
</div>
2225

2326
## 功能特点
2427

@@ -347,4 +350,4 @@ A: 本程序暂时不支持推送到多个 QQ 机器人
347350

348351
## 许可证
349352

350-
本项目采用 GPL-3.0 许可证。
353+
本项目采用 [Apache License 2.0](LICENSE) 许可证。

app.py

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,23 @@
1+
# Copyright 2025 AptS-1547
2+
# Licensed under the Apache License, Version 2.0 (the "License");
3+
# you may not use this file except in compliance with the License.
4+
# You may obtain a copy of the License at
5+
#
6+
# http://www.apache.org/licenses/LICENSE-2.0
7+
#
8+
# Unless required by applicable law or agreed to in writing, software
9+
# distributed under the License is distributed on an "AS IS" BASIS,
10+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
11+
# See the License for the specific language governing permissions and
12+
# limitations under the License.
13+
114
"""
215
OneBot GitHub Webhook 入口文件
316
本文件用于接收 GitHub Webhook 事件,并将其转发到配置的 OneBot 目标。
417
作者:AptS:1547
518
版本:0.1.0-alpha
619
日期:2025-04-17
7-
本程序遵循 GPL-3.0 许可证
20+
本程序遵循 Apache License 2.0 许可证
821
"""
922

1023
import logging

docs/src/faq.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,4 +25,4 @@ A: 本程序暂时不支持推送到多个 QQ 机器人
2525

2626
## 许可证
2727

28-
本项目采用 GPL-3.0 许可证。
28+
本项目采用 [Apache License 2.0](LICENSE) 许可证。

docs/src/introduction.md

Lines changed: 24 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -2,23 +2,30 @@
22
OneBot GitHub Webhook
33
</h1>
44

5-
<p align="center">
6-
OneBot GitHub Webhook 是一个用于接收 GitHub Webhook 推送事件并通过 OneBot 协议将通知转发到 QQ 群/好友的轻量级服务。它允许开发者和团队实时跟踪 GitHub 仓库活动,提高协作效率和项目透明度。
7-
</p>
8-
9-
<p align="center">
10-
<a href="https://www.codefactor.io/repository/github/AptS-1547/onebot-github-webhook/">
11-
<img src="https://www.codefactor.io/repository/github/AptS-1547/onebot-github-webhook/badge" alt="CodeFactor" />
12-
</a>
13-
14-
<a href="https://github.com/AptS-1547/onebot-github-webhook/activity">
15-
<img src="https://img.shields.io/github/last-commit/AptS-1547/onebot-github-webhook/master" alt="Last Commit"/>
16-
</a>
17-
18-
<a href="./LICENSE">
19-
<img src="https://img.shields.io/github/license/AptS-1547/onebot-github-webhook" alt="GPL-3.0\"/>
20-
</a>
21-
</p>
5+
<div align="center">
6+
<img src="./resources/logo.png" alt="OneBot GitHub Webhook Logo">
7+
</div>
8+
9+
<div align="center">
10+
11+
# OneBot GitHub Webhook
12+
13+
<p>OneBot GitHub Webhook 是一个用于接收 GitHub Webhook 推送事件并通过 OneBot 协议将通知转发到 QQ 群/好友的轻量级服务。它允许开发者和团队实时跟踪 GitHub 仓库活动,提高协作效率和项目透明度。</p>
14+
15+
<a href="https://www.codefactor.io/repository/github/AptS-1547/onebot-github-webhook/">
16+
<img src="https://www.codefactor.io/repository/github/AptS-1547/onebot-github-webhook/badge" alt="CodeFactor" />
17+
</a>
18+
19+
<a href="https://github.com/AptS-1547/onebot-github-webhook/activity">
20+
<img src="https://img.shields.io/github/last-commit/AptS-1547/onebot-github-webhook/master" alt="Last Commit"/>
21+
</a>
22+
23+
<a href="./LICENSE">
24+
<img src="https://img.shields.io/github/license/AptS-1547/onebot-github-webhook" alt="Apache License 2.0" />
25+
</a>
26+
27+
<img src="https://img.shields.io/badge/python-3.9+-blue.svg" alt="python">
28+
</div>
2229

2330
## 功能特点
2431

docs/src/resources/logo.png

181 KB
Loading

hooks/github_webhook.py

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,23 @@
1+
# Copyright 2025 AptS-1547
2+
# Licensed under the Apache License, Version 2.0 (the "License");
3+
# you may not use this file except in compliance with the License.
4+
# You may obtain a copy of the License at
5+
#
6+
# http://www.apache.org/licenses/LICENSE-2.0
7+
#
8+
# Unless required by applicable law or agreed to in writing, software
9+
# distributed under the License is distributed on an "AS IS" BASIS,
10+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
11+
# See the License for the specific language governing permissions and
12+
# limitations under the License.
13+
114
"""
215
GitHub Webhook 处理模块
316
本模块用于处理 GitHub Webhook 事件,包括验证签名、查找匹配的 webhook 配置和提取 push 事件数据。
417
作者:AptS:1547
518
版本:0.1.0-alpha
619
日期:2025-04-17
7-
本程序遵循 GPL-3.0 许可证
20+
本程序遵循 Apache License 2.0 许可证
821
"""
922

1023
import hmac

send_message.py

Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,25 @@
1+
# Copyright 2025 AptS-1547
2+
# Licensed under the Apache License, Version 2.0 (the "License");
3+
# you may not use this file except in compliance with the License.
4+
# You may obtain a copy of the License at
5+
#
6+
# http://www.apache.org/licenses/LICENSE-2.0
7+
#
8+
# Unless required by applicable law or agreed to in writing, software
9+
# distributed under the License is distributed on an "AS IS" BASIS,
10+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
11+
# See the License for the specific language governing permissions and
12+
# limitations under the License.
13+
114
"""
215
OneBot V11 客户端
316
本模块提供了一个 OneBot V11 客户端的实现,支持通过 WebSocket 和 HTTP 发送消息。
417
作者:AptS:1547
518
版本:0.1.0-alpha
619
日期:2025-04-17
7-
本程序遵循 GPL-3.0 许可证
20+
本程序遵循 Apache License 2.0 许可证
821
"""
22+
923
import json
1024
import logging
1125
from typing import Union, List, Dict, Any

settings.py

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,23 @@
1+
# Copyright 2025 AptS-1547
2+
# Licensed under the Apache License, Version 2.0 (the "License");
3+
# you may not use this file except in compliance with the License.
4+
# You may obtain a copy of the License at
5+
#
6+
# http://www.apache.org/licenses/LICENSE-2.0
7+
#
8+
# Unless required by applicable law or agreed to in writing, software
9+
# distributed under the License is distributed on an "AS IS" BASIS,
10+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
11+
# See the License for the specific language governing permissions and
12+
# limitations under the License.
13+
114
"""
215
Onebot Github Webhook 配置类
316
本文件用于定义 Onebot Github Webhook 的配置类和验证逻辑。
417
作者:AptS:1547
518
版本:0.1.0-alpha
619
日期:2025-04-17
7-
本程序遵循 GPL-3.0 许可证
20+
本程序遵循 Apache License 2.0 许可证
821
"""
922

1023
import pathlib

0 commit comments

Comments
 (0)