Skip to content

Commit

Permalink
Merge pull request #156 from HotCakeX/Improved-visual-spacing-of-Opti…
Browse files Browse the repository at this point in the history
…onal-Windows-Features-category

Improved visual spacing of Optional Windows Features category
  • Loading branch information
HotCakeX authored Nov 18, 2023
2 parents 2302018 + fb29d3a commit a4cf279
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -1959,7 +1959,7 @@ IMPORTANT: Make sure to keep it in a safe place, e.g., in OneDrive's Personal Va
powershell.exe {

# Enable Windows Sandbox
Write-Host 'Enabling Windows Sandbox' -ForegroundColor Yellow
Write-Host "`nEnabling Windows Sandbox" -ForegroundColor Yellow
if ((Get-WindowsOptionalFeature -Online -FeatureName Containers-DisposableClientVM).state -eq 'disabled') {
try {
Enable-WindowsOptionalFeature -Online -FeatureName Containers-DisposableClientVM -All -NoRestart -ErrorAction Stop
Expand Down Expand Up @@ -2110,10 +2110,9 @@ IMPORTANT: Make sure to keep it in a safe place, e.g., in OneDrive's Personal Va
}

powershell.exe {
# The first Write-host after PowerShell.exe script block doesn't need the extra `n because it automatically has an extra new line


# Uninstall Steps Recorder
Write-Host 'Uninstalling Steps Recorder' -ForegroundColor Yellow
Write-Host "`nUninstalling Steps Recorder" -ForegroundColor Yellow
if ((Get-WindowsCapability -Online | Where-Object { $_.Name -like '*App.StepsRecorder*' }).state -ne 'NotPresent') {
try {
Get-WindowsCapability -Online | Where-Object { $_.Name -like '*App.StepsRecorder*' } | Remove-WindowsCapability -Online -ErrorAction Stop
Expand Down
7 changes: 3 additions & 4 deletions Harden-Windows-Security.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -1959,7 +1959,7 @@ IMPORTANT: Make sure to keep it in a safe place, e.g., in OneDrive's Personal Va
powershell.exe {

# Enable Windows Sandbox
Write-Host 'Enabling Windows Sandbox' -ForegroundColor Yellow
Write-Host "`nEnabling Windows Sandbox" -ForegroundColor Yellow
if ((Get-WindowsOptionalFeature -Online -FeatureName Containers-DisposableClientVM).state -eq 'disabled') {
try {
Enable-WindowsOptionalFeature -Online -FeatureName Containers-DisposableClientVM -All -NoRestart -ErrorAction Stop
Expand Down Expand Up @@ -2110,10 +2110,9 @@ IMPORTANT: Make sure to keep it in a safe place, e.g., in OneDrive's Personal Va
}

powershell.exe {
# The first Write-host after PowerShell.exe script block doesn't need the extra `n because it automatically has an extra new line


# Uninstall Steps Recorder
Write-Host 'Uninstalling Steps Recorder' -ForegroundColor Yellow
Write-Host "`nUninstalling Steps Recorder" -ForegroundColor Yellow
if ((Get-WindowsCapability -Online | Where-Object { $_.Name -like '*App.StepsRecorder*' }).state -ne 'NotPresent') {
try {
Get-WindowsCapability -Online | Where-Object { $_.Name -like '*App.StepsRecorder*' } | Remove-WindowsCapability -Online -ErrorAction Stop
Expand Down

0 comments on commit a4cf279

Please sign in to comment.