Reputation: 969
I'd like to support multiple GNOME versions with my shell extension. How can I detect the GNOME version it's running on and branch the code appropriately?
Upvotes: 5
Views: 821
Reputation: 969
const Config = imports.misc.config;
if (Config.PACKAGE_VERSION.startsWith("3.42"))
// etc.
Upvotes: 5