How To Update GNOME Extensions via Terminal

Is there a simple way to update installed GNOME Extenions from the terminal so I can add it to a simple shell script that is run on a cron so that I can one-shot update my OS, Flatpaks, and GNOME Extensions?

No.

You can instruct gnome-shell to download and prepare available updates with the following D-Bus call:

$ gdbus call --session --dest org.gnome.Shell.Extensions \
     --object-path /org/gnome/Shell/Extensions \
     --method org.gnome.Shell.Extensions.CheckForUpdates

But any updates will only be installed the next time gnome-shell starts up, before initializing extensions. There is no way around that because of caching in SpiderMonkey: Once a file has been imported, any future imports will return the cached import, including after the file on disk changed.

1 Like

Ah that’s unfortunate.

So what happens with the gnome-chrome-shell extension and updates from the browser? Is it unloading it fully so the updated file on disk gets read without caching?

No way to do the same?

Is it planned to have this type of management interface in the future?

No, it tells gnome-shell to unload the old version and load the new one, but until a gnome-shell restart only the metadata update takes effect. That is, it looks like you are using the updated version, while in reality you are still running the old code.

1 Like

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.