ExtraMenus Fork (window configuration) Final version

Hello, everyone.
I have created a fork of ExtraMenu for E27. Currently, everything has to be created and edited manually. This fork adds a configuration window (menu -> configuration -> all -> menu-> ExtraMenu) that allows for the quick creation of menus and submenus, the definition of their positions, the selection of applications, and so on. The interface follows the theme and language of the target system. A description can be found in the README.
Much like with the E-Containers module, I designed the interface myself, drafted the outline, and then had Claude do the implementation work.

Not shared on GitHub; once again, I had an AI do the work, so the code might need checking. I’ve shared it via FreeTransfer—it will be accessible for 30 days.

enlightenment-module-extramenu-0.5.5.tar.gz :

Installation:

tar xzf enlightenment-module-extramenu-0.5.5.tar.gz
cd enlightenment-module-extramenu
meson setup build && ninja -C build && sudo ninja -C build install

Just wondering how this works:
Did Claude add the COPYING (GPL)file, or did you?

No, it already exists in the repository: Making sure you're not a bot! . I have just updated the version to the 5.1 fork. There was an issue with its placement in the menu. In E27, the sys/N prefix no longer exists; it is now enlightenment/N.

strings /usr/bin/enlightenment | grep -E '[1]+/[0-9]{1,2}$' | sort -u
config/0
config/1
config/2
enlightenment/0
enlightenment/1
enlightenment/2
enlightenment/3
main/0
main/1
main/10
main/11
main/2
main/3
main/4
main/5
main/6
main/7
main/8
main/9

I’ve put together a quick little video to show you how it works. I use "extramenu" to create custom menus containing things like quick shortcuts for scripts, tutorial sections, and more. In this example, which I threw together quickly I used the .desktop files for existing applications; while there’s no real point in duplicating menus like that, I’ve done it just to demonstrate the concept to you.

I still need to correct the manual editing of the .menus files. I'm getting an error with xdg-open.

src/e_mod_main.h (EDIT_COMMAND)

//
#define MENU_USER_DIR ".e/e/extra_menu"
#define MENU_SYSTEM_DIR "/usr/share/menus"
//#define MENU_SYSTEM_DIR "/etc/xdg/menus"

#define DEFAULT_MENU_PLACEMENT "main/7"
/
command used by the "Edit .menu manually" button (%s = file path)/
#define EDIT_COMMAND "xdg-open '%s'"
/
/

I am updating the first post with version 5.1 for those who want to test it.

enlightenment-module-extramenu-0.5.1.tar.gz:


  1. a-z_ ↩︎

Too bad, I was sort of hoping that Claude did that because it did use/borrow/steal GPL code and therefore should GPL it too.

So there's going to be a lot of programs out there that aren't GPL but should be, in the future. :thinking:

Once I’ve finished everything, I’ll add a mention of Claude, as well as the GPL license. I wasn’t aware of that—thanks for the information.

Final version :

enlightenment-module-extramenu-0.5.5.tar.gz:

ExtraMenu — Elive / Triki1 version

An Enlightenment (E27) module that adds your own menus and submenus to the
main menu, the system (Enlightenment) menu or the Configuration menu, with a
graphical configuration window
.

Designed by triki1, built by Claude (Anthropic),
based on the original enlightenment-module-extramenu module by Davide Andreoli.

Version: 0.5.5 · License: GNU GPL v3 or later (see COPYING)


The original module

Repository: https://git.enlightenment.org/enlightenment/enlightenment-module-extramenu.git

Written by Davide Andreoli (2008-2015), first for the OpenGeu distribution, the
original module does one simple and useful thing: it reads the .menu files
(FreeDesktop standard) found in ~/.e/e/extra_menu and /usr/share/menus, and
adds every menu it finds to Enlightenment's main menu, using the
X-Enlightenment-Menu attribute of the .directory file.

Its weak point: everything had to be done by hand. For each menu you had to
write a .menu (XML) file, a .directory file and, for the icon, a .desktop
file. The original documentation is kept in README.original.

What triki1 and Claude did

The idea comes from triki1: make ExtraMenu easy to configure, taking inspiration
from the way the E-Containers module was built. Claude wrote the code, checked
that it compiles against the Enlightenment headers and tested the file
generation with the real Efreet parser; triki1 tested the module on Elive
(Debian Trixie, Enlightenment 0.27.99) and steered every fix.

