Upload files to "Get Scripts"
This commit is contained in:
@@ -0,0 +1,20 @@
|
||||
<#
|
||||
Author: Gabe Kerntke
|
||||
Company: UFS LLC
|
||||
Date: 12-05-2024
|
||||
|
||||
.Synopsis
|
||||
|
||||
.Modified
|
||||
2024-12-05 (GabeK) - Original script created
|
||||
|
||||
#>
|
||||
|
||||
#Region Start Script
|
||||
If($args.count -eq 0) { $Computer = "." }
|
||||
Else { $Computer = $args[0] }
|
||||
|
||||
$LastBootTime = (Get-WmiObject Win32_OperatingSystem -ComputerName $Computer ).LastBootUpTime
|
||||
$UpTime = (New-TimeSpan ([System.Management.ManagementDateTimeconverter]::ToDateTime($LastBootTime)) (Get-Date) | Select-Object -ExpandProperty Days)
|
||||
$UpTime
|
||||
#Region End Script
|
||||
Reference in New Issue
Block a user