Aryan20 / Logomenu

Quick access menu for the GNOME panel with options that help ease the workflow for newcomers and power users alike.
https://extensions.gnome.org/extension/4451/logo-menu/
GNU General Public License v2.0
52 stars 31 forks source link

Make restart and shutdown interactive #26

Closed RedBearAK closed 2 years ago

RedBearAK commented 2 years ago

This extension is exactly what I was looking for, for a long time, especially now that I've realized it has the power menu options available to be enabled. Works wonderfully with "Big Sur Status Area" to produce a distro-specific "Apple menu" to fit Ubuntu or Fedora or whatever. The only thing that was really missing from Tofu Menu was the power options. The dev for some reason just wasn't interested in adding them.

I just put together PR #25 with some alternative commands that will make sure that Restart and Shut Down will produce an interactive dialog in the same way as using the existing power options in the usual GNOME status menu (and just like using the same options in the Apple menu on macOS). I hope you'll accept the changes. I was actually using these alternate commands in a modified Big Sur Menu extension last year, but didn't want to go through the whole process of publishing it as a new extension.

Let me know if you have any questions about the PR, or issues with it.

Aryan20 commented 2 years ago

Hey, thanks for your kind remarks! Yeah, Tofu Menu is unfortunately not maintained anymore, hence the reason this extension exists. The changes you proposed are nice! I have commented one required change in the PR, once done I will merge it.

RedBearAK commented 2 years ago

@Aryan20

Cleaned up the comments. I'm a big fan of littering whatever I'm working on with comments and snippets that I might need to refer to later to remember WTH was going on at the time. But clearing them out shouldn't cause any harm. Some commenters on Reddit helped me understand and track down all the relevant CLI commands last year, and I can always refer back to that if I can't recall where this PR is.

https://www.reddit.com/r/gnome/comments/ne8hos/gnome_status_menu_restartshutdown_commands_with/

FYI, I have experienced instability with my GNOME shell when testing the lock screen option, but that instability happens with both the original loginctl lock-session command and the replacement dbus-send command, so I don't think it's caused by anything I did. My system has been upgraded from Ubuntu 20.04 to 21.04, 21.10 and finally 22.04. And I have about three dozen extensions active most of the time, so I can't be sure exactly where any instability emanates from. I actually get the whole Extension Manager automatically turning the main switch off frequently whenever I'm messing with any extension at all. But I've come to expect that from GNOME in general when there are too many extensions involved. Just the way it is.

The other functions don't seem to cause my shell any fits the way the lock screen option does. The lock screen option doesn't seem to cause the same issues on another machine (2007 white MacBook) with a fresh Ubuntu 22.04 install. So I'm hoping this issue is just isolated to my main system.

I don't really use the lock screen option anyway, so I was just testing to make sure it works and then I'll be turning it back off.

Thanks for your time!

Aryan20 commented 2 years ago

I will definitely check the lock screen option, last time I checked it worked fine. Thanks for your work! :D