From: <dom...@us...> - 2020-02-09 22:11:36
|
Revision: 968 http://sourceforge.net/p/fvwm-crystal/code/968 Author: dominique_libre Date: 2020-02-09 22:11:35 +0000 (Sun, 09 Feb 2020) Log Message: ----------- Fix call of AutoHibernate menu with sysctl Modified Paths: -------------- ChangeLog fvwm/components/functions/Exit Modified: ChangeLog =================================================================== --- ChangeLog 2020-02-09 21:58:26 UTC (rev 967) +++ ChangeLog 2020-02-09 22:11:35 UTC (rev 968) @@ -3,7 +3,7 @@ dimanche 9 février 2020 fvwm/components/functions/Exit: fix xscreensaver and systemctl menu; call systemctl without sudo; don't show pm-utils menu is systemd is present; - cleanup. + cleanup; fix unique call of AutoHibernate menu. - fvwm/components/functions/Exit-systemctl: moved to the Exit file fvwm/scripts/AutoHibernate: call systemctl without sudo Modified: fvwm/components/functions/Exit =================================================================== --- fvwm/components/functions/Exit 2020-02-09 21:58:26 UTC (rev 967) +++ fvwm/components/functions/Exit 2020-02-09 22:11:35 UTC (rev 968) @@ -41,15 +41,17 @@ DestroyFunc AutoHibernate-generator AddToFunc AutoHibernate-generator ++ I InfoStoreAdd sysctl no ++ I Test (x /usr/bin/systemctl) InfoStoreAdd sysctl /usr/bin/systemctl ++ I TestRc (NoMatch) Test (x /bin/systemctl) InfoStoreAdd sysctl /bin/systemctl + I DestroyMenu recreate /AutoHibernate + I Piperead "if test `pkill -0 AutoHibernate`; \ then echo Test \\\(x /usr/sbin/pm-hibernate\\\) AddToMenu /AutoHibernate \\'$[gt.Stop]\\' EndAutoHibernate; \ - echo Test \\\(x /usr/bin/systemctl\\\) AddToMenu /AutoHibernate \\'$[gt.Stop]\\' EndAutoHibernate; \ - echo Test \\\(x /bin/systemctl\\\) AddToMenu /AutoHibernate \\'$[gt.Stop]\\' EndAutoHibernate; \ + echo Test \\\(!EnvMatch infostore.sysctl no\\\) AddToMenu /AutoHibernate \\'$[gt.Stop]\\' EndAutoHibernate; \ else echo Test \\\(x /usr/sbin/pm-hibernate\\\) AddToMenu /AutoHibernate \\'$[gt.Start when battery is as low as]\\' Popup /AutoHibernatePMValue; \ - echo Test \\\(x /usr/bin/systemctl\\\) AddToMenu /AutoHibernate \\'$[gt.Start when battery is as low as]\\' Popup /AutoHibernateSysValue; \ - echo Test \\\(x /bin/systemctl\\\) AddToMenu /AutoHibernate \\'$[gt.Start when battery is as low as]\\' Popup /AutoHibernateSysValue; \ + echo Test \\\(!EnvMatch infostore.sysctl no\\\) AddToMenu /AutoHibernate \\'$[gt.Start when battery is as low as]\\' Popup /AutoHibernateSysValue; \ fi" ++ I InfoStoreRemove sysctl DestroyMenu /AutoHibernate AddToMenu /AutoHibernate @@ -123,7 +125,7 @@ Test (EnvIsSet SESSION_MANAGER) AddToMenu /Exit '%22x22/fvwm-crystal/gdm.png%$[gt.Save session]' Exec exec gnome-session-save --gui Test (EnvIsSet SESSION_MANAGER) AddToMenu /Exit '%22x22/fvwm-crystal/gdm.png%$[gt.Manage session]' Exec exec gnome-session-properties + I Test (EnvMatch infostore.sysctl no) Exit-SelectLogoutManager -+ I InfoStoreRemove ExitManager ++ I InfoStoreRemove sysctl Exit-Menu This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |