Skip to content

Commit

Permalink
Merge branch 'dev' of https://github.com/Atlas-OS/Atlas into dev
Browse files Browse the repository at this point in the history
  • Loading branch information
Xyueta committed Nov 2, 2023
2 parents 8fad907 + 4fdc7c4 commit 929196c
Show file tree
Hide file tree
Showing 31 changed files with 90 additions and 40 deletions.
2 changes: 1 addition & 1 deletion .github/labeler.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,4 +30,4 @@ services:
- src/Configuration/features/atlas/services.yml

desktop folder:
- src/Executables/Atlas/**/*
- src/Executables/Atlas/**/*
5 changes: 4 additions & 1 deletion src/playbook/Configuration/custom.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,12 @@ privilege: TrustedInstaller
actions: []
tasks:
# Configure PowerShell first so that other PowerShell scripts work
# NGEN - PowerShell optimization
- tweaks\statuses\status-ngen.yml
- tweaks\scripts\script-ngen.yml
- tweaks\qol\config-powershell.yml
- atlas\start.yml
- atlas\services.yml
- atlas\components.yml
- atlas\appx.yml
- tweaks.yml
- tweaks.yml
6 changes: 1 addition & 5 deletions src/playbook/Configuration/tweaks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,6 @@ tasks:

# ----------------------- END NOTES ----------------------- #

# NGEN - PowerShell optimization
- tweaks\statuses\status-ngen.yml
- tweaks\scripts\script-ngen.yml

# -----------------------------------------------------
# Networking
# -----------------------------------------------------
Expand Down Expand Up @@ -255,11 +251,11 @@ tasks:
- tweaks\qol\shell\disable-low-disk-warning.yml
- tweaks\qol\shell\disable-menu-delay.yml
- tweaks\qol\shell\disable-network-location-wizard.yml
- tweaks\qol\shell\disable-shared-experiences.yml
- tweaks\qol\shell\set-unpinned-notification-items.yml
- tweaks\qol\shell\restore-old-context-menu.yml
- tweaks\qol\shell\show-more-pins.yml
- tweaks\qol\shell\no-recommendations-start-menu.yml
- tweaks\qol\shell\disable-nearby-sharing.yml

# -------------------------------------------------------------------------- #
# qol\startup-shutdown #
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,4 +25,4 @@ actions:
# Enable cleaning temp files
- !scheduledTask: {path: '\Microsoft\Windows\DiskCleanup\SilentCleanup', operation: enable}

# There's also subkeys for OneDrive cleanup, but as OneDrive is uninstalled, they probably aren't relevant
# There's also subkeys for OneDrive cleanup, but as OneDrive is uninstalled, they probably aren't relevant
Original file line number Diff line number Diff line change
Expand Up @@ -18,4 +18,4 @@ actions:
path: 'HKLM\SOFTWARE\Policies\Microsoft\Windows Defender Security Center\Account protection'
value: 'UILockdown'
data: '1'
type: REG_DWORD
type: REG_DWORD
Original file line number Diff line number Diff line change
Expand Up @@ -32,4 +32,4 @@ actions:
path: 'HKLM\SOFTWARE\Policies\Microsoft\Windows\DeviceInstall\Settings'
value: 'DisableSendRequestAdditionalSoftwareToWER'
data: '1'
type: REG_DWORD
type: REG_DWORD
13 changes: 13 additions & 0 deletions src/playbook/Configuration/tweaks/qol/appearance/atlas-theme.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,22 @@ actions:
exeDir: true
wait: true

# Set lockscreen
- !run:
exe: 'powershell.exe'
args: '-NoP -EP Unrestricted & "LOCKSCREEN.ps1"'
exeDir: true
runas: currentUserElevated
- !taskKill: {name: 'SystemSettings'}
- !taskKill: {name: 'control'}

# Disable fun facts, tips, tricks, and more on lockscreen
- !registryValue:
path: 'HKLM\SOFTWARE\Policies\Microsoft\Windows\Personalization'
value: 'LockScreenOverlaysDisabled'
data: '1'
type: REG_DWORD

