Replies: 1 comment
|
Patches welcome. Here is a outline for how to implement it.
1) Write cross platform code to list all background processes that are
descendants of a given PID. For example: https://unix.stackexchange.com/questions/701938/how-do-i-list-all-background-processes
Except on Linux you would use the /proc file system directly and macOS
you would use the process query library (cant recall what its called).
See the implementation of process_group_map() to get started. No clue what
you would do on the various BSDs. At least some of them support /proc.
2) Use this code to check if there background processes and also to list
all processes associated with all windows.
3) Write a kitten to present the list of processes from (2) and ask for
confirmation, since the current ask kitten cant really do that well. Or
maybe add a mode to the ask kitten for it.
|
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Ideas
with shell integration driven confirm and close, also ask for confirmation when at shell prompt && there are also background jobs still running or stopped (e.g. I could have an instance of vim suspended/stopped in the background and would unknowingly lose it by closing the tab)
instead of just saying "n windows are running", be more specific and list all the programs that are running in that tab too (perhaps again including/considering background jobs as well)
All reactions