kill subscriber process when desktop is removed#36
Closed
no3m wants to merge 1 commit intophenax:masterfrom
Closed
kill subscriber process when desktop is removed#36no3m wants to merge 1 commit intophenax:masterfrom
no3m wants to merge 1 commit intophenax:masterfrom
Conversation
phenax
requested changes
Jun 11, 2022
| local old_pid="$(get_desktop_options "$selected_desktop" | valueof pid)"; | ||
| kill_layout $old_pid; | ||
|
|
||
| desktop_id=$(bspc query -D -d "$selected_desktop"); |
Owner
There was a problem hiding this comment.
nit: this can be a function inside desktop.sh
| @@ -14,19 +14,22 @@ BSP_DEFAULT_LAYOUTS="tiled\nmonocle"; | |||
|
|
|||
| # Kill old layout process | |||
| kill_layout() { | |||
Owner
There was a problem hiding this comment.
kill_layout's purpose is to kill the layout of a desktop. It doesn't make sense for it to accept a pid. Maybe we can have 2 functions kill_layout and kill_process
Collaborator
|
@phenax, in case @no3m does not respond, would you like me to try to fix the requests you made on the commit? 😋 not sure how that can be done though as i won't be able to push to no3m:master 🤔 |
Collaborator
|
Hi @no3m 👋 😋 as this PR has ben stale for almost 8 months now, we've decided with @phenax to move the changes to a2n-s/kill-subscriber-process-when-desktop-is-removed and apply the requested changes there 👍 hope you'll understand 😉 |
amtoine
added a commit
to amtoine/bsp-layout
that referenced
this pull request
Aug 12, 2022
Addresses the original review requested changes from phenax#36
amtoine
added a commit
to amtoine/bsp-layout
that referenced
this pull request
Aug 12, 2022
Addresses requested changes from the original stale phenax#36
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.
change the way kill_layout gets called... desktop options in remove_listener have to be cleared before calling kill_layout, otherwise if remove_listener is called by the subscriber process on desktop_remove event, it will kill itself before the options are cleared.
added 'did' (desktop id) option... once desktop_remove event is triggered, get_desktop_name_from_id is useless since desktop doesn't exist anymore.