Moved logs to subfolder.
Moved creating wDayzManager logs to subfolder.
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
# wDayzManager v0.2
|
||||
# wDayzManager v0.3
|
||||
# Copyright (c) 2024 Vladislav Salikov aka W0LF aka 'dreamforce'
|
||||
# https://github.com/dreamforceinc
|
||||
# Required module: PSIni
|
||||
@@ -229,7 +229,7 @@ if ($rotateLogs) {
|
||||
|
||||
Write-Host "Removing old wDayzManager logs..."
|
||||
$fileList = $null
|
||||
$fileList = Get-ChildItem -Path $currentPath\*.log -Recurse | Where-Object { $_.LastWriteTime.Date -lt $date.AddDays( -3) }
|
||||
$fileList = Get-ChildItem -Path $currentPath\Logs\*.log -Recurse | Where-Object { $_.LastWriteTime.Date -lt $date.AddDays( -3) }
|
||||
# Write-Host $fileList -Separator "`n"
|
||||
foreach ($file in $fileList) {
|
||||
Remove-Item -Path $file
|
||||
|
||||
Reference in New Issue
Block a user