{"id":15995805,"url":"https://github.com/jm199504/sclog","last_synced_at":"2025-04-05T00:43:13.702Z","repository":{"id":247615094,"uuid":"826359705","full_name":"jm199504/sclog","owner":"jm199504","description":"安卓设备录屏日志工具（scrcpy log）","archived":false,"fork":false,"pushed_at":"2024-07-09T14:58:58.000Z","size":7,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-02-10T09:12:27.131Z","etag":null,"topics":["adb","android-log","android-testing","scrcpy-android"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/jm199504.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"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}},"created_at":"2024-07-09T14:57:51.000Z","updated_at":"2024-07-10T08:35:33.000Z","dependencies_parsed_at":"2024-07-09T19:06:06.459Z","dependency_job_id":"910c8295-5d90-4605-90c2-0401bad1ba9c","html_url":"https://github.com/jm199504/sclog","commit_stats":null,"previous_names":["jm199504/sclog"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jm199504%2Fsclog","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jm199504%2Fsclog/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jm199504%2Fsclog/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jm199504%2Fsclog/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/jm199504","download_url":"https://codeload.github.com/jm199504/sclog/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247271489,"owners_count":20911586,"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":["adb","android-log","android-testing","scrcpy-android"],"created_at":"2024-10-08T07:21:16.354Z","updated_at":"2025-04-05T00:43:13.679Z","avatar_url":"https://github.com/jm199504.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"### sclog（scrcpy log）安卓设备录屏日志工具\n\n#### 1. 安装引导\n\n该工具可通过下载源码后，在`sclog/dist`目录下执行以下命令安装：\n\n```\npip3 install sclog-1.0.tar.gz\n```\n\n安装输入输出，若显示`Successfully installed sclog-1.0`表示安装成功：\n\n```cmd\n➜  dist pip3 install sclog-1.0.tar.gz \nProcessing ./sclog-1.0.tar.gz\n  Preparing metadata (setup.py) ... done\nInstalling collected packages: sclog\n  DEPRECATION: sclog is being installed using the legacy 'setup.py install' method, because it does not have a 'pyproject.toml' and the 'wheel' package is not installed. pip 23.1 will enforce this behaviour change. A possible replacement is to enable the '--use-pep517' option. Discussion can be found at https://github.com/pypa/pip/issues/8559\n  Running setup.py install for sclog ... done\nSuccessfully installed sclog-1.0\n\n```\n\n\n\n#### 2. 使用介绍\n\n该工具主要应用于安卓车机进行debug调试时，发现了error/crash时，考虑复现对车机录屏和日志抓取功能，并将日志和录屏文件进行打包压缩，复现前打开cmd终端输入`sclog`即可运行该脚本。\n\n\n\n#### 3. 主函数（功能）介绍\n\n```python\ndef main():\n    timestamp = datetime.now().strftime(\"%Y-%m-%d_%H-%M-%S\")\n    logcat_filename = \"logcat_{}.log\".format(timestamp)\n    output_filename = \"video_{}.mp4\".format(timestamp)\n    zip_filename = \"logs_and_screen_{}.zip\".format(timestamp)\n\n    record_screen(logcat_filename, output_filename)\n    create_zip(logcat_filename, output_filename, zip_filename)\n\n```\n\n（1）获取当前时间\n\n（2）在当前目录创建`logcat_{当前时间}.log`日志文件\n\n（3）在当前目录创建`video_{当前时间}.mp4`录屏文件\n\n（4）将日志文件和录屏文件压缩至`logs_and_screen_{当前时间}.zip`压缩文件\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjm199504%2Fsclog","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjm199504%2Fsclog","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjm199504%2Fsclog/lists"}