4 ms·
Show HN: Gnome-stay-awake – temporarily disable your lockscreen
- mnahkies 5y agoSometimes I have things like recipes or dashboards open on my laptop whilst I do other things in the background. It can be annoying having to bump the mouse to avoid the screen locking, and manually changing the settings through the UI has the risk I forget to change them back. This is a tiny utility that uses `gsettings` to disable the gnome screen lock and idle timeout when it starts, and restores them when it exits. It's written as a NodeJS / npm package for ease of distribution - you can try it out using `npx gnome-screen-lock` The code is very straight forward and I'd encourage you to read it prior to trying.
- okdjnfweonfe 5y agoSorry to be rude-ish Probably should be able to do the same with just: systemd-inhibit --what=idle --mode=block sh -c read or the more easier ways https://github.com/eonpatapon/gnome-shell-extension-caffeine https://github.com/eonpatapon/gnome-shell-extension-caffeine https://github.com/coadmunkee/gnome-shell-extension-espresso https://github.com/coadmunkee/gnome-shell-extension-espresso Or via api, which everything leads to https://people.gnome.org/~mccann/gnome-session/docs/gnome-session.html#org.gnome.SessionManager.Inhibit https://people.gnome.org/~mccann/gnome-session/docs/gnome-se... Noting other apps generally will inhibit via stuff sent through X/Wayland afaik, so this doesn't cover all methods
- mnahkies 5y agoHuh, nice. Feel a bit silly that I didn't find those extensions in my googling prior to making this