mirror of
https://github.com/PowerShell/PowerShell
synced 2026-06-08 12:12:50 +00:00
Context caps
This commit is contained in:
@@ -9,7 +9,7 @@ This is accomplished by parsing the output of an existing command, *parted -l* i
|
||||
|
||||
```PowerShell
|
||||
Function Get-DiskInfo {
|
||||
$disks = sudo parted -l | Select-String "Disk /dev/sd*" -context 1,0
|
||||
$disks = sudo parted -l | Select-String "Disk /dev/sd*" -Context 1,0
|
||||
$diskinfo = @()
|
||||
foreach ($disk in $disks) {
|
||||
$diskline1 = $disk.ToString().Split("`n")[0].ToString().Replace(' Model: ','')
|
||||
|
||||
Reference in New Issue
Block a user