Files
gnome-shell-extensions/HACKING.md
Florian Müllner 406f4cd170 docs: Update instructions for extension additions for meson
The steps for adding a new extension are clearly different in meson,
so update the instructions accordingly. Don't bother with keeping
the existing autotools steps - supporting both build systems in
parallel is just temporary, autotools is on its way out.

Fixes https://gitlab.gnome.org/GNOME/gnome-shell-extensions/issues/31
2017-12-01 17:43:21 +01:00

1.3 KiB

Creating a New Extension

To create a new extension, add a subdirectory in extensions. Then create a meson.build from the provided template. If you need additional sources, add them to extension_sources. Similarily add GSettings schemas to extension_schemas and other files to extension_data.

Then modify the toplevel Meson file to add the new extension name in the appropriate set (that is one of classic_extensions, default_extensions or all_extensions).

Don't forget to add any translatable file to po/POTFILES.in, and then you're done. The Gettext domain you should choose is gnome-shell-extensions, not gnome-shell, unless you're sure there is the string you need in gnome-shell.

Coding Style

Generally, we follow GJS coding style, which in short is: indent 4 spaces, no tabs, space after comma, no space after function call.

The Emacs mode line for this /* -- mode: js2; js2-basic-offset: 4; indent-tabs-mode: nil -- */

Imports should be at the top, in two groups, one for standard imports (like imports.lang or imports.dbus) and introspection, the other for Shell API. Within the same group, put everything in alphabetic order.