# Windows theme
- !registryValue:
path: 'HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Themes\Personalize'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,4 +6,4 @@ actions:
- !powerShell:
command: '$pin = @(""""$env:USERPROFILE\Videos"""",""""$env:USERPROFILE\Music""""); $qa = New-Object -ComObject shell.application; ForEach ($dir in $pin) {$qa.Namespace($dir).Self.InvokeVerb(''pintohome'')}'
runas: currentUser
builds: [ '!>=22000' ]
builds: [ '!>=22000' ]
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@ description: Removes 'Extract all' from Context Menu
privilege: TrustedInstaller
actions:
- !registryKey: {path: 'HKCR\CompressedFolder\ShellEx\ContextMenuHandlers\{b8cdcb65-b1bf-4b42-9428-1dfdb7ee92af}'}
- !registryKey: {path: 'HKCR\SystemFileAssociations\.zip\ShellEx\ContextMenuHandlers\{b8cdcb65-b1bf-4b42-9428-1dfdb7ee92af}'}
- !registryKey: {path: 'HKCR\SystemFileAssociations\.zip\ShellEx\ContextMenuHandlers\{b8cdcb65-b1bf-4b42-9428-1dfdb7ee92af}'}
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,6 @@ actions:
- !registryKey: {path: 'HKCR\.bmp\ShellNew'}
- !run:
exe: 'powershell.exe'
args: '-NoP -File REMOVEBITMAP.ps1'
args: '-NoP -EP Unrestricted & "REMOVEBITMAP.ps1"'
exeDir: true
wait: true
Original file line number Diff line number Diff line change
Expand Up @@ -9,14 +9,14 @@ actions:
- !registryValue:
path: 'HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\Explorer'
value: 'SettingsPageVisibility'
data: 'hide:crossdevice;recovery;autoplay;usb;maps;maps-downloadmaps;findmydevice;privacy;privacy-speechtyping;privacy-speech;privacy-feedback;privacy-activityhistory;search-permissions;privacy-location;privacy-general;sync;printers;cortana-windowssearch;mobile-devices;mobile-devices-addphone;backup;'
data: 'hide:recovery;autoplay;usb;maps;maps-downloadmaps;findmydevice;privacy;privacy-speechtyping;privacy-speech;privacy-feedback;privacy-activityhistory;search-permissions;privacy-location;privacy-general;sync;printers;cortana-windowssearch;mobile-devices;mobile-devices-addphone;backup;'
type: REG_SZ
builds: [ '!>=22000' ]

