-
Notifications
You must be signed in to change notification settings - Fork 7
/
Copy pathws1_sample_start.ps1
executable file
·28 lines (20 loc) · 1.03 KB
/
ws1_sample_start.ps1
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
26
27
28
<#
Clear Powershell $error Logging. This is most useful for debugging purposes as only the errors from the previous script will show up.
Of course you must press ctrl+c to exit before they are cleared.
This entire thing be discarded. It would be much cleaner to have a start-ws1ToolBox cmdlet, that imports the modules and automatically launches the select-ws1config cmdlet
#>
$error.clear()
###Clear the Screen
clear-host
$ws1Functions = "PowerShell_Functions"
$ws1Modules = Get-ChildItem -file -Name *.psm1 $ws1Functions -Recurse
foreach ($ws1Module in $ws1Modules) {
$ws1Import = "{0}\{1}\{2}" -f $PSScriptRoot,$ws1Functions,$ws1Module
Import-Module $ws1Import -Force
write-host "Importing 3rd-party Tools module: " $ws1Module
}
###Setting up folder structure
get-ws1Folders
###Set TLS version
[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12
write-host -ForegroundColor Cyan 'use the following command to get started: $headers = select-ws1Config'