Shopfloor: single autologon, clear Start pins, Intune sync tool, update docs
- AutoLogonCount reduced from 2 to 1 in Run-ShopfloorSetup.ps1 - Remove default pinned Start Menu tiles and set blank layout for future users - Add sync_intune.bat: triggers MDM sync and polls for SFLD group policies - Update README.md and SETUP.md with current project state (boot chain, new scripts, samba shares, webapp pages, commit history) Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -1,6 +1,36 @@
|
||||
# 03-StartMenu.ps1 — Create Start Menu shortcuts for all users (baseline)
|
||||
# Shortcuts in ProgramData\Microsoft\Windows\Start Menu\Programs\ persist for all accounts.
|
||||
|
||||
# --- Remove all default pinned Start Menu tiles ---
|
||||
# Unpin tiles for the current user
|
||||
try {
|
||||
$shell = New-Object -ComObject Shell.Application
|
||||
$shell.NameSpace('shell:::{4234d49b-0245-4df3-b780-3893943456e1}').Items() | ForEach-Object {
|
||||
$_.Verbs() | Where-Object { $_.Name -match 'Unpin from Start|Un.*pin' } | ForEach-Object { $_.DoIt() }
|
||||
}
|
||||
Write-Host "Unpinned all default Start Menu tiles for current user."
|
||||
} catch {
|
||||
Write-Warning "Could not unpin Start tiles: $_"
|
||||
}
|
||||
|
||||
# Set blank layout for future user profiles
|
||||
$blankLayout = @"
|
||||
<LayoutModificationTemplate xmlns:defaultlayout="http://schemas.microsoft.com/Start/2014/FullDefaultLayout"
|
||||
xmlns:start="http://schemas.microsoft.com/Start/2014/StartLayout"
|
||||
Version="1" xmlns="http://schemas.microsoft.com/Start/2014/LayoutModification">
|
||||
<LayoutOptions StartTileGroupCellWidth="6" />
|
||||
<DefaultLayoutOverride>
|
||||
<StartLayoutCollection>
|
||||
<defaultlayout:StartLayout GroupCellWidth="6" />
|
||||
</StartLayoutCollection>
|
||||
</DefaultLayoutOverride>
|
||||
</LayoutModificationTemplate>
|
||||
"@
|
||||
$layoutDir = "C:\Users\Default\AppData\Local\Microsoft\Windows\Shell"
|
||||
if (-not (Test-Path $layoutDir)) { New-Item -Path $layoutDir -ItemType Directory -Force | Out-Null }
|
||||
$blankLayout | Out-File -FilePath "$layoutDir\LayoutModification.xml" -Encoding UTF8 -Force
|
||||
Write-Host "Set blank Start Menu layout for future users."
|
||||
|
||||
$startMenu = "C:\ProgramData\Microsoft\Windows\Start Menu\Programs"
|
||||
$shell = New-Object -ComObject WScript.Shell
|
||||
|
||||
|
||||
Reference in New Issue
Block a user