]> glassweightruler.freedombox.rocks Git - xdg-ninja.git/commitdiff
xdg-ninja: allow custom programs/ dir via XN_PROGRAMS_DIR
authorAsperatus <thomas@ballasi.com>
Sat, 22 Apr 2023 13:33:15 +0000 (09:33 -0400)
committerAsperatus <thomas@ballasi.com>
Sat, 22 Apr 2023 13:43:04 +0000 (09:43 -0400)
In order to foresee the work on the unified packaging process, the
programs/ directory (which should be located in /usr/share/xdg-ninja or
/usr/local/share/xdg-ninja) is automatically found depending on where
the xdg-ninja executable is located.

This also allows for backwards compatibility as when the xdg-ninja
script is located in a working directory (not in a bin/), xdg-ninja
automatically picks the programs/ folder in the current working
directory, just like previously.

If the directory fails to find the programs/ dir, the user can override
the variable XN_PROGRAMS_DIR through environment variables.

This change is to prevent people from packaging xdg-ninja with the
programs/ directory within /usr(/local)/bin or by modifying the script
in place.


No differences found