Closed FunctionalHacker closed 4 years ago
There is no strong reason this script is tied to sway and if there is a simple way to get rid of swaymsg
then that would be a welcome change. Sway is just what I am using and what I created the script for. I would have a hard time "supporting" other WMs but that does not mean we need to make it hard to use other WMs.
However, it does not seem to be quite as simple as just replacing swaymsg
with setsid
. From basic testing, something like exec setsid /bin/sh -c "$command"
appears to be working. Is that what you had in mind? If not, can you provide a better example?
@ReekyMarko Any input? I think I might just use the code above otherwise.
Sorry I totally forgot about this. Your example is basically what I ment. Great to see you got it implemented already!
I had a quick glance over the code and the only part that seems to make this script Sway specific is the the line where you use
swaymsg
to start the program.Is there any benefit to starting the program with
swaymsg
, rather than f.exsetsid $program
? Being that this whole script uses nothing but the CLI, changing that line would make it compatible with just about any WM.