-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathQuickModuleCLI.psm1
More file actions
25 lines (22 loc) · 1019 Bytes
/
QuickModuleCLI.psm1
File metadata and controls
25 lines (22 loc) · 1019 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
. "$PSScriptRoot\Private\Variables.ps1"
. "$PSScriptRoot\Private\UI.ps1"
. "$PSScriptRoot\Private\Environment.ps1"
. "$PSScriptRoot\Private\ArgumentCompleters.ps1"
. "$PSScriptRoot\Private\ArgumentTransformations.ps1"
. "$PSScriptRoot\Private\ObjectTransformation.ps1"
. "$PSScriptRoot\Private\Validators.Exceptions.ps1"
. "$PSScriptRoot\Private\Validators.ps1"
$helperFunctions = Get-ChildItem "$PSScriptRoot\Public" -Filter "*.ps1"
foreach($helperFunction in $helperFunctions) {
if (!$helperFunction.BaseName.EndsWith('.Tests')) {
. "$PSScriptRoot\Public\$helperFunction"
}
}
if (!(Test-Path "$PSScriptRoot\Modules")) {
New-Item "$PSScriptRoot\Modules" -ItemType Directory
}
foreach($Module in (Get-ValidModuleProjects)) {
Import-Module "$($Module.FullName)\$($Module.Name).psd1" -Force -Global
}
#In theory this will not change the Global Error Action Preference, but will scope this action preference to all of the Module Functions.
$ErrorActionPreference = "Stop"