StorageB / custom-command-toggle

GNOME extension to run shell commands using a GNOME quick toggle.
GNU General Public License v3.0
1 stars 0 forks source link

Not Working on Ubuntu 24.04 #1

Open FreQRiDeR opened 2 weeks ago

FreQRiDeR commented 2 weeks ago

Installs without error. (gnome 46 version) Extension loads fine, able to edit prefs. However, Extension does not show up in Menu. No text, Icon, nothing. Trying to create a simple SSh toggle with 'sudo systenctl start ssh, stop ssh.' Tried other commands without sudo. Bug in 24.04? Thanks!

StorageB commented 2 weeks ago

Both my desktop and laptop are running Ubuntu 24.04 and it's working fine on both. Could you provide screenshots of the prefs window and the menu where it should be showing up? However, even if all the fields in the prefs window are empty, a blank toggle button should still show up. A new menu will not appear with this extension, only a new toggle button will be added.

Do you have any other extensions installed that customizes what shows up in the menu or hides toggle buttons? Try disabling all other extensions except this one and see if it shows up.

FreQRiDeR commented 2 weeks ago

Yes, I have other extensions and I tried disabling them, most, at least. Strange? I tried your other extension, Command one and that didn’t (partially) work either? Buttons, commands are there but command is not executed. Tried prompting the terminal as well. Shows up but no command :( Will provide screenshots in a bit…

On Jun 16, 2024, at 7:43 PM, StorageB @.***> wrote:

 Both my desktop and laptop are running Ubuntu 24.04 and it's working fine on both. Maybe provide screenshots of the prefs window and the menu where it should be showing up. However, even if all the fields in the prefs window are empty, a blank toggle button should still show up. A new menu will not appear with this extension, only a new toggle button will be added.

Do you have any other extensions installed that customizes what shows up in the menu or hides toggle buttons? Try disabling all other extensions except this one and see if it shows up.

— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you authored the thread.

StorageB commented 2 weeks ago

Note that sudo commands require a password input from the terminal, so they will not directly work by themselves since the toggle button (and the command menu for the other extension) runs the command without a terminal window by default. However, you can use gnome-terminal -- command to run the command in the terminal. For example, gnome-terminal -- sudo apt-get update will open a terminal, prompt for your password, and then run the command.

Did the default command work after installing the extension? Try running this command instead. It should just open a dialog box when the command is executed. zenity --info --text="hello world"

FreQRiDeR commented 2 weeks ago

Thanks! The — worked. I was using ; and && which didn’t work.

Strangely, sudo did work sporadically, prompting admin password on occasion?

I was just wanting a quick way to turn ssh on, off with: ‘sudo system to start (or stop) ssh’. Adding gnome-terminal — worked. Semicolon, Ampersands did not.

On Jun 18, 2024, at 10:45 AM, StorageB @.***> wrote:

 Note that sudo commands require a password input from the terminal, so they will not directly work by themselves since the toggle button (and the command menu for the other extension) runs the command without a terminal window by default. However, you can use gnome-terminal -- command to run the command in the terminal. For example, gnome-terminal -- sudo apt-get update will open a terminal, prompt for your password, and then run the command.

Did the default command work after installing the extension? Try running this command instead. It should just open a dialog box when the command is executed. zenity --info --text="hello world"

— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you authored the thread.

StorageB commented 2 weeks ago

No problem! Glad to hear you got it working using gnome-terminal -- command (I'm assuming the "—" symbol was an autocorrect)

FreQRiDeR commented 2 weeks ago

Actually, the Command toggle extension does not work for me. (No icon) I was able to get Command Extension to work, however. Yeah, some fonts show double hyphen like that. (As one line)

On Jun 18, 2024, at 1:04 PM, StorageB @.***> wrote:

 No problem! Glad to hear you got it working using gnome-terminal -- command (I'm assuming the "—" symbol was an autocorrect)

— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you authored the thread.

StorageB commented 2 weeks ago

Can you provide screenshots of the toggle preferences screen and the menu showing the toggle button?

FreQRiDeR commented 2 weeks ago

Screenshot from 2024-06-19 14-58-23

FreQRiDeR commented 2 weeks ago

No icon shows. Where are the prefs stored besides .local/share/gnome-shell/extensions? I trashed the extension's folder, reinstalled and my saved prefs were still there? I remember the smiley face icon showing when I first installed? How do I wipe it completely? Seems like my prefs are retained even after deleting, reinstalling?

StorageB commented 2 weeks ago

No icon is displayed on the toggle button? Does the indicator icon show up in the top right portion of the screen next to the wifi indicator when the toggle button is on?

Are you using a different theme and maybe that particular icon doesn't exist? Maybe try different icon names to see if any of the others work. The smiley face icon was face-smile-symbolic

To completely remove the settings and revert to defaults, you need to install the Dconf editor from flathub or by sudo apt install dconf-editor

Screenshot from 2024-06-19 14-59-05

In the editor, navigate to the extension folder /org/gnome/shell/extensions/ and right click on the toggle extension, select reset, then hit the checkmark in the bottom right corner to apply.

FreQRiDeR commented 2 weeks ago

I reset the Prefs with dconf. Still no icon. 🤷‍♂️ I do have quite a few extensions, however. Might be a conflict. It’s fine, though. I prefer your Commands list tweak. Thanks!

On Jun 19, 2024, at 4:36 PM, StorageB @.***> wrote:

 No icon is displayed on the toggle button? Does the indicator icon show up in the top right portion of the screen next to the wifi indicator when the toggle button is on?

Are you using a different theme and maybe that particular icon doesn't exist? Maybe try different icon names to see if any of the others work. The smiley face icon was face-smile-symbolic

To completely remove the settings and revert to defaults, you need to install the Dconf editor from flathub or by sudo apt install dconf-editor

Screenshot.from.2024-06-19.14-59-05.png (view on web)

In the editor, navigate to the extension folder /org/gnome/shell/extensions/ and right click on the toggle extension, select reset, then hit the checkmark in the bottom right corner to apply.

— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you authored the thread.