Powershell Tips, and examples
Enabling, and using SSH with Powershell
https://docs.microsoft.com/en-us/windows-server/administration/openssh/openssh_install_firstuse
One quirk with using OpenSSH Server via Windows is that the authorized_keys file is used only for standard users. If the user you are trying to connect with is an admin, you have to use the administrator_authorized_keys file in ProgramData/ssh/ - https://docs.microsoft.com/en-us/windows-server/administration/openssh/openssh_server_configuration
Using vim as your editor in the command line
https://codeandkeep.com/PowerShell-And-Vim/
Install the windows vim application Create a powershell profile - https://www.howtogeek.com/50236/customizing-your-powershell-profile/ (note you may have an issue with creating a profile, Powershell may complain about restricting the use of running scripts. See here - thewindowsclub.com/powershell-file-cannot-be-loaded-because-running-scripts-is-disabled-on-this-system) Add these alias lines inside the profile:
New-Alias -Name vim -Value 'C:\Program Files (x86)\Vim\vim82\vim.exe' New-Alias -Name vi -Value 'C:\Program Files (x86)\Vim\vim82\vim.exe'
More on profile locations - https://docs.microsoft.com/en-us/powershell/module/microsoft.powershell.core/about/about_profiles?view=powershell-7.2
Restart your session for the changes to take effect.
Making Powershell look pretty
Message box pop-ups
Input Box pop-up
Open up a file browser to pick a path
- (I like this one the best, very redundant for normal users) https://code.adonline.id.au/folder-file-browser-dialogues-powershell/