New features

  • Configuration window: Menu → Configuration → Menus → Extra Menu.
    • menus shown as a tree (menus, submenus, sub-submenus…);
    • Name and icon (icon theme name or full path, file chooser button
      with preview);
    • Position: main menu (order 0-11), Enlightenment system menu
      (order 0-3), Configuration menu (order 0-2), or a custom name/N value;
    • Applications: picked from the .desktop files of
      /usr/share/applications and ~/.local/share/applications, with search,
      Add, Remove, Up, Down;
    • "Edit .menu manually" button (opens geany, mousepad, scite, SciTE, gvim
      or edi; EXTRAMENU_EDITOR forces another editor);
    • New menu, New submenu, Delete, Reload from disk.
  • Submenus: nested <Menu> elements, one .directory file per submenu
    (<menu>--<submenu>.directory).
  • Order is respected: a <Layout> is written in every menu, otherwise
    FreeDesktop menus are sorted alphabetically. Applications follow the order of
    the list, then the submenus come after them.
  • Base folder: the first time the module loads, ~/.e/e/extra_menu is
    created with a basic extramenu.menu and extramenu.directory.
  • Fixed positions: the system menu is enlightenment/N (the sys/ prefix
    from the old documentation does not exist) and the order is limited to the
    values that really exist, otherwise the menu becomes invisible.
  • Follows the theme and the language: the window uses Enlightenment's own
    widgets and icons, so it follows the active theme. Texts are translated
    (gettext, domain extramenu).
  • Translations: cs, de, es, fr, it, ja, ko, nl, pl, pt, pt_BR, ru
    (French is the reference; the others deserve a review by native speakers).

File safety

  • Hand-written .menu files that contain elements the window does not generate
    (categories, custom layouts, merges…) are shown read-only: they are never
    overwritten.
  • Only the menus actually modified in the window are rewritten.
  • The Name[xx]= and Comment… lines of .directory files are preserved.
  • "Atomic" writes (temporary file, then rename).

Changes to the original module

  • e_mod_main.c: only reads *.menu files (before, every file in the folders,
    .directory files included); creates the user folder before monitoring it;
    ignores temporary files; registers the configuration page; new
    extramenu_reload() function.
  • meson.build: new source files, translations installed in
    <module folder>/locale, version 0.5.x.
  • New files: e_mod_config.c/h (the window), e_mod_files.c/h (reading and
    writing .menu / .directory files, minimal XML parser), po/ folder.

Installation

Dependencies: enlightenment-dev, libefl-dev, meson, ninja-build, and
gettext (to install the translations).

meson setup build
ninja -C build
sudo ninja -C build install

Then, in Enlightenment: Menu → Configuration → Modules → Extra Menu,
Load (or unload then reload after an update).

Usage

  1. Open Menu → Configuration → Menus → Extra Menu.
  2. New menu, then give it a name, an icon and a position.
  3. Select applications on the left, Add.
  4. New submenu creates a level below the selected entry.
  5. Apply (or OK): the files are written to ~/.e/e/extra_menu and
    Enlightenment's menu is reloaded immediately.

The files remain standard .menu / .directory files: you can still edit them
by hand ("Edit .menu manually" button, then "Reload from disk").

Known limitations

  • Submenus follow their creation order relative to each other (no buttons to
    move them yet); they are shown after the applications.
  • Only the top level of /usr/share/applications and
    ~/.local/share/applications is scanned (not their subfolders).
  • Tested on Elive (E 0.27.99). The headers used for the compile checks outside
    Elive are those of E 0.26.

Translating into another language

Copy po/extramenu.pot to po/<language>.po, translate the msgstr entries,
add the language code to po/LINGUAS, then rebuild.

License

This module is distributed under the GNU General Public License, version 3 or
(at your option) any later version
— full text in COPYING.

  • The added files (e_mod_config.*, e_mod_files.*) are under GPL v3+.
  • The original files (e_mod_main.*) keep their author's header ("GNU Lesser
    General Public License, version 3 or later") with a note describing the
    modifications; since the LGPL v3 allows redistribution under the GPL v3, the
    module as a whole is distributed under GPL v3+.
  • The original repository already ships the GPL v3 text in COPYING.
Copyright (C) 2008-2015 Davide Andreoli  (original module)
Copyright (C) 2026      triki1           (design, testing)
                        built with Claude (Anthropic)

This program is free software: you can redistribute it and/or modify it under
the terms of the GNU General Public License as published by the Free Software
Foundation, either version 3 of the License, or (at your option) any later
version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY
WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A
PARTICULAR PURPOSE. See the GNU General Public License for more details.

Credits

  • Davide Andreoli — original module (OpenGeu / Enlightenment).
  • triki1 — idea, specification, testing on Elive.
  • Claude (Anthropic) — code for the window, the submenus and the translations.

Files: AUTHORS · NEWS · INSTALL

@triantares

Here is the GPL license and the explanation of the project; is this okay?