notes/os/shells/pwsh/feature/startup-autoload.txt
Ihar Hancharenka 5dff80e88e first
2023-03-27 16:52:17 +03:00

11 строки
370 B
Plaintext

startup
https://github.com/PowerShell/PowerShell/issues/1190
#Add this to C:\Users\%username%\Documents\WindowsPowerShell\Microsoft.PowerShell_profile.ps1
# directory where my scripts are stored
$psdir="D:\Documents\Powershell\Scripts\autoload"
# load all 'autoload' scripts
Get-ChildItem "${psdir}\*.ps1" | %{.$_}
Write-Host "Custom PowerShell Environment Loaded"