{"id":15030840,"url":"https://github.com/sqzw-x/mdcx","last_synced_at":"2025-05-14T05:00:57.525Z","repository":{"id":205831682,"uuid":"715192363","full_name":"sqzw-x/mdcx","owner":"sqzw-x","description":"Movie metadata scraper","archived":false,"fork":false,"pushed_at":"2025-04-21T12:28:55.000Z","size":10762,"stargazers_count":2363,"open_issues_count":105,"forks_count":315,"subscribers_count":9,"default_branch":"master","last_synced_at":"2025-04-21T13:34:06.404Z","etag":null,"topics":["crawler","emby","jav-scraper","jellyfin","metadata","movie-crawler","movie-metadata","movie-scrapper","movies","python","scraper"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/sqzw-x.png","metadata":{"files":{"readme":"README.md","changelog":"changelog.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2023-11-06T16:46:10.000Z","updated_at":"2025-04-21T12:28:59.000Z","dependencies_parsed_at":"2023-12-20T08:58:57.684Z","dependency_job_id":"bc671e35-0807-42a9-8ec9-446242ca58f0","html_url":"https://github.com/sqzw-x/mdcx","commit_stats":{"total_commits":156,"total_committers":10,"mean_commits":15.6,"dds":0.2435897435897436,"last_synced_commit":"89e1df1992b441a83b154dcc13adec41b7794490"},"previous_names":["sqzw-x/mdcx"],"tags_count":29,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sqzw-x%2Fmdcx","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sqzw-x%2Fmdcx/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sqzw-x%2Fmdcx/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sqzw-x%2Fmdcx/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/sqzw-x","download_url":"https://codeload.github.com/sqzw-x/mdcx/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":254076330,"owners_count":22010597,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["crawler","emby","jav-scraper","jellyfin","metadata","movie-crawler","movie-metadata","movie-scrapper","movies","python","scraper"],"created_at":"2024-09-24T20:14:23.126Z","updated_at":"2025-05-14T05:00:57.461Z","avatar_url":"https://github.com/sqzw-x.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# MDCx\n\n![python](https://img.shields.io/badge/Python-3.9-3776AB.svg?style=flat\u0026logo=python\u0026logoColor=white)\n\n## 上游项目\n\n* [yoshiko2/Movie_Data_Capture](https://github.com/yoshiko2/Movie_Data_Capture): CLI 工具,\n  开源版本现已不活跃, 新版本已闭源商业化.\n* [moyy996/AVDC](https://github.com/moyy996/AVDC): 上述项目早期的一个 Fork, 使用 PyQt 实现了图形界面, 已停止维护\n* @Hermit/MDCx: AVDC 的 Fork, 一度在 [anyabc/something](https://github.com/anyabc/something/releases) 分发源代码及可执行文件.\n* 2023-11-3 @anyabc 因未知原因销号删库, 其分发的最后一个版本号为 20231014.\n\n向相关开发者表示敬意.\n\n## 关于本项目\n\n* 本项目基于 @Hermit/MDCx, 对代码进行了大幅的重构与拆分, 以提高可维护性\n* MacOS 版本为自动构建, 不保证可用性\n* 尽管重构了大部分代码, 但由于代码耦合度仍然很高, 可维护性很差, 因此仅修复 bug, 不考虑加入新功能\n* 当然如果直接 PR 也可以\n\n## 构建\n\n\u003e 一般情况请勿自行构建, 至 [Release](https://github.com/sqzw-x/mdcx/releases) 下载最新版\n\n#### Windows 7\n\nWindows 7 上需使用 Python 3.8 构建, 代码及依赖均兼容, 可在本地自行构建. 也可使用 GitHub Actions 构建:\n\n1. fork 本仓库, 在仓库设置中启用 Actions\n2. 参考 [为存储库创建配置变量](https://docs.github.com/zh/actions/learn-github-actions/variables#creating-configuration-variables-for-a-repository), 设置 `BUILD_FOR_WINDOWS_LEGACY` 变量, 值非空即可\n3. 在 Actions 中手动运行 `Build and Release`\n\n#### macOS\n\n低版本 macOS: 需注意 opencv 兼容性问题, 参考 [issue #82](https://github.com/sqzw-x/mdcx/issues/82#issuecomment-1947973961).\n也可使用 GitHub Actions 构建, 步骤同上, 需设置 `BUILD_FOR_MACOS_LEGACY` 变量, 值非空即可;\n以及 `MACOS_LEGACY_CV_VERSION` 变量, 值为兼容的 `opencv-contrib-python-headless` 版本\n\nARM64(AArch64) 架构: 可本地构建. 若欲使用 GitHub Actions 构建, 需 [添加自托管的运行器](https://docs.github.com/zh/actions/hosting-your-own-runners/managing-self-hosted-runners/adding-self-hosted-runners),\n并设置 `SELF_HOSTED_MACOS_ARM64_RUNNER` 变量\n\n## 开发\n\n### 环境准备\n- python 3.9\n- Windows 10/11\n- macOS 10.15.7+\n\n### 准备源码\n- 方式1: 下载 [仓库源码](https://github.com/sqzw-x/mdcx/archive/refs/heads/master.zip) 或 [Release源码](https://github.com/sqzw-x/mdcx/archive/refs/tags/daily_release.zip)，下载后解压\n- 方式2: git克隆项目\n  ```bash\n  git clone https://github.com/sqzw-x/mdcx.git\n  ```\n\n### 运行\n#### Windows\n\n- cmd\n```batch\ncd /d D:\\dev\\mdcx\npython -m venv venv\nvenv\\Scripts\\activate\npip install -r requirements.txt\nset PYTHONPATH=.\\src;%PYTHONPATH%\npython main.py\n```\n\n- powershell\n```powershell\ncd D:\\dev\\mdcx\npython -m venv venv\nvenv\\Scripts\\Activate.ps1\npip install -r requirements.txt\n$env:PYTHONPATH = \"./src;$env:PYTHONPATH\"\npython main.py\n```\n\n#### macOS\n\n```bash\ncd /path/to/mdcx\npython -m venv venv\nsource venv/bin/activate\npip install -r requirements-mac.txt\nexport PYTHONPATH=./src:$PYTHONPATH\npython main.py\n```\n\n### 如何添加新配置项\n\n1. 在 `config.ini.default` 中添加配置项及其默认值, 值类型可以是字符串, 整数, 浮点数\n2. 如果此值非字符串, 在 `src/models/config/config_manual.py` 中将配置键加入 `INT_KEY` 或 `FLOAT_KEY` 中\n3. 修改 `src/models/config/config_generator.py` 中的 `CONFIG_STR`, 这用于生成默认配置文件\n4. 修改 `src.models.config.config.MDCxConfig.save_config` 方法, 将新配置项加入模板字符串中, 这用于保存配置文件\n5. 运行 `src/models/config/config_generator.py`, 这将更新 `src/models/config/config_generated.py`\n6. 现在可以通过 `from models.config.config import config` 导入配置, 并通过 `config.\u003ckey\u003e` 获取对应值, 且支持 IDE 补全\n7. 按下一节所述在设置界面中添加对应的控件\n8. 修改 `src/controllers/main_window/` 目录下 `load_config.py` 及 `save_config.py`, 以实现与图形界面的交互\n\n### 如何修改图形界面\n\n* `src/views/MDCx.ui` 定义了主窗口, `src/views/posterCutTool.ui` 是图片裁剪窗口, 可使用 Qt Designer 或 Qt Creator 编辑\n* 修改后运行 `pyuic5 src\\views\\MDCx.ui -o src\\views\\MDCx.py` 生成对应的 Python 代码\n* 如需设置控件事件等, 需修改 `src.controllers.main_window.init.Init_Singal`\n* 所有事件处理函数均在 `src/controllers/main_window/main_window.py`\n\n### 代码结构说明\n\n* `src/models` 中包括全部业务逻辑, 其中:\n* `config` 目录包括配置管理相关的代码\n* `base` 目录包括基本的功能函数, 它们耦合度较低\n* `core` 包括核心功能实现, 其中 `scraper.py` 包括刮削过程的实现\n* `signals.py` 包括 Qt 信号量, 这是 MC 解耦的关键, 它也负责日志打印\n* `config` 和 `signal` 是预定义的单例, 可以在任何位置导入使用\n* `views` 和 `controllers` 结构相对简单, 可参考上文说明\n\n\n## 授权许可\n本插件项目在 GPLv3 许可授权下发行。此外，如果使用本项目表明还额外接受以下条款：\n\n- 本项目仅供学习以及技术交流使用\n- 请勿在公共社交平台上宣传此项目\n- 使用本软件时请遵守当地法律法规\n- 法律及使用后果由使用者自己承担\n- 禁止将本软件用于任何的商业用途","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsqzw-x%2Fmdcx","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsqzw-x%2Fmdcx","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsqzw-x%2Fmdcx/lists"}