Releases: bash-bastion/bash-core
Releases · bash-bastion/bash-core
v0.12.0
v0.11.0
v0.10.2
Fixes
core.should_output_color()now calls the internalcore.private.should_print_color()function for consistencycore.should_output_color()now accounts forFORCE_COLORenvironment variable
v0.10.1
Fixes
- Fix issue in which
bash-core's trap handling function would beunsettoo soon- Previously, it would be
unsetafter the firstcore.trap_removefor a particular signal (even if there are other user-provided handlers left). Now, it's only unset until after all user-provided handlers for a particular signal have been removed (withcore.trap_remove) - The bug was introduced in this revision, when fixing the calculation of our trap handler function name
- Previously, it would be
- Fix
unseting incorrect variables after certain loops
v0.10.0
Breaking Changes
core.print_dienow executes the newly-addedcore.print_fatalinstead ofcore.print_error
Features
New printing functions
core.print_{fatal,debug}?(_fn)
Fixes
- Improve documentation wording
v0.9.0
Breaking Changes
- When using
core.print_*_fnfunctions, a set of parenthesis is now printed:
Example:
fnn() { core.print_info_fn 'Blah'; }
fnn
# Before:
# => Info: fnn: Something
# Now:
# => Info: fnn(): Something- For
core.print_{error,warn,info}parameterless calls no longer have special behavior
core.print_error
# Before:
# => Error
# Now:
# => Error: Features
- Functions
$core.print_(?:error|warn|info)(?:_fn)?functions now print color.- Color is properly suppressed if
NO_COLORis passed or if:- Either standard error (or stdout in the case of info) is not a terminal
- Or
$TERMis set todumb
- Color is properly suppressed if
Miscellaneous
- Documentation improvements
- Prefix private methods with
core.private.
v0.8.0
Features
- Add core.print_die
- Original
core.print_*functions no longer show function name in output. New ones that still do have_fnpostpended to them. These might be removed in thev1.0.0release
Fixes
v0.7.1
Fixes
core.panic()properly prints stacktrace
v0.7.0
Features
- Add
core.panic()- Best used for programmer errors. It
exit 1while printing the applicable errors. Remember that you still need to account for subshells, etc.
- Best used for programmer errors. It
Fixes
- Fix regex in
core.get_package_infoso it actually works TOML files containing tabs
v0.6.0
Features
- New function
core.print_error - New function
core.print_warn - New function:
core.print_info - New function
core.print_stacktrace- Same exact functionality as previous
core.stacktrace_print
- Same exact functionality as previous
Deprecations
- Deprecate
core.stacktrace_print- This was done so the naming was more consistent with the
core.print_*family of functions. Expect this to be removed before thev1.0.0stable release
- This was done so the naming was more consistent with the
Fixes
- When printing errors, some functions incorrectly printed their own function names. This has been fixed
- Miscellaneous documentation improvements