[feat] sway/workspaces: refer to outputs by their monitor identifier in persistent-workspaces#5073
Open
ar-turek wants to merge 2 commits into
Open
Conversation
sway/workspaces: refer to outputs by their monitor identifier in persistent-workspaces
Author
|
Please let me know if you'd like me to make an update to the wiki as well, if/when this is merged - I'm not sure if it's possible to stage wiki changes as PRs as well. |
sway/workspaces: refer to outputs by their monitor identifier in persistent-workspacessway/workspaces: refer to outputs by their monitor identifier in persistent-workspaces
Author
|
I've also noticed the potential effect this PR has on this other one: #5072 - I can facilitate integration of those two, if needed. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR extends the
persistent-workspacesfunctionality insway/workspaceswith an option of pinning workspaces to displays by their output identifiers (basically, the monitor's "make and model", usually given as a vendor/model/serial triple) in addition to their output name (e.g.DP-3, which is unstable and can change between reboots).That means instead of this:
{ ... "sway/workspaces": { ... "persistent-workspaces": { "1:main": ["DP-2"], "2:code": ["DP-2"], "3:secondary": ["DP-3"], "0:TV": ["HDMI-A-1"] } }, ... }we can now write this:
{ ... "sway/workspaces": { ... "persistent-workspaces": { "1:main": ["Dell Inc. Dell AW2518H #ASM0cCiovard"], "2:code": ["Dell Inc. Dell AW2518H #ASM0cCiovard"], "3:secondary": ["AOC 24P4CV XL9RAHA000298"], "0:TV": ["Philips Consumer Electronics Company Philips FTV 0x01010101"] } }, ... }and even if the outputs are renamed after a reboot the workspaces will still be assigned to correct displays.