1、以管理员权限打开 PowerShell
2、输入 Install-Module -Name windows-screenfetch,回车(输入Y,接受)
3、输入 Set-ExecutionPolicy -ExecutionPolicy Unrestricted,回车(输入Y,接受)
4、输入 Import-Module windows-screenfetch
5、成功。输入 Screenfetch 测试!
来自 <Windows10 安装 Screenfetch - 程序员大本营>
1、开启PowerShell自动运行脚本
2、使用管理员身份运行 Windows PowerShell ISE
3、新建脚本 profile.ps1
4、内容填写:Screenfetch
5、保存
- %windir%\system32\WindowsPowerShell\v1.0\profile.ps1
此配置文件适用于所有用户和所有外壳。 - %windir%\system32\WindowsPowerShell\v1.0\Microsoft.PowerShell_profile.ps1
此配置文件适用于所有用户,但仅适用于Microsoft.PowerShell Shell。 - %UserProfile%\My Documents\WindowsPowerShell\profile.ps1
此配置文件仅适用于当前用户,但会影响所有外壳程序。 - %UserProfile%\My Documents\WindowsPowerShell\Microsoft.PowerShell_profile.ps1
此配置文件仅适用于当前用户和Microsoft.PowerShell Shell。
最终效果
参考文档: