Skip to content

v2024-08-14 Latest

Choose a tag to compare

@BetterScripts BetterScripts released this 14 Aug 14:44
· 1 commit to main since this release

Release v2024-08-14 for 14th August 2024, includes:

libarray.sh - v1.2.0
libdeque.sh - v1.1.0
libgetargs.sh & getarg - v1.3.0

Release is focused on portablity updates and makes many changes across all libraries and many tests.

libarray.sh v1.2.0

  • [NEW] Added array_is_array.
  • [NEW] array_split now has multiple ways of splitting text.
  • [FIX] (PORTABILITY) Added trailing '\n' to printf - without it some implementations will effectively discard the last line of data.
  • [FIX] (PORTABILITY) Rewrote awk scripts to better match platform capabilities. (All awk usage has changed considerably.)
  • [FIX] (PORTABILITY) Added workarounds for sed where '\n' in a replacement expression does not result in a <newline>.
  • [FIX] (PORTABILITY) Changed sed scripts to avoid long label names and remove grouping with { when not required.
  • [FIX] (PORTABILITY) Minor changes to some case statements which should now be more portable, though never showed any issues (e.g. add ;; to some statements where it was missing even though this was permitted.)
  • [FIX] (PORTABILITY) Use null string instead of no arguments for echo when intent is only to output a <newline>.
  • [FIX] (PORTABILITY) Minor changes to parameter expansion to avoid issues with ksh88.

libgetargs.sh & getarg v1.3.0

  • [FIX] Fixed an issue that would cause a failure under set -u when an unset user variable was used. (Although the failure may be useful, it breaks the principle that behavior is the same under set -u and set +u.)
  • [FIX] (PORTABILITY) Added trailing '\n' to printf - without it some implementations will effectively discard the last line of data.
  • [FIX] (PORTABILITY) Rewrote OPTION matching to be simpler and more portable: sed is now used in place of expr and grep for all matching; tr is required where previously use was based on config. (NOTES: Previously rejected OPTION-CONFIG may now be accepted; performance characteristics may have changed, however overall performance was not measurably altered.)
  • [FIX] (PORTABILITY) Minor changes to some case statements which should now be more portable, though never showed any issues (e.g. add ;; to some statements where it was missing even though this was permitted.)

libdeque.sh v1.1.0

  • [FIX] (PORTABILITY) Added workarounds for grep where '-F' is not available. (Assumes fgrep is available in this case - this may change.)
  • [FIX] (PORTABILITY) Removed - when used to indicate input is from STDIN.
  • [FIX] (PORTABILITY) Minor changes to parameter expansion to avoid issues with ksh88 and posh.

Other

  • [FIX] Makefile doc generation (typo caused incorrect behavior outside GNU tools).
  • [FIX] (PORTABILITY) Fixes to test harness and tests for portablity.
  • [NEW] Added support for more auto-detected shells in test harness.
  • [CHANGE] Documentation updates & edits.

Full Changelog: v2024-06-29...v2024-08-14