Skip to content

Commit

Permalink
Updated init script
Browse files Browse the repository at this point in the history
  • Loading branch information
lexiismadd committed Nov 24, 2022
1 parent 5f2d257 commit 455aaac
Showing 1 changed file with 7 additions and 4 deletions.
11 changes: 7 additions & 4 deletions Standard-CT-Module/CT-PS-Standard.psm1
Original file line number Diff line number Diff line change
Expand Up @@ -25,12 +25,15 @@ function Initialize-Script {
It starts transcript to the transcript log file so the history can be accessed anytime in the future
The script then tests for the CT_DEST folder and creates it if its not there.
This needs to be imported to a script by using the following two commands:
This needs to be imported to a script by using the following set of commands:
Invoke-WebRequest -uri "https://raw.githubusercontent.com/alexisspencer/ct_store/main/Standard-CT-Module/CT-PS-Standard.psm1" -OutFile "$($PSScriptRoot)\CT-PS-Standard.psm1" -Verbose:$VerbosePreference -Debug:$DebugPreference
--------
[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12
if(Test-Path -Path "$($PSScriptRoot)\CT-PS-Standard.psm1" -PathType Leaf ) { Remove-Item "$($PSScriptRoot)\CT-PS-Standard.psm1" -Force }
Invoke-WebRequest -uri "https://raw.githubusercontent.com/alexisspencer/ct_store/main/Standard-CT-Module/CT-PS-Standard.psm1" -OutFile "$($PSScriptRoot)\CT-PS-Standard.psm1" -UseBasicParsing -Verbose:$VerbosePreference -Debug:$DebugPreference #-SkipCertificateCheck
Import-Module -Name "$($PSScriptRoot)\CT-PS-Standard.psm1" -Force -Verbose:$VerbosePreference -Debug:$DebugPreference
Then trigger the function "Initialize-Script" at the start of your script
Initialize-Script
--------
#>

Expand Down

0 comments on commit 455aaac

Please sign in to comment.