Skip to content

Commit

Permalink
perf: clean app data
Browse files Browse the repository at this point in the history
  • Loading branch information
xunpod committed Jun 17, 2024
1 parent 5079510 commit 7323abb
Showing 1 changed file with 22 additions and 0 deletions.
22 changes: 22 additions & 0 deletions main.py
Original file line number Diff line number Diff line change
Expand Up @@ -132,6 +132,28 @@ def main():
df_update = df_update._append(df_new, ignore_index=True)
df_update = df_update._append(df_down, ignore_index=True)
df_update = df_update._append(df_upgrade, ignore_index=True)
for name in df_update["应用名称"]:
a = "3A4000"
if a in name:
df_update.drop((df_update[df_update["应用名称"] == name]).index, inplace=True)
else:
continue
df_update.drop(columns="图片链接", axis=1, inplace=True)
df_update.sort_values("应用编号", ascending=True, inplace=True)
# 删除开源软件
df_update.drop((df_update[df_update["开发者"] == "开源软件"]).index, inplace=True)
# 删除二进制翻译软件
df_update.drop((df_update[df_update["开发者"] == "二进制翻译软件"]).index, inplace=True)
# 删除开源软件(云顶书院迁移)
df_update.drop((df_update[df_update["开发者"] == "开源软件(云顶书院迁移)"]).index, inplace=True)
df_update.rename(
columns={
"应用编号": "编号",
# "安装教程": "详细信息",
"版本号": "版本",
},
inplace=True,
)
df_down.to_csv("loongapplist-down.csv", encoding="utf-8-sig", index=False)
df_new.to_csv("loongapplist-new.csv", encoding="utf-8-sig", index=False)
df_upgrade.to_csv("loongapplist-upgrade.csv", encoding="utf-8-sig", index=False)
Expand Down

0 comments on commit 7323abb

Please sign in to comment.