Powershell Core 6.2 Cookbook
上QQ阅读APP看书,第一时间看更新

There's more...

Scoping can lead to some issues when not taken care of, for example, with dot-sourcing. Dot-sourcing a script with . 'Full Script Path.ps1' will mean that the entire script with all of its contents will be imported into your current scope. However, this also means that the script might overwrite your variables, aliases, functions, cmdlets, and so on.