Update docs/# samy.functions.ps1

This commit is contained in:
2026-01-31 18:49:37 -05:00
parent 1b4144f76f
commit 357385a652

View File

@@ -48,7 +48,7 @@ Ensures SAMY can install/update PowerShell modules and providers without interac
- Optionally marks `PSGallery` as trusted to prevent prompts.
**Why it matters**
Many PowerShell module installs trigger interactive prompts, especially on fresh machines. This function makes module installation reliable for SAMYs automation.
Many PowerShell module installs trigger interactive prompts, especially on fresh machines. This function makes module installation reliable for SAMY's automation.
**Common failure modes**
- No internet / proxy blocks PSGallery or NuGet endpoints.
@@ -113,8 +113,8 @@ Many Windows customizations are stored per-user. To make onboarding consistent,
**Important safety notes**
- Loading/unloading hives is sensitive:
- A loaded hive cant always be unloaded if something else is holding a handle.
- The function tracks whether it loaded the hive (`$didLoad`) to avoid unloading someone elses mount.
- A loaded hive can't always be unloaded if something else is holding a handle.
- The function tracks whether it loaded the hive (`$didLoad`) to avoid unloading someone else's mount.
- Profile iteration excludes non-standard SIDs by regex filter.
- Some profiles may not have `NTUSER.DAT` (system profiles, corrupt profiles, etc.). Those are skipped safely.
@@ -124,7 +124,7 @@ Uses `Write-LogHybrid` to record default hive load/unload outcomes and per-setti
**Modification notes**
- If you add more settings, prefer calling this helper rather than duplicating hive logic.
- If you need to write to HKLM machine-wide instead, do that outside this helper.
- If you ever see unload failed, its usually because something still holds a handle to the loaded hive.
- If you ever see “unload failed”, it's usually because something still holds a handle to the loaded hive.
---
@@ -227,7 +227,7 @@ All functions log via `Write-LogHybrid` using categories like:
- `SVSApps`
- `UI`
When `-LogToEvent` is enabled, events are also written to the configured Windows Event Log (e.g., `SVSMSP Events`) using the projects Event Log binding logic.
When `-LogToEvent` is enabled, events are also written to the configured Windows Event Log (e.g., `SVSMSP Events`) using the project's Event Log binding logic.
---