Overview of changes:
* Improved and updated README.md
Actually, the main reason for this update is to make new README
visible sooner, since it's been significantly improved. Most
important change is that the introduction has been moved to own
document. Also Installation section has been clarified. That and
some tiny fixes.
* Made minor visual improvement to mkusage()
* Added tests for mkusage() '-w' option
* Made SHELLFU_IMPORTED into an internal variable
* Added some ShellCheck exceptions
SC2039 - We simply have to use `local` whenever it's possible, and
although it's not defined in POSIX, most common shells do support it
(well, at least Dash, Bash and Zsh).
SC1090 - Sourcing non-constant file is pretty much the main idea of
Shellfu, so avoiding that part does not make sense.
Overview of changes:
* Added workaround to shellfu_api test only against own modules
* Added option to append clarifying message to usage messages
Usage messages can now be made more useful by warning user what
exactly was wrong. Warnings will appear after the usage message
and before command exits and decorated with 'bad usage: ' prefix;
this is so that user will be more likely notice and understand them.
Note that this could be done earlier by using -E option and adding
the warning yourself inside usage() function, but the -w option lets
you keep usage() very simple and yet leads to more consistency.
* Codebase maintenance
* Refactored charmenu.sh
The docstring was not very useful so this it was overhauled
completely. Also more proper coding style is now in place.
* `shellfu` command will now de-duplicate $SHELLFU_PATH
shellfu init function, and by extension some shellfu-doc modes,
would list a module twice if its path ended up twice on
SHELLFU_PATH. That should no longer happen.
* Added mdfmt, a Markdown formatting helper
This module consists of single function with aim to help generate
Markdown text from your scripts.
* Updated and improved usage-related pretty.sh docstrings
* Fixed PRETTY_DEBUG_EXCLUDE double double-underscore bug
PRETTY_DEBUG_EXCLUDE would not work properly on functions like
`foo__bar__baz`, where the second double-underscore would make it
think module name was `foo__bar`, when in fact it's `foo`.
* Added journald logging module for pretty.sh
Using systemd-cat, this module employs journald as way of
communicating with user.
* Added shellfu-sh pseudo-package
On RPM-based distributions, somebody has to own 'include-sh'
directory. Also having shellfu-FOO package helps module packages
declare their "Shellfu flavor" (ie. `Requires: shellfu-sh` sends
clear message that a module is "POSIX-oriented".
* Updated packaging and meta-data
Files responsinle for packaging and versioning meta-data have been
altered to catch up with newer versions of MKit. This should have
almost no effect on package (only 'effect' I can think of is a purely
decorative change in `--version` output).
* Fixed typo in SPEC file
SPEC file claimed that Shellfu is distributed under LGPL2, while
it's actually GPL3. (We should consider changing it to LGPL2,
though.)
* Replaced LICENSE file with Markdown version
Because Markdown is cooler. For a more serious reason, MKit now has
*newstub* script, which can help regenerate MKit structure including
LICENSE file, and this script can only do Markdown (because Markdown
is cooler). TL;DR: It will be less hassle to keep MKit stuff fresh.
* Updated emnedded TFKit (v0.0.14) and MKit (v0.0.21)
Until TFKit is able to run tests in sandbox (instead of running tests
against installed SUT), this test will throw false positives in case
any other Shellfu modules are present.
This commit adds workaround that should be removed when new TFKit
version is installed.
If function name after the module prefix contained double underscore,
the old code would not parse module name properly, e.g.
foo__bar__baz
would consider 'foo__bar' as module name, when only 'foo' should be
considered.
Overview of changes:
* Fixed bug in function doc exporting that caused all function
docstrings be treated as verbatim text in POD
* Fixed case when shellfu-doc was called with non-existent file
* Added --encoding option to shellfu-doc
* Added inigrep test for special chars in section/key/value
* Added validation of section/key names to inigrep
* Build scripts maintenance