Skip to content

Commit 0a34b14

Browse files
committed
Merge upstream new-update into fix/new-user-profile-reset-rerun
Resolves merge conflict in src/playbook/Executables/AtlasModules/Scripts/newUsers.ps1 by keeping the PR branch version which includes all upstream changes plus the per-SID guard additions to prevent re-running after a Windows profile reset.
2 parents 461732b + eaadb64 commit 0a34b14

20 files changed

Lines changed: 582 additions & 276 deletions

File tree

.github/ISSUE_TEMPLATE/bug_report.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,8 +57,8 @@ body:
5757
label: Atlas Version
5858
description: 'If you''re on v0.4.0, see the workarounds page first: https://github.com/orgs/Atlas-OS/projects/7/views/5'
5959
options:
60-
- Atlas v0.5.0 for Windows 10 22H2
6160
- Atlas v0.5.0 for Windows 11 24H2
61+
- Atlas v0.5.0 for Windows 11 25H2
6262
validations:
6363
required: true
6464

.github/dependabot.yml

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
version: 2
2+
updates:
3+
- package-ecosystem: "github-actions"
4+
directory: "/"
5+
schedule:
6+
interval: "weekly"
7+
groups:
8+
actions:
9+
patterns:
10+
- "actions/*"
11+
tj-actions:
12+
patterns:
13+
- "tj-actions/*"
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
@{
2+
Severity = @('Error', 'Warning')
3+
4+
ExcludeRules = @(
5+
# Atlas scripts use Write-Host intentionally for colored playbook output
6+
'PSAvoidUsingWriteHost',
7+
# Positional parameters are common in short Atlas helper calls
8+
'PSAvoidUsingPositionalParameters',
9+
# Internal Atlas scripts are not published cmdlets; ShouldProcess is not applicable
10+
'PSUseShouldProcessForStateChangingFunctions',
11+
# Internal function names do not need to follow module-publishing conventions
12+
'PSUseSingularNouns',
13+
# InstallSoftware.ps1 uses global vars intentionally for its progress display state machine
14+
'PSAvoidGlobalVars',
15+
# BOM handling is a per-file encoding decision, not enforced project-wide
16+
'PSUseBOMForUnicodeEncodedFile',
17+
# Script-level params used inside nested functions trigger a false positive in PSSA
18+
'PSReviewUnusedParameter'
19+
)
20+
}

.github/workflows/apbx.yaml

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,8 @@ jobs:
2424

2525
steps:
2626
- name: Checkout code
27-
uses: actions/checkout@v6
27+
# gh api repos/actions/checkout/commits/v6 --jq '.sha'
28+
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6
2829
with:
2930
ref: ${{ github.event_name == 'workflow_dispatch' && github.event.inputs.branch || github.ref }}
3031
token: ${{ secrets.RUNNER_SECRET }}
@@ -34,7 +35,8 @@ jobs:
3435

3536
- name: Get changed files
3637
id: changed-files
37-
uses: tj-actions/changed-files@v47.0.4
38+
# gh api repos/tj-actions/changed-files/commits/v47.0.4 --jq '.sha'
39+
uses: tj-actions/changed-files@7dee1b0c1557f278e5c7dc244927139d78c0e22a # v47.0.4
3840
with:
3941
files_yaml: |
4042
sxsc:
@@ -136,7 +138,8 @@ jobs:
136138
working-directory: src\playbook
137139

138140
- name: Upload artifact
139-
uses: actions/upload-artifact@v7.0.0
141+
# gh api repos/actions/upload-artifact/commits/v7.0.0 --jq '.sha'
142+
uses: actions/upload-artifact@bbbca2ddaa5d8feaa63e36b76fdaad77386f024f # v7.0.0
140143
if: ${{ steps.create-pb.outcome != 'skipped' }}
141144
with:
142145
name: Atlas Playbook

