DankMaterialShell icon indicating copy to clipboard operation
DankMaterialShell copied to clipboard

Proposal: break out machine specific state from `settings.json` into their own files

Open mawkler opened this issue 5 months ago • 5 comments

Feature Description

Break out machine specific state from settings.json into their own files

Use Case

Hi! I use the same dotfiles on two different machines, and I've noticed that ~/.config/DankMaterialShell/settings.json contains a lot of machine-specific settings. This gets kind of awkward to deal with when having settings.json checked in to a Git repo and tracked from both machines, because for some entries in settings.json each machine needs to have a unique setting, like its monitor names for example.

Here's a non-complete list of some of the entries that I'm talking about (for some I'm guessing what the actual use case is based on the name, but hopefully you get the idea).

  • bluetoothDevicePins.preferredDevice
  • wifiNetworkPins.preferredWifi
  • brightnessDevicePins
  • audioInputDevicePins / audioOutputDevicePins
  • niriOutputSettings
  • activeDisplayProfile
  • displayProfiles
  • enabledGpuPciIds / selectedGpuIndex
  • systemMonitorGpuPciId
  • lockScreenActiveMonitor
  • matugenTargetMonitor
  • frameScreenPreferences
  • systemMonitorDisplayPreferences
  • systemMonitorVariants
  • connectedFrameBarStyleBackups
  • browserUsageHistory / filePickerUsageHistory

Compositor(s)

All compositors

If Other, please specify

No response

Proposed Solution

My proposed solution is to move machine-specific settings like the ones above to some other file, for example ~/.local/share/DankMaterialShell/settings/<hostname-of-computer>.json.

Alternatives/Existing Solutions

🤷🏻‍♂

mawkler avatar Jun 11 '26 19:06 mawkler

It would also improve Nix OS / Home Manager compatibility

TurnrDev avatar Jul 03 '26 14:07 TurnrDev

Done in https://github.com/duxlabs-dev/dux-shell/commit/7974887295d2691fba5f885a899c3f8ba7ef59dd (settings: diff-only configs, machine-state split, backup CLI). Output state, the active display profile and device pins moved to session.json; a few per-machine keys remain in settings.json.

bbedward avatar Oct 28 '26 23:10 bbedward

Awesome! Thank you!

mawkler avatar Oct 29 '26 06:10 mawkler

Done in https://github.com/duxlabs-dev/dux-shell/commit/7974887295d2691fba5f885a899c3f8ba7ef59dd (settings: diff-only configs, machine-state split, backup CLI). Output state, the active display profile and device pins moved to session.json; a few per-machine keys remain in settings.json.

Guess I'm gonna need to rework my settings profiles PR😬 But a good change though

Conava avatar Oct 29 '26 08:10 Conava

9. > Done in 7974887 (settings: diff-only configs, machine-state split, backup CLI). Output state, the active display profile and device pins moved to session.json; a few per-machine keys remain in settings.json.

Guess I'm gonna need to rework my settings profiles PR😬
But a good change though

Don't think so, that commit is quite old.

apollo79 avatar Oct 29 '26 09:10 apollo79