powershell 必备三件套的安装
前言
很多年前刚开始摸索编程的时候,还是很鄙视 powershell 等等这些微软的东西的。可以说是有些刻板印象。
但是做码农时间长了,只会觉得当年的自己太过幼稚。能干活就行,考虑那么多价值观干嘛。特别是最近几年微软拥抱开源,对微软的印象是越来越好了,对 Google 反而越来越差,不好好做 flutter。
熟悉 linux 的都知道,zsh,oh my zsh,fish 等等 shell 或者脚本可以说是大大提高了命令行操作的便利。那 Windows 下是否有类似的东西呢?当然有了。本文就介绍一下必备的一些组件(自动补全,高亮,z)。实际上 powershell 非常强大,这些只是冰山一角,powershell 可是自带了 .net 内核的。
其实是自己每次换电脑就忘记,每次都要重新找一遍。这次干脆记录一下。
PSReadLine
https://github.com/PowerShell/PSReadLine
Install-Module -Name PowerShellGet -Force; exit
Install-Module PSReadLine -Repository PSGallery -Scope CurrentUser -Force
Oh My Posh
winget install JanDeDobbeleer.OhMyPosh --source winget --scope user --force
z jump
https://github.com/vors/ZLocation
Install-Module ZLocation -Scope CurrentUser