arelange / gnome-shell-extension-hibernate-status

Gnome Shell extension that adds a hibernate/hybrid suspend button in Status menu.
GNU General Public License v2.0
151 stars 54 forks source link

Install from command line #43

Closed meaz closed 4 years ago

meaz commented 4 years ago

Hi, how can we install and enable this extension from command line? I'm trying to install it with ansible. Thanks a lot

p91paul commented 4 years ago

you have to put files into .local/share/gnome-shell/extensions/#extension id as written in metadata.json#/ Then restart gnome shell to load the extension, and use gsettings to enable it. This procedure works in general for all extensions.

meaz commented 4 years ago

thanks @p91paul I did try that, but it still doesn't work. I did git clone https://github.com/arelange/gnome-shell-extension-hibernate-status.git hibernate-status@dromi22 It works if I user firefox gnome extension to install it. But with git clone, I get a get a orange triangle with a question mark in gnome extensions list. I use debian buster and have gnome-shell 3.30.2.

p91paul commented 4 years ago

it's hibernate-status@dromi, not dromi22. Not sure if you just copied it wrong here.

p91paul commented 4 years ago

You also need to run: glib-compile-schemas schemas/ in the extension's folder

meaz commented 4 years ago

it's hibernate-status@dromi, not dromi22. Not sure if you just copied it wrong here.

yes I just copied it wrong

You also need to run: glib-compile-schemas schemas/ in the extension's folder

So, here is exactly what I did: git clone https://github.com/arelange/gnome-shell-extension-hibernate-status.git hibernate-status@dromi cd .local/share/gnome-shell/extensions/hibernate-status@dromi glib-compile-schemas schemas/ I add hibernate-status@dromi in the enabled plugins in dconf I even reboot: I still have the orange triangle with a question mark in gnome extensions list.

p91paul commented 4 years ago

can you post journalctl log? probably some error occurred

p91paul commented 4 years ago

what's your gnome-shell version?

meaz commented 4 years ago

First of all, thanks for your time and help @p91paul !

gnome-shell version is 3.30.2

journalctl | grep hibernate

gives me that error: gnome-shell[2820]: Extension "hibernate-status@dromi" had error: TypeError: GObject.registerClass() used with invalid base class (is ModalDialog)

p91paul commented 4 years ago

I see. Latest master does not support gnome shell 3.30, unfortunately, try checking out commit 3c81d57fbc6c59a02067c7508abdca51a8688734

p91paul commented 4 years ago

Also, I have to warn you: gnome is making big changes to the shutdown menu in 3.36. Most certainly this extension is not going to work, and will require a full rewrite. I hope that either gnome will include a hibernate option in its default menu, or someone is going to create another extension, but this one is likely to die.

meaz commented 4 years ago

Thanks a lot @p91paul ! I'm closing the ticket then. Too bad this extension won't work anymore!