.github/workflows/labeler.yaml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,4 +10,5 @@ jobs:
1010
pull-requests: write
1111
runs-on: ubuntu-latest
1212
steps:
13-
- uses: actions/labeler@v6.0.1
13+
# gh api repos/actions/labeler/commits/v6.0.1 --jq '.sha'
14+
- uses: actions/labeler@634933edcd8ababfe52f92936142cc22ac488b1b # v6.0.1
Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
name: Lint PowerShell
2+
3+
on:
4+
push:
5+
paths:
6+
- "src/**/*.ps1"
7+
- "src/**/*.psm1"
8+
- ".github/linters/PSScriptAnalyzerSettings.psd1"
9+
- ".github/workflows/lint-powershell.yml"
10+
pull_request:
11+
paths:
12+
- "src/**/*.ps1"
13+
- "src/**/*.psm1"
14+
- ".github/linters/PSScriptAnalyzerSettings.psd1"
15+
- ".github/workflows/lint-powershell.yml"
16+
workflow_dispatch:
17+
18+
jobs:
19+
psscriptanalyzer:
20+
runs-on: windows-latest
21+
22+
steps:
23+
- name: Checkout code
24+
# gh api repos/actions/checkout/commits/v6.0.2 --jq '.sha'
25+
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
26+
27+
- name: Install PSScriptAnalyzer
28+
shell: pwsh
29+
run: |
30+
# Pin to a specific version so results are reproducible
31+
# Update RequiredVersion when a new release ships on PowerShell Gallery
32+
Install-Module -Name PSScriptAnalyzer -RequiredVersion 1.25.0 -Force -Scope CurrentUser
33+
34+
- name: Run PSScriptAnalyzer
35+
shell: pwsh
36+
run: |
37+
$settings = '.github/linters/PSScriptAnalyzerSettings.psd1'
38+
$results = Get-ChildItem -Path 'src' -Recurse -Include '*.ps1','*.psm1' |
39+
Invoke-ScriptAnalyzer -Settings $settings
40+
41+
if ($results) {
42+
$results | Format-Table -AutoSize
43+
Write-Host "::error::PSScriptAnalyzer found $($results.Count) issue(s)."
44+
exit 1
45+
}
46+
47+
Write-Host "No issues found."