# Windows 11
- !registryValue:
path: 'HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\Explorer'
value: 'SettingsPageVisibility'
data: 'hide:crossdevice;recovery;autoplay;usb;maps;maps-downloadmaps;findmydevice;privacy;privacy-speechtyping;privacy-speech;privacy-feedback;privacy-activityhistory;search-permissions;privacy-location;privacy-general;sync;printers;cortana-windowssearch;mobile-devices;mobile-devices-addphone;family-group;deviceusage;home;'
data: 'hide:recovery;autoplay;usb;maps;maps-downloadmaps;findmydevice;privacy;privacy-speechtyping;privacy-speech;privacy-feedback;privacy-activityhistory;search-permissions;privacy-location;privacy-general;sync;printers;cortana-windowssearch;mobile-devices;mobile-devices-addphone;family-group;deviceusage;home;'
type: REG_SZ
builds: [ '>=22000' ]
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
---
title: Disable Shared Experiences
description: Disables 'Shared Experiences', which is a way of sharing items between advices for privacy and QoL
privilege: TrustedInstaller
actions:
# https://www.elevenforum.com/t/turn-on-or-off-nearby-sharing-in-windows-11.2644/
- !registryValue:
path: 'HKCU\Software\Microsoft\Windows\CurrentVersion\CDP\SettingsPage'
value: 'BluetoothLastDisabledNearShare'
data: '0'
type: REG_DWORD
- !registryValue:
path: 'HKCU\Software\Microsoft\Windows\CurrentVersion\CDP'
value: 'NearShareChannelUserAuthzPolicy'
data: '0'
type: REG_DWORD
- !registryValue:
path: 'HKCU\Software\Microsoft\Windows\CurrentVersion\CDP'
value: 'CdpSessionUserAuthzPolicy'
data: '1'
type: REG_DWORD

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -9,4 +9,4 @@ actions:
path: 'HKLM\SYSTEM\CurrentControlSet\Control\Session Manager'
value: 'DisableWpbtExecution'
data: '1'
type: REG_DWORD
type: REG_DWORD
2 changes: 1 addition & 1 deletion src/playbook/Configuration/tweaks/scripts/script-ngen.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,5 +5,5 @@ privilege: TrustedInstaller
actions:
- !run:
exe: 'powershell.exe'
args: '-NoP -File NGEN.ps1'
args: '-NoP -EP Unrestricted -File NGEN.ps1'
exeDir: true
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@ title: Status in AME Wizard for cleaner script
description: Displays a status in AME Wizard for a specified category
privilege: TrustedInstaller
actions:
- !writeStatus: {status: 'Cleaning up'}
- !writeStatus: {status: 'Cleaning up'}
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@ title: Status in AME Wizard for the Debloating Category
description: Displays a status in AME Wizard for a specified category
privilege: TrustedInstaller
actions:
- !writeStatus: {status: 'Running debloating tweaks'}
- !writeStatus: {status: 'Running debloating tweaks'}
2 changes: 1 addition & 1 deletion src/playbook/Configuration/tweaks/statuses/status-misc.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@ title: Status in AME Wizard for the Miscellaneous Category
description: Displays a status in AME Wizard for a specified category
privilege: TrustedInstaller
actions:
- !writeStatus: {status: 'Running miscellaneous tweaks'}
- !writeStatus: {status: 'Running miscellaneous tweaks'}
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@ title: Status in AME Wizard for the Networking Category
description: Displays a status in AME Wizard for a specified category
privilege: TrustedInstaller
actions:
- !writeStatus: {status: 'Running networking tweaks'}
- !writeStatus: {status: 'Running networking tweaks'}
2 changes: 1 addition & 1 deletion src/playbook/Configuration/tweaks/statuses/status-ngen.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@ title: Status in AME Wizard for Running .NET Optimization
description: Displays a status in AME Wizard for a specified category
privilege: TrustedInstaller
actions:
- !writeStatus: {status: 'Optimizing PowerShell'}
- !writeStatus: {status: 'Optimizing PowerShell'}
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@ title: Status in AME Wizard for the Performance Category
description: Displays a status in AME Wizard for a specified category
privilege: TrustedInstaller
actions:
- !writeStatus: {status: 'Running performance tweaks'}
- !writeStatus: {status: 'Running performance tweaks'}
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@ title: Status in AME Wizard for the Privacy Category
description: Displays a status in AME Wizard for a specified category
privilege: TrustedInstaller
actions:
- !writeStatus: {status: 'Running privacy tweaks'}
- !writeStatus: {status: 'Running privacy tweaks'}
2 changes: 1 addition & 1 deletion src/playbook/Configuration/tweaks/statuses/status-qol.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@ title: Status in AME Wizard for the QoL Category
description: Displays a status in AME Wizard for a specified category
privilege: TrustedInstaller
actions:
- !writeStatus: {status: 'Running QoL tweaks'}
- !writeStatus: {status: 'Running QoL tweaks'}
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@ title: Status in AME Wizard for the Scripts Category
description: Displays a status in AME Wizard for a specified category
privilege: TrustedInstaller
actions:
- !writeStatus: {status: 'Running scripts'}
- !writeStatus: {status: 'Running scripts'}
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@ title: Status in AME Wizard for the Security Category
description: Displays a status in AME Wizard for a specified category
privilege: TrustedInstaller
actions:
- !writeStatus: {status: 'Running security tweaks'}
- !writeStatus: {status: 'Running security tweaks'}
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ function Menu {
2 {
if ($DefenderEnabled) {Menu}
Clear-Host
Write-Host "Enabling Defender...`n" -ForegroundColor Yellow
Write-Host "Enabling Defender..." -ForegroundColor Yellow
foreach ($package in $packages) {
try {
Remove-WindowsPackage -Online -PackageName $package -NoRestart -LogLevel 1 *>$null
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -181,7 +181,8 @@ Ideally don't use your computer until it's completed.

# Enable features for compatibility
Enable-WindowsOptionalFeature -Online -FeatureName "DirectPlay" -All -NoRestart
Enable-WindowsOptionalFeature -Online -FeatureName "NetFx3" -All -NoRestart
# Takes too long - also prompted to install if needed
# Enable-WindowsOptionalFeature -Online -FeatureName "NetFx3" -All -NoRestart

# Indiciate to the BitLocker section that it should be ran
Remove-Item $featureStatusIndicator -Force -EA SilentlyContinue
Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
22 changes: 22 additions & 0 deletions src/playbook/Executables/LOCKSCREEN.ps1
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
# Credit: https://superuser.com/a/1343640
$imagePath = "$env:windir\AtlasModules\Wallpapers\lockscreen.png"

$newImagePath = $(Split-Path $imagePath) + '\' + (New-Guid).Guid + [System.IO.Path]::GetExtension($imagePath)
Copy-Item $imagePath $newImagePath
[Windows.System.UserProfile.LockScreen,Windows.System.UserProfile,ContentType=WindowsRuntime] | Out-Null
Add-Type -AssemblyName System.Runtime.WindowsRuntime
$asTaskGeneric = ([System.WindowsRuntimeSystemExtensions].GetMethods() | ? { $_.Name -eq 'AsTask' -and $_.GetParameters().Count -eq 1 -and $_.GetParameters()[0].ParameterType.Name -eq 'IAsyncOperation`1' })[0]
function Await($WinRtTask, $ResultType) {
$asTask = $asTaskGeneric.MakeGenericMethod($ResultType)
$netTask = $asTask.Invoke($null, @($WinRtTask))
$netTask.Wait(-1) | Out-Null
$netTask.Result
}
function AwaitAction($WinRtAction) {
$asTask = ([System.WindowsRuntimeSystemExtensions].GetMethods() | ? { $_.Name -eq 'AsTask' -and $_.GetParameters().Count -eq 1 -and !$_.IsGenericMethod })[0]
$netTask = $asTask.Invoke($null, @($WinRtAction))
$netTask.Wait(-1) | Out-Null
}
[Windows.Storage.StorageFile,Windows.Storage,ContentType=WindowsRuntime] | Out-Null
$image = Await ([Windows.Storage.StorageFile]::GetFileFromPathAsync("$env:windir\AtlasModules\Wallpapers\lockscreen.png")) ([Windows.Storage.StorageFile])
AwaitAction ([Windows.System.UserProfile.LockScreen]::SetImageFileAsync($image))
2 changes: 1 addition & 1 deletion src/playbook/Executables/SOFTWARE.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ if ($Brave) {
} else {
Remove-Item "$tempDir" -ErrorAction SilentlyContinue -Force -Recurse
}
} until (!$processesFound)
} while ($processesFound)

Stop-Process -Name "brave" -Force -ErrorAction SilentlyContinue
exit
Expand Down
4 changes: 4 additions & 0 deletions src/playbook/Executables/THEME.cmd
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,10 @@ for /d %%a in ("%ProgramData%\Microsoft\Windows\SystemData\*") do (
)
)

:: set default lockscreen
:: https://admx.help/?Category=Windows_11_2022&Policy=Microsoft.Policies.ControlPanelDisplay::CPL_Personalization_ForceDefaultLockScreen
reg add "HKLM\Software\Policies\Microsoft\Windows\Personalization" /v LockScreenImage /t REG_SZ /d "%windir%\AtlasModules\Wallpapers\lockscreen.png" /f

exit /b

:ALLUSERS
Expand Down

0 comments on commit 929196c

Please sign in to comment.