]> glassweightruler.freedombox.rocks Git - xdg-ninja.git/commit
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)
commit5d5a66a5d31ad7708b1d998228f2230febeba4b5
treebbf27040bd57f540f8af75af5b26420cbd654473
parent4644d409aaf00b7d3b6864840f23e4c05c830322
xdg-ninja: allow custom programs/ dir via XN_PROGRAMS_DIR

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.
README.md
xdg-ninja.sh