Skip to content

Commit 176b7af

Browse files
committed
revert: 移除个人化改动(端口、logo、版本号、platform字段),保留给上游PR
1 parent 1f50af8 commit 176b7af

4 files changed

Lines changed: 26 additions & 29 deletions

File tree

backend/src/module/__version__.py

Lines changed: 0 additions & 1 deletion
This file was deleted.

backend/src/module/api/program.py

Lines changed: 12 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
import logging
22
import os
33
import signal
4-
import sys
54

65
from fastapi import APIRouter, Depends, HTTPException
76
from fastapi.responses import JSONResponse
@@ -69,14 +68,18 @@ async def stop():
6968

7069
@router.get("/status", response_model=dict, dependencies=[Depends(get_current_user)])
7170
async def program_status():
72-
is_linux = sys.platform == "linux"
73-
base = {
74-
"status": program.is_running,
75-
"version": VERSION,
76-
"first_run": program.first_run,
77-
"platform": "linux" if is_linux else "windows",
78-
}
79-
return base
71+
if not program.is_running:
72+
return {
73+
"status": False,
74+
"version": VERSION,
75+
"first_run": program.first_run,
76+
}
77+
else:
78+
return {
79+
"status": True,
80+
"version": VERSION,
81+
"first_run": program.first_run,
82+
}
8083

8184

8285
@router.get(

backend/src/module/conf/const.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
"program": {
88
"rss_time": 900,
99
"rename_time": 60,
10-
"webui_port": 37892,
10+
"webui_port": 7892,
1111
},
1212
"downloader": {
1313
"type": "qbittorrent",

backend/src/module/core/program.py

Lines changed: 13 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -18,22 +18,17 @@
1818
logger = logging.getLogger(__name__)
1919

2020
figlet = r"""
21-
$$$$$$\ $$\ $$\ $$\ $$\
22-
$$ __$$\ $$$\ $$$ |\$$\ $$ |
23-
$$ / $$ |$$$$\ $$$$ | \$$\ $$ /
24-
$$$$$$$$ |$$\$$\$$ $$ | \$$$$ /
25-
$$ __$$ |$$ \$$$ $$ | \$$ /
26-
$$ | $$ |$$ |\$ /$$ | $$ |
27-
$$ | $$ |$$ | \_/ $$ | $$ |
28-
\__| \__|\__| \__| \__|
29-
30-
___ __ __ _
31-
/ | __ __/ /_____ / /_ ____ _____ ____ ___ ______ ___ (_)
32-
/ /| |/ / / / __/ __ \/ __ \/ __ `/ __ \/ __ `/ / / / __ `__ \/ /
33-
/ ___ / /_/ / /_/ /_/ / /_/ / /_/ / / / / /_/ / /_/ / / / / / / /
34-
/_/ |_\__,_/\__/\____/_.___/\__,_/_/ /_/\__, /\__,_/_/ /_/ /_/_/
35-
/____/
21+
_ ____ _
22+
/\ | | | _ \ (_)
23+
/ \ _ _| |_ ___ | |_) | __ _ _ __ __ _ _ _ _ __ ___ _
24+
/ /\ \| | | | __/ _ \| _ < / _` | '_ \ / _` | | | | '_ ` _ \| |
25+
/ ____ \ |_| | || (_) | |_) | (_| | | | | (_| | |_| | | | | | | |
26+
/_/ \_\__,_|\__\___/|____/ \__,_|_| |_|\__, |\__,_|_| |_| |_|_|
27+
__/ |
28+
|___/
3629
"""
30+
31+
3732
class Program(RenameThread, RSSThread, OffsetScanThread, CalendarRefreshThread):
3833
def __init__(self):
3934
super().__init__()
@@ -44,10 +39,10 @@ def __start_info():
4439
for line in figlet.splitlines():
4540
logger.info(line.strip("\n"))
4641
logger.info(
47-
f"Version {VERSION} Author: AMYdd00 | Amy 自建修复版"
42+
f"Version {VERSION} Author: EstrellaXD Twitter: https://twitter.com/Estrella_Pan"
4843
)
49-
logger.info("GitHub: https://github.com/AMYdd00/Auto_Bangumi/")
50-
logger.info("Starting...")
44+
logger.info("GitHub: https://github.com/EstrellaXD/Auto_Bangumi/")
45+
logger.info("Starting AutoBangumi...")
5146

5247
async def startup(self):
5348
# Prevent duplicate startup due to nested router lifespan events

0 commit comments

Comments
 (0)