add textblock formatting functions
This commit is contained in:
parent
e74971997f
commit
bbea5e871c
18
.vscode/numbered-bookmarks.json
vendored
18
.vscode/numbered-bookmarks.json
vendored
@ -1,3 +1,19 @@
|
|||||||
{
|
{
|
||||||
"bookmarks": []
|
"bookmarks": [
|
||||||
|
{
|
||||||
|
"fsPath": "$ROOTPATH$/pilerBackup/pilerbackup.sh",
|
||||||
|
"bookmarks": [
|
||||||
|
-1,
|
||||||
|
113,
|
||||||
|
-1,
|
||||||
|
-1,
|
||||||
|
-1,
|
||||||
|
-1,
|
||||||
|
-1,
|
||||||
|
-1,
|
||||||
|
-1,
|
||||||
|
-1
|
||||||
|
]
|
||||||
|
}
|
||||||
|
]
|
||||||
}
|
}
|
@ -184,6 +184,18 @@ stamp () {
|
|||||||
(date +%F" "%T)
|
(date +%F" "%T)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
textblock() {
|
||||||
|
printf "%s\n" "$1" | fold -w "$width" -s
|
||||||
|
}
|
||||||
|
|
||||||
|
switchTextblock() {
|
||||||
|
printf "%s%s%s\n" "$yellow" "$1" "$norm"
|
||||||
|
}
|
||||||
|
|
||||||
|
newline() {
|
||||||
|
printf "\n"
|
||||||
|
}
|
||||||
|
|
||||||
# same as exitError but for signal captures
|
# same as exitError but for signal captures
|
||||||
trapExit () {
|
trapExit () {
|
||||||
printf "${err}[%s] -- [ERROR] 99: Caught signal --${norm}\n" \
|
printf "${err}[%s] -- [ERROR] 99: Caught signal --${norm}\n" \
|
||||||
|
Loading…
Reference in New Issue
Block a user