src/dependencies/local-build.ps1

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,8 +32,6 @@ if ($Removals) {
3232
$runtimeInformation = [System.Runtime.InteropServices.RuntimeInformation]
3333
$osPlatform = [System.Runtime.InteropServices.OSPlatform]
3434
$IsWindowsPlatform = $runtimeInformation::IsOSPlatform($osPlatform::Windows)
35-
$IsLinuxPlatform = $runtimeInformation::IsOSPlatform($osPlatform::Linux)
36-
$IsMacOSPlatform = $runtimeInformation::IsOSPlatform($osPlatform::OSX)
3735
# lazy temp staging so we only touch disk when needed
3836
$rootTempDir = $null
3937
$playbookTempPath = $null

src/playbook/Executables/ASSOC.ps1

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -156,7 +156,7 @@ function Get-Time {
156156
Write-Output $dateTimeHex
157157
}
158158

159-
function Delete-UserChoiceKey {
159+
function Remove-UserChoiceKey {
160160
param (
161161
[Parameter( Position = 0, Mandatory = $True )]
162162
[String]
@@ -229,7 +229,7 @@ for ($i = 2; $i -lt $args.Length; $i++) {
229229
New-Item -Path "HKU:\$Hive\SOFTWARE\Microsoft\Windows\Shell\Associations\UrlAssociations\$($splitArg[1])" -Force | Out-Null
230230
}
231231
If (Test-Path "HKU:\$Hive\SOFTWARE\Microsoft\Windows\Shell\Associations\UrlAssociations\$($splitArg[1])\UserChoice") {
232-
Delete-UserChoiceKey "$Hive\SOFTWARE\Microsoft\Windows\Shell\Associations\UrlAssociations\$($splitArg[1])\UserChoice"
232+
Remove-UserChoiceKey "$Hive\SOFTWARE\Microsoft\Windows\Shell\Associations\UrlAssociations\$($splitArg[1])\UserChoice"
233233
}
234234
If (-NOT (Test-Path "HKU:\$Hive\SOFTWARE\Microsoft\Windows\CurrentVersion\ApplicationAssociationToasts")) {
235235
New-Item -Path "HKU:\$Hive\SOFTWARE\Microsoft\Windows\CurrentVersion\ApplicationAssociationToasts" -Force | Out-Null
@@ -246,7 +246,7 @@ for ($i = 2; $i -lt $args.Length; $i++) {
246246
New-Item -Path "HKU:\$Hive\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\FileExts\$($splitArg[0])" -Force | Out-Null
247247
}
248248
If (Test-Path "HKU:\$Hive\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\FileExts\$($splitArg[0])\UserChoice") {
249-
Delete-UserChoiceKey "$Hive\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\FileExts\$($splitArg[0])\UserChoice"
249+
Remove-UserChoiceKey "$Hive\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\FileExts\$($splitArg[0])\UserChoice"
250250
}
251251
If (-NOT (Test-Path "HKU:\$Hive\SOFTWARE\Microsoft\Windows\CurrentVersion\ApplicationAssociationToasts")) {
252252
New-Item -Path "HKU:\$Hive\SOFTWARE\Microsoft\Windows\CurrentVersion\ApplicationAssociationToasts" -Force | Out-Null

src/playbook/Executables/AtlasDesktop/6. Advanced Configuration/Services/Network Discovery/Disable Network Discovery Services.cmd

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ reg add "HKLM\SOFTWARE\AtlasOS\Services\%settingName%" /v path /t REG_SZ /d "%sc
2323
if not "%~1"=="/silent" call "%windir%\AtlasModules\Scripts\serviceWarning.cmd" %*
2424

2525
:: Unpin 'Network' from Explorer sidebar
26-
reg import "%windir%\AtlasDesktop\3. General Configuration\File Sharing\Network Navigation Pane\Disable Network Navigation Pane (default).reg" > nul
26+
call "%windir%\AtlasDesktop\3. General Configuration\File Sharing\Network Navigation Pane\Disable Network Navigation Pane (default).cmd" > nul
2727

2828
call setSvc.cmd fdPHost 4
2929
call setSvc.cmd FDResPub 4
@@ -33,4 +33,4 @@ if "%~1"=="/silent" exit /b
3333

3434
echo Finished, please reboot your device for changes to apply.
3535
pause
36-
exit /b
36+
exit /b

src/playbook/Executables/AtlasModules/Scripts/ASSOC.ps1

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -156,7 +156,7 @@ function Get-Time {
156156
Write-Output $dateTimeHex
157157
}
158158

159-
function Delete-UserChoiceKey {
159+
function Remove-UserChoiceKey {
160160
param (
161161
[Parameter( Position = 0, Mandatory = $True )]
162162
[String]
@@ -229,7 +229,7 @@ for ($i = 2; $i -lt $args.Length; $i++) {
229229
New-Item -Path "HKU:\$Hive\SOFTWARE\Microsoft\Windows\Shell\Associations\UrlAssociations\$($splitArg[1])" -Force | Out-Null
230230
}
231231
If (Test-Path "HKU:\$Hive\SOFTWARE\Microsoft\Windows\Shell\Associations\UrlAssociations\$($splitArg[1])\UserChoice") {
232-
Delete-UserChoiceKey "$Hive\SOFTWARE\Microsoft\Windows\Shell\Associations\UrlAssociations\$($splitArg[1])\UserChoice"
232+
Remove-UserChoiceKey "$Hive\SOFTWARE\Microsoft\Windows\Shell\Associations\UrlAssociations\$($splitArg[1])\UserChoice"
233233
}
234234
If (-NOT (Test-Path "HKU:\$Hive\SOFTWARE\Microsoft\Windows\CurrentVersion\ApplicationAssociationToasts")) {
235235
New-Item -Path "HKU:\$Hive\SOFTWARE\Microsoft\Windows\CurrentVersion\ApplicationAssociationToasts" -Force | Out-Null
@@ -246,7 +246,7 @@ for ($i = 2; $i -lt $args.Length; $i++) {
246246
New-Item -Path "HKU:\$Hive\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\FileExts\$($splitArg[0])" -Force | Out-Null
247247
}
248248
If (Test-Path "HKU:\$Hive\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\FileExts\$($splitArg[0])\UserChoice") {
249-
Delete-UserChoiceKey "$Hive\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\FileExts\$($splitArg[0])\UserChoice"
249+
Remove-UserChoiceKey "$Hive\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\FileExts\$($splitArg[0])\UserChoice"
250250
}
251251
If (-NOT (Test-Path "HKU:\$Hive\SOFTWARE\Microsoft\Windows\CurrentVersion\ApplicationAssociationToasts")) {
252252
New-Item -Path "HKU:\$Hive\SOFTWARE\Microsoft\Windows\CurrentVersion\ApplicationAssociationToasts" -Force | Out-Null

0 commit comments

Comments
 (0)