{"id":31626366,"url":"https://github.com/jy-eggroll/my-powershell","last_synced_at":"2025-10-06T19:51:35.648Z","repository":{"id":316678240,"uuid":"1064410710","full_name":"Jy-EggRoll/my-powershell","owner":"Jy-EggRoll","description":"这是一个由我自己编写的 PowerShell 脚本集，用于实现一些常用功能，如电池健康度监测、功率监测、清理指定 PowerShell 历史记录、创建软硬链接等 | This is a collection of PowerShell scripts I wrote myself, used to implement some common functions such as battery health monitoring, power monitoring, cleaning specified PowerShell history, creating soft and hard links, etc","archived":false,"fork":false,"pushed_at":"2025-09-26T03:56:58.000Z","size":19,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-09-26T04:08:57.872Z","etag":null,"topics":["powershell"],"latest_commit_sha":null,"homepage":"","language":"PowerShell","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/Jy-EggRoll.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,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2025-09-26T02:00:38.000Z","updated_at":"2025-09-26T03:56:52.000Z","dependencies_parsed_at":"2025-09-26T04:09:04.322Z","dependency_job_id":"efb6eaec-56ff-45d8-8bef-85467be19c72","html_url":"https://github.com/Jy-EggRoll/my-powershell","commit_stats":null,"previous_names":["jy-eggroll/my-powershell"],"tags_count":9,"template":false,"template_full_name":null,"purl":"pkg:github/Jy-EggRoll/my-powershell","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Jy-EggRoll%2Fmy-powershell","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Jy-EggRoll%2Fmy-powershell/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Jy-EggRoll%2Fmy-powershell/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Jy-EggRoll%2Fmy-powershell/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Jy-EggRoll","download_url":"https://codeload.github.com/Jy-EggRoll/my-powershell/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Jy-EggRoll%2Fmy-powershell/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":278671749,"owners_count":26025743,"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","status":"online","status_checked_at":"2025-10-06T02:00:05.630Z","response_time":65,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":["powershell"],"created_at":"2025-10-06T19:51:31.400Z","updated_at":"2025-10-06T19:51:35.642Z","avatar_url":"https://github.com/Jy-EggRoll.png","language":"PowerShell","funding_links":[],"categories":[],"sub_categories":[],"readme":"# PowerShell 功能集成\n\n## 介绍\n\n这是一个由我自己编写的 PowerShell 脚本集，用于实现一些常用功能，如电池健康度监测、功率监测、清理指定 PowerShell 历史记录、创建软硬链接等。\n\n## 发布说明\n\n我更推荐您直接运行 PowerShell 脚本，即下载 Release 中的源代码，这保证了最佳的兼容性和灵活性。\n\n不过，我仍然保留构建 exe 可执行文件的功能，并将其发布在 Release 中，供有需要的用户下载使用。这是由于如果您未安装 PowerShell7 环境，直接运行 ps1 脚本是会被禁止的（除非您修改执行策略），这为用户带来了额外的障碍。\n\n\u003e [!WARNING]\n\u003e\n\u003e v0 版本全部不稳定，仅作发布测试，请勿下载使用。\n\u003e\n\u003e ARM64 版本的实际架构仍为 x64，但是打包环境是 Windows on ARM，这可能会提升一些兼容性。如果您追求在 ARM 设备上运行的原生性，那么请用原生的 PowerShell 运行 ps1 脚本。\n\n## 使用方法\n\n### PowerShell7 用户\n\n如果您的电脑上安装有 PowerShell7，那么使用 ps1 脚本是最好的选择。用法如下：\n\n进入脚本所在目录，在该目录打开 PowerShell7，运行：\n\n```powershell\n.\\Get-BatteryInfo.ps1  # 获取电池信息：设计容量、实际容量、健康度、电量\n.\\Get-BatteryInfo.ps1 -Monitor  # 实时监测功率\n.\\Get-BatteryInfo.ps1 -Bluetooth  # 获取已连接的蓝牙设备的电量\n.\\Get-BatteryInfo.ps1 -RefreshBluetoothCache  # 刷新已配对的蓝牙设备的缓存文件\n\n.\\Clear-SpecifiedHistory.ps1 -Like \"\"  # 清理指定 PowerShell 历史记录，使用 * 匹配\n```\n\n### PowerShell5 用户\n\n如果您不想修改 PowerShell5 的脚本执行策略，请下载相应架构的 exe 可执行文件，在命令行中运行。用法如下：\n\n进入 exe 所在目录，在该目录打开命令行，运行：\n\n```powershell\n.\\Get-BatteryInfo-x64.exe  # 获取电池信息：设计容量、实际容量、健康度、电量\n.\\Get-BatteryInfo-x64.exe -Monitor  # 实时监测功率\n.\\Get-BatteryInfo-x64.exe -Bluetooth  # 获取已连接的蓝牙设备\n.\\Get-BatteryInfo-x64.exe -RefreshBluetoothCache  # 刷新已配对的蓝牙设备的缓存文件\n\n.\\Clear-SpecifiedHistory-x64.exe -Like \"\"  # 清理指定 PowerShell 历史记录，使用 * 匹配\n```\n\n如果您不愿在命令行中输入文件名，可以考虑创建快捷方式。如果您使用快捷方式运行 exe 文件时出现了运行结束后窗口马上退出的问题，请在快捷方式绑定的命令后面加上 `-wait` 参数，这样就可以通过双击来运行对应的文件了。\n\n## 建议\n\n文件名较长，您可以设置 PowerShell 别名。\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjy-eggroll%2Fmy-powershell","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjy-eggroll%2Fmy-powershell","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjy-eggroll%2Fmy-powershell/lists"}