PowerShell: Manage PowerShell Profiles
Split Function Definitions in PowerShell Profile into Several Files
if you have a lot PowerShell functions in your Profile (init file), you can organize them by splitting into different files of function definitions.
For example, in your profile file, add
# load PowerShell scripts @( "file_util.ps1", "windows_util.ps1", "personal.ps1" ) | ForEach-Object { . (Join-Path (Split-Path -Parent $PSCommandPath ) $_ ) }
PowerShell: Profile and Script
- PowerShell: Open File by Default App
- PowerShell: Launch App, Start Process
- PowerShell: Load a Script
- PowerShell: Eval Variable, String, ScriptBlock
- PowerShell: Profile (init file)
- PowerShell: Manage PowerShell Profiles
- PowerShell: Create a Script
- PowerShell: File Name Extension
- PowerShell: Get Current Script Path