From b5ea77873635ed272cf31294395b146dd802331a Mon Sep 17 00:00:00 2001 From: Dandaedre Date: Fri, 16 Oct 2026 14:31:31 +0200 Subject: [PATCH] Add requested application config declarations --- bootstrap.ps1 | 1 + configs/mpc-hc/settings.json | 4 ++++ configs/nextcloud/managed.ini | 3 +++ configs/ontime/override.css | 4 ++++ configs/windows/hosts.entries | 2 ++ configs/xnviewmp/xnview.ini | 3 +++ profiles/desktop-apps.json | 37 ++++++++++++++++++++++++++++++++++- tests/Manifest.Tests.ps1 | 2 +- 8 files changed, 54 insertions(+), 2 deletions(-) create mode 100644 configs/mpc-hc/settings.json create mode 100644 configs/nextcloud/managed.ini create mode 100644 configs/ontime/override.css create mode 100644 configs/windows/hosts.entries create mode 100644 configs/xnviewmp/xnview.ini diff --git a/bootstrap.ps1 b/bootstrap.ps1 index e6a8c00..acaa712 100644 --- a/bootstrap.ps1 +++ b/bootstrap.ps1 @@ -102,6 +102,7 @@ $settings = [ordered]@{ LOCALAPPDATA = $env:LOCALAPPDATA USERPROFILE = $env:USERPROFILE PROGRAMDATA = $env:PROGRAMDATA + SYSTEMROOT = $env:SYSTEMROOT } } $settings | ConvertTo-Json -Depth 8 | Set-Content -LiteralPath (Join-Path $dataRoot 'settings.json') -Encoding UTF8 diff --git a/configs/mpc-hc/settings.json b/configs/mpc-hc/settings.json new file mode 100644 index 0000000..ed5eb77 --- /dev/null +++ b/configs/mpc-hc/settings.json @@ -0,0 +1,4 @@ +{ + "schemaVersion": 1, + "values": [] +} diff --git a/configs/nextcloud/managed.ini b/configs/nextcloud/managed.ini new file mode 100644 index 0000000..c41286e --- /dev/null +++ b/configs/nextcloud/managed.ini @@ -0,0 +1,3 @@ +; Nextcloud managed preference overlay. +; Add non-secret settings only. Never add account sections, auth tokens, +; passwords, client certificates, or machine-specific sync paths. diff --git a/configs/ontime/override.css b/configs/ontime/override.css new file mode 100644 index 0000000..712359a --- /dev/null +++ b/configs/ontime/override.css @@ -0,0 +1,4 @@ +/* + * Ontime custom styling managed by Config Central. + * Add CSS overrides below. This file does not contain projects or application data. + */ diff --git a/configs/windows/hosts.entries b/configs/windows/hosts.entries new file mode 100644 index 0000000..466e832 --- /dev/null +++ b/configs/windows/hosts.entries @@ -0,0 +1,2 @@ +# Add managed entries as: IP-address hostname [additional-hostname ...] +# Comments and blank lines are ignored. Config Central owns only its marked block. diff --git a/configs/xnviewmp/xnview.ini b/configs/xnviewmp/xnview.ini new file mode 100644 index 0000000..60851f0 --- /dev/null +++ b/configs/xnviewmp/xnview.ini @@ -0,0 +1,3 @@ +; XnView MP managed preference overlay. +; Add only the sections and keys that should be identical on every machine. +; Catalog databases, thumbnails, and other unlisted keys are left untouched. diff --git a/profiles/desktop-apps.json b/profiles/desktop-apps.json index 2327a97..b3484b1 100644 --- a/profiles/desktop-apps.json +++ b/profiles/desktop-apps.json @@ -9,5 +9,40 @@ { "id": "XnSoft.XnViewMP", "source": "winget", "scope": "machine", "update": "latest" }, { "id": "Nextcloud.NextcloudDesktop", "source": "winget", "scope": "machine", "update": "latest" } ], - "configs": [] + "configs": [ + { + "name": "mpc-hc-settings", + "source": "configs/mpc-hc/settings.json", + "target": "HKCU:\\Software\\MPC-HC\\MPC-HC", + "mode": "registry", + "requiresPackage": "clsid2.mpc-hc" + }, + { + "name": "ontime-style", + "source": "configs/ontime/override.css", + "target": "%APPDATA%/Ontime/user/styles/override.css", + "mode": "copy", + "requiresPackage": "cpvalente.ontime" + }, + { + "name": "xnviewmp-settings", + "source": "configs/xnviewmp/xnview.ini", + "target": "%APPDATA%/XnViewMP/xnview.ini", + "mode": "ini-overlay", + "requiresPackage": "XnSoft.XnViewMP" + }, + { + "name": "nextcloud-settings", + "source": "configs/nextcloud/managed.ini", + "target": "%APPDATA%/Nextcloud/nextcloud.cfg", + "mode": "ini-overlay", + "requiresPackage": "Nextcloud.NextcloudDesktop" + }, + { + "name": "windows-hosts", + "source": "configs/windows/hosts.entries", + "target": "%SYSTEMROOT%/System32/drivers/etc/hosts", + "mode": "hosts-block" + } + ] } diff --git a/tests/Manifest.Tests.ps1 b/tests/Manifest.Tests.ps1 index 22fafa8..eb23443 100644 --- a/tests/Manifest.Tests.ps1 +++ b/tests/Manifest.Tests.ps1 @@ -6,7 +6,7 @@ Describe 'Manifest resolution' { It 'resolves the checked-in example in profile order' { $result = Resolve-MachineManifest -RepositoryRoot "$PSScriptRoot/.." -Machine 'example-desktop' $result.packages.Count | Should -Be 7 - $result.configs.Count | Should -Be 2 + $result.configs.Count | Should -Be 7 $result.packages[0].id | Should -Be 'Git.Git' }