[Nix-dev] wmii and xrandr
Nicolas Pierron
nicolas.b.pierron at gmail.com
Thu Mar 12 22:47:47 CET 2009
Hi Marc,
On Thu, Mar 12, 2009 at 21:39, Marc Weber <marco-oweber at gmx.de> wrote:
> So does someone mind me changing the fix-style branch wmii windowManager
> start session script this way?
Yes, I hate killing server. I am a nice guy ;)
> diff --git a/upstart-jobs/xserver/windowManager/wmii.nix
> b/upstart-jobs/xserver/windowManager/wmii.nix
> index 59a88f9..50d6a3d 100644
> --- a/upstart-jobs/xserver/windowManager/wmii.nix
> +++ b/upstart-jobs/xserver/windowManager/wmii.nix
> @@ -21,8 +21,10 @@ in
> session = mkIf cfg.enable [{
> name = "wmii";
> start = "
> + while :; do
> ${pkgs.wmiiSnap}/bin/wmii &
> waitPID=$!
> + done
> ";
> }];
> };
>
>
> Then wmii will be restarted forever and you'll be able to switch
> rotation occasionally.
The goal of the waitPID variable is to wait in order to end the
session when a job terminate. By adding this loop you kill extra
configuration which could be loaded after and force the user to quit
with a bad method.
I am against this method, you should use the waitPID variable with a
primary job which allow user to quit properly and to resize the
screen.
So I foresee two possible solutions to this problem:
- patching wmii
- adding a wrapper which handle wmii restart and the screen resize
without leaving the PID number.
--
Nicolas Pierron
http://www.linkedin.com/in/nicolasbpierron
- If you are doing something twice then you should try to do it once.
More information about the nix-dev
mailing list