added new Output directory to root MSP directory

moved InstalledSoftware.csv to new Output directory and added date stamp to filename
This commit is contained in:
2021-07-26 13:22:21 -04:00
parent eb93ecb075
commit cad054685a
2 changed files with 3 additions and 1 deletions
+2 -1
View File
@@ -1,5 +1,6 @@
## Specify output file to write data to
$FILE = "${Env:UserProfile}\Desktop\InstalledSoftware.csv"
$CurrentDateTime = Get-Date -Format "yyyyMMddHHmmssffff"
$FILE = "${OutputDirectory}\${CurrentDateTime}_InstalledSoftware.csv"
## Clear content of output file
If ( Test-Path $FILE ) { Clear-Content -Path $FILE -Force }
+1
View File
@@ -4,6 +4,7 @@ $MSPName = "Emberkom"
## Setup the MSP management directories
If ( Test-Path ${Env:ProgramData} ) {$RootDirectory = "${Env:ProgramData}\${MSPName}" } Else { $RootDirectory = "${Env:SystemDrive}\${MSPName}" }
$ScriptsDirectory = "${RootDirectory}\Scripts"
$OutputDirectory = "${RootDirectory}\Output"
$ToolsDirectory = "${RootDirectory}\Tools"
$LogsDirectory = "${RootDirectory}\Logs"