$ git clone https://github.com/zx80live/bash-utils
$ cd ./bash-utils
# import util_files
$ source util_files
# create nested dirs if it isn't exist
$ touch_dir '/a/b/c/d/e/f'
# create file if it isn't exist including all nested dirs in its path
$ touch_file '/a/b/c/d/e/f/hello.txt'
# import util_logs
$ source util_logs
$ log_info 'some log info string'
$ log_err 'some err string'
$ log_debug 'some debug string'
# there is nothing in output, because log_level variable is LOG_LEVEL_INFO by default
$ export log_level=$LOG_LEVEL_DEBUG
$ log_debug 'some debug string'
# import util_text
$ source util_text
# list of available formats
$ strformats
$ strformat "Hello, World" CYAN BOLD ITALIC
$ strlen "Hello, World"
12
$ substring "0123456789ABCDEFGH" 10 3
ABC
$ strdrop_right "0123456789ABCDEFGH" 8
0123456789
$ strdrop_left "0123456789ABCDEFGH" 10
ABCDEFGH
$ strfill_right "ABC" '.' 10
ABC..........
$ strfill_left "ABC" '.' 10
..........ABC
$ strdecorate "some text" '~~' '~~'
~~some text~~
# get matched regex groups
$ strregex "Some string with some 123 number and SPECIAL word." '.*([0-9]{3}).*(SPECIAL).*'
Some string with some 123 number and SPECIAL word.
123
SPECIAL
$ strunwrap "~~some text~~" '~~' '~~'
some text
$ strtake_left "0123456789ABCDEFGH" 5
01234
$ strtake_right "0123456789ABCDEFGH" 5
DEFGH
$ strsplit 'A.B.C.D' '.'
A
B
C
D