{"id":21202206,"url":"https://github.com/shthemw/list-format-updater","last_synced_at":"2025-03-14T22:27:07.499Z","repository":{"id":213472279,"uuid":"734187516","full_name":"SHthemW/List-Format-Updater","owner":"SHthemW","description":"列表类型数据专用更新工具","archived":false,"fork":false,"pushed_at":"2023-12-21T05:52:27.000Z","size":6,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-01-21T15:09:23.433Z","etag":null,"topics":[],"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/SHthemW.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}},"created_at":"2023-12-21T04:44:46.000Z","updated_at":"2023-12-21T05:52:55.000Z","dependencies_parsed_at":"2023-12-21T08:30:46.378Z","dependency_job_id":"cf4c6214-8695-4d38-9a03-96ded52e0856","html_url":"https://github.com/SHthemW/List-Format-Updater","commit_stats":null,"previous_names":["shthemw/xlsx-format-updater"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SHthemW%2FList-Format-Updater","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SHthemW%2FList-Format-Updater/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SHthemW%2FList-Format-Updater/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SHthemW%2FList-Format-Updater/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/SHthemW","download_url":"https://codeload.github.com/SHthemW/List-Format-Updater/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243654826,"owners_count":20325965,"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":[],"created_at":"2024-11-20T20:14:57.237Z","updated_at":"2025-03-14T22:27:07.477Z","avatar_url":"https://github.com/SHthemW.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# List Format Updater Document\nList Format Updater (LsFU)能够对剪贴板内的列表进行批量格式化处理:\n\n    [1, 10, 2, 30]                                                         [1, 10, 2, 30] \n    [1, 11, 2, 32]  =\u003e 令范围(2, 3)内的[第2个元素 + 10], [第4个元素 + 1] =\u003e  [1, 21*, 2, 33*]\n    [1, 12, 2, 34]                                                         [1, 32*, 2, 35*]  \n\n所有数值操作均在剪贴板上进行, 因此最大程度的保护了原始数据的安全性.  \n程序具有一定的错误处理功能, 但时间所限可能并不完善..  \n请勿调戏未成年代码!  \n\n## 环境:\n- Python 3.8及以上\n- 需要的库: colorama, pyperclip\n\u003e 在Windows-cmd中使用以下命令安装:\n\n    pip install colorama  \n    pip install pyperclip\n\n## 快速开始:\n\n- 直接clone项目到本地.\n- 运行`startup.bat`. 若出现闪退, 请检查环境是否配置正确\n\nLsFU是命令交互式的程序, 你将依次看到以下命令:  \n\n### input command:\n程序进入时的界面. 可输入以下命令:  \n\n- `get`: 识别剪贴板上的列表并打印. 进入程序的下一步.\n- `exit`: 退出程序\n\n注意: \n- 程序能识别的列表格式为`[,,,]`, 行与行间用换行符分割.\n\n### input scope:\n输入希望修改的行的范围. 范围索引将在上一步打印时显示.  \n\u003e 如: 希望修改第21-41行的数据, 可输入:\n \n    21 41\n    \n此外, 支持首尾匹配字符`-`.  \n\u003e 如: 希望修改第61行到最后一行的数据, 可输入:\n \n    61 -\n\n\u003e 希望修改首行到第21行的数据, 可输入:  \n\n    - 21\n\n### input index:\n输入每行中希望修改的索引(索引从1开始). 支持多个索引, 用空格分隔.  \n\u003e 如:\n\n    2 4 6\n\n\u003e 表示匹配`[1, 10, 2, 20, 3, 30]`中的`10 20 30`字段.\n\n注意:\n- 如果输入的索引在当前行不存在, 则会新建该索引, 值为下一步中输入的值.  \n\n\n### input changes on XXX:\n\n输入对于当前的每个索引, 你希望改变的值.  \n\u003e 如, 假设上一步中选择的值是\n\n    10 20 30  \n\n\u003e 此时, 输入\n\n    50 10 30  \n\n\u003e 表示对所选择的三个索引对应的值分别+50, +10, +30, \n\u003e 最终会得到:\n\n    60 30 60\n\n注意:\n- 如果所选的索引不存在, 则会分别新建值为50 10 30的新索引.\n- 这一步的输入数量必须和上一步的索引数量匹配.\n\n特别地, 若输入-1, 则表示删除对应的索引.\n\u003e 如, 输入\n\n    50 10 -1\n\n\u003e 最终会得到:\n\n    60 30\n\n注意:\n- 程序支持负数, 表示减去对应的值. 但-1是特别的, 表示删除这个索引.\n\n\n### process:\n\n现在, 程序将开始对每个所选择的索引进行批量操作. 每处理一个索引, 程序将会打印一次state, 并高亮显示本次修改后的索引.  \n\n\n### apply:\n\n处理完成后, 程序会询问是否应用这次修改.  \n检查无误后, 输入`y`, 程序即用处理后的数据覆盖到剪贴板中. 此时可将剪贴板内的数据粘贴到excel, 或其它文件中. 所有的列表格式字符(如[] ,)等都会保留.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fshthemw%2Flist-format-updater","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fshthemw%2Flist-format-updater","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fshthemw%2Flist-format-updater/lists"}