mirror of
https://github.com/notwa/rc
synced 2024-05-20 10:53:23 -07:00
flesh out the compatibility table
This commit is contained in:
parent
9dc69caebd
commit
112a7a6d63
1
sh/arith
1
sh/arith
|
@ -2,6 +2,7 @@
|
|||
# YES_ZSH
|
||||
# YES_BASH
|
||||
# YES_DASH
|
||||
# YES_ASH
|
||||
|
||||
# though technically compatible with other shells,
|
||||
# extra functionality is through zsh's extended arithmetic functions.
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
# YES_ZSH
|
||||
# NO_BASH
|
||||
# NO_DASH
|
||||
# NO_ASH
|
||||
|
||||
# TODO: portable way of dodging aliases to allow other shell support?
|
||||
|
||||
|
|
3
sh/bak
3
sh/bak
|
@ -2,6 +2,7 @@
|
|||
# YES_ZSH
|
||||
# YES_BASH
|
||||
# YES_DASH
|
||||
# YES_ASH
|
||||
|
||||
bak() { ### @-
|
||||
### backup files by creating copies and appending ".bak" to their names.
|
||||
|
@ -20,7 +21,7 @@ bak() { ### @-
|
|||
### ```
|
||||
[ $# -gt 0 ] || { printf "%s\n" "$0: too few arguments" >&2; return 1; }
|
||||
local ret=0
|
||||
local f
|
||||
local f=
|
||||
for f; do
|
||||
if [ -e "$f.bak" ]; then
|
||||
bak "$f.bak" || { ret=1; continue; }
|
||||
|
|
1
sh/baks
1
sh/baks
|
@ -3,6 +3,7 @@
|
|||
# YES_ZSH
|
||||
# YES_BASH
|
||||
# YES_DASH
|
||||
# YES_ASH
|
||||
|
||||
baks() { ### @-
|
||||
### backup files by copying each and appending *the current* date-time,
|
||||
|
|
1
sh/bin
1
sh/bin
|
@ -2,6 +2,7 @@
|
|||
# YES_ZSH
|
||||
# YES_BASH
|
||||
# YES_DASH
|
||||
# YES_ASH
|
||||
|
||||
# though technically compatible with other shells,
|
||||
# extra functionality is through zsh's extended arithmetic functions.
|
||||
|
|
|
@ -1,5 +1,8 @@
|
|||
#!/usr/bin/env zsh
|
||||
# YES_ZSH
|
||||
# NO_BASH
|
||||
# NO_DASH
|
||||
# NO_ASH
|
||||
|
||||
cdbusiest() { ### @-
|
||||
### cd to the directory with the most files in it, counted recursively.
|
||||
|
@ -17,4 +20,6 @@ cdbusiest() { ### @-
|
|||
cd $d
|
||||
}
|
||||
|
||||
[ -n "${preload+-}" ] || . ~/sh/preload || exit 2
|
||||
eval ${preload:-preload} dbusiest
|
||||
[ -n "${preload+-}" ] || cdbusiest "$@"
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
# YES_ZSH
|
||||
# YES_BASH
|
||||
# NO_DASH
|
||||
# NO_ASH
|
||||
|
||||
colors() { ### @-
|
||||
### display all combinations of foreground and background terminal colors.
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
# YES_ZSH
|
||||
# NO_BASH
|
||||
# NO_DASH
|
||||
# NO_ASH
|
||||
|
||||
setup_clang_ubuntu() { ### @-
|
||||
### print (but don't execute) the commands necessary to install
|
||||
|
|
1
sh/cutv
1
sh/cutv
|
@ -2,6 +2,7 @@
|
|||
# YES_ZSH
|
||||
# NO_BASH
|
||||
# NO_DASH
|
||||
# NO_ASH
|
||||
|
||||
cutv() { ### @-
|
||||
### (WIP) create a short clip of a long video file.
|
||||
|
|
1
sh/days
1
sh/days
|
@ -2,6 +2,7 @@
|
|||
# YES_ZSH
|
||||
# YES_BASH
|
||||
# YES_DASH
|
||||
# YES_ASH
|
||||
|
||||
days() { ### @-
|
||||
### compute the number of days since a given date.
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
# YES_ZSH
|
||||
# NO_BASH
|
||||
# NO_DASH
|
||||
# NO_ASH
|
||||
|
||||
dbusiest() { ### @-
|
||||
### list directories ordered descending by the number of files in them,
|
||||
|
|
3
sh/dfu
3
sh/dfu
|
@ -2,6 +2,9 @@
|
|||
# YES_ZSH
|
||||
# YES_BASH
|
||||
# YES_DASH
|
||||
# YES_ASH
|
||||
|
||||
# works with busybox awk.
|
||||
|
||||
dfu() { ### @-
|
||||
### pretty-print `df` in GiB.
|
||||
|
|
3
sh/disf
3
sh/disf
|
@ -2,9 +2,8 @@
|
|||
# disassembles a function given its symbolic name.
|
||||
# YES_ZSH
|
||||
# YES_BASH
|
||||
# YES_DASH
|
||||
|
||||
# TODO: actually test that this works with dash.
|
||||
# does not work with busybox sed (yet?)
|
||||
|
||||
disf() { ### @-
|
||||
### disassemble a single function from an unstripped executable, unreliably.
|
||||
|
|
1
sh/e
1
sh/e
|
@ -2,6 +2,7 @@
|
|||
# YES_ZSH
|
||||
# NO_BASH
|
||||
# NO_DASH
|
||||
# NO_ASH
|
||||
|
||||
e() { ### @-
|
||||
### wrap around `$EDITOR` to run it as root if necessary.
|
||||
|
|
1
sh/ea
1
sh/ea
|
@ -3,6 +3,7 @@
|
|||
# YES_ZSH
|
||||
# YES_BASH
|
||||
# YES_DASH
|
||||
# YES_ASH
|
||||
|
||||
ea() { ### @- **TODO:** document.
|
||||
local cmd="${1:?missing subcommand}"; shift
|
||||
|
|
1
sh/echo2
1
sh/echo2
|
@ -2,6 +2,7 @@
|
|||
# YES_ZSH
|
||||
# YES_BASH
|
||||
# YES_DASH
|
||||
# YES_ASH
|
||||
|
||||
echo2() { ### @-
|
||||
### print arguments joined by spaces to stderr without parsing anything.
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
# YES_ZSH
|
||||
# YES_BASH
|
||||
# YES_DASH
|
||||
# YES_ASH
|
||||
|
||||
explore() { ### @- open a single directory in `explorer.exe`, defaulting to `$PWD`.
|
||||
[ -n "$MSYSTEM" ] || { printf "%s\n" "$0: only for MSYS2" >&2; return 1; }
|
||||
|
|
1
sh/ghmd
1
sh/ghmd
|
@ -5,6 +5,7 @@
|
|||
# YES_ZSH
|
||||
# YES_BASH
|
||||
# YES_DASH
|
||||
# YES_ASH
|
||||
|
||||
ghmd() { ### @-
|
||||
### convert a markdown file to HTML in the style of GitHub.
|
||||
|
|
1
sh/has
1
sh/has
|
@ -2,6 +2,7 @@
|
|||
# YES_ZSH
|
||||
# YES_BASH
|
||||
# YES_DASH
|
||||
# YES_ASH
|
||||
|
||||
has() { ### @-
|
||||
### print the result of `which` if the program is found, else simply return 1.
|
||||
|
|
1
sh/hex
1
sh/hex
|
@ -2,6 +2,7 @@
|
|||
# YES_ZSH
|
||||
# YES_BASH
|
||||
# YES_DASH
|
||||
# YES_ASH
|
||||
|
||||
# though technically compatible with other shells,
|
||||
# extra functionality is through zsh's extended arithmetic functions.
|
||||
|
|
1
sh/ify
1
sh/ify
|
@ -2,6 +2,7 @@
|
|||
# YES_ZSH
|
||||
# YES_BASH
|
||||
# YES_DASH
|
||||
# YES_ASH
|
||||
|
||||
ify() { ### @-
|
||||
### pipe one command through another, so you can still pass arguments to the former.
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
# YES_ZSH
|
||||
# YES_BASH
|
||||
# NO_DASH
|
||||
# NO_ASH
|
||||
|
||||
is_empty() { ### @-
|
||||
### return 0 if the directory given by argument is empty.
|
||||
|
|
1
sh/isup
1
sh/isup
|
@ -2,6 +2,7 @@
|
|||
# YES_ZSH
|
||||
# YES_BASH
|
||||
# YES_DASH
|
||||
# YES_ASH
|
||||
|
||||
isup() { ### @-
|
||||
### return 0 if a given website returns a 2xx HTTP code.
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
# YES_ZSH
|
||||
# YES_BASH
|
||||
# YES_DASH
|
||||
# YES_ASH
|
||||
|
||||
maybesudo_() { ### @-
|
||||
### mimic certain features of `sudo` for systems without it installed.
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
# YES_ZSH
|
||||
# YES_BASH
|
||||
# YES_DASH
|
||||
# YES_ASH
|
||||
|
||||
minutemaid() { ### @-
|
||||
### return 0 and/or execute a command if the current minute
|
||||
|
|
|
@ -1,5 +1,8 @@
|
|||
#!/usr/bin/env zsh
|
||||
# YES_ZSH
|
||||
# NO_BASH
|
||||
# NO_DASH
|
||||
# NO_ASH
|
||||
|
||||
monitor() { ### @-
|
||||
### this is [watch(1)](https://www.man7.org/linux/man-pages/man1/watch.1.html)
|
||||
|
|
|
@ -1,14 +1,15 @@
|
|||
#!/usr/bin/env sh
|
||||
# the first expression is taken from this FAQ:
|
||||
# https://perldoc.perl.org/perlfaq6.html#How-do-I-use-a-regular-expression-to-strip-C-style-comments-from-a-file%3f
|
||||
# YES_ZSH
|
||||
# YES_BASH
|
||||
# YES_DASH
|
||||
# YES_ASH
|
||||
|
||||
# TODO: what's the minimum version of perl required for this?
|
||||
|
||||
noccom() { ### @-
|
||||
### strip C-like comments; both multi-line and single-line.
|
||||
# the first expression is taken from this FAQ:
|
||||
# https://perldoc.perl.org/perlfaq6.html#How-do-I-use-a-regular-expression-to-strip-C-style-comments-from-a-file%3f
|
||||
[ -s ~/opt/local/bin/noccom ] || cat > ~/opt/local/bin/noccom <<EOF
|
||||
#!/usr/bin/env perl
|
||||
|
||||
|
|
1
sh/note
1
sh/note
|
@ -2,6 +2,7 @@
|
|||
# YES_ZSH
|
||||
# YES_BASH
|
||||
# YES_DASH
|
||||
# YES_ASH
|
||||
|
||||
note() { ### @-
|
||||
### act like [`echo2`,](#echo2) but use a bright color to stand out more.
|
||||
|
|
15
sh/now
15
sh/now
|
@ -2,8 +2,7 @@
|
|||
# YES_ZSH
|
||||
# YES_BASH
|
||||
# YES_DASH
|
||||
|
||||
# dash compatibility is not fully tested, but it's probably okay.
|
||||
# YES_ASH
|
||||
|
||||
now() { ### @-
|
||||
### print a date-time (UTC) in a sortable format.
|
||||
|
@ -18,8 +17,8 @@ now() { ### @-
|
|||
### 2009-02-13_84690000
|
||||
### ```
|
||||
[ $# -le 1 ] || { printf "%s\n" "$0: too many arguments" >&2; return 1; }
|
||||
local dt
|
||||
local fmt='+%F_%T_%N'
|
||||
|
||||
local dt= fmt='+%F_%T_%N'
|
||||
if [ -z "$1" ]; then
|
||||
dt="$(date -u "$fmt")"
|
||||
elif [ -e "$1" ]; then
|
||||
|
@ -28,12 +27,12 @@ now() { ### @-
|
|||
dt="$(date -u -d "$1" "$fmt")"
|
||||
fi
|
||||
|
||||
local F T N
|
||||
local F= T= N=
|
||||
F=${dt%%_*}
|
||||
T=${dt#*_}
|
||||
T=${T%_*}
|
||||
N=${dt##*_}
|
||||
local H M S
|
||||
local H= M= S=
|
||||
H=${T%%:*}
|
||||
M=${T#*:}
|
||||
M=${M%:*}
|
||||
|
@ -47,8 +46,8 @@ now() { ### @-
|
|||
M=${M#0*}
|
||||
S=${S#0*}
|
||||
|
||||
local ms
|
||||
ms=$(((H*60*60+M*60+S)*1000+N/1000000))
|
||||
local ms=
|
||||
ms=$(( (H*60*60+M*60+S)*1000+N/1000000 ))
|
||||
ms=$(printf '%08i' $ms)
|
||||
echo "${F}_${ms}"
|
||||
}
|
||||
|
|
3
sh/pacbm
3
sh/pacbm
|
@ -2,6 +2,9 @@
|
|||
# YES_ZSH
|
||||
# YES_BASH
|
||||
# YES_DASH
|
||||
# YES_ASH
|
||||
|
||||
# TODO: does this work with busybox awk?
|
||||
|
||||
pacbm() { ### @-
|
||||
### display and order installed pacman packages by their filesize ascending,
|
||||
|
|
1
sh/pause
1
sh/pause
|
@ -2,6 +2,7 @@
|
|||
# YES_ZSH
|
||||
# YES_BASH
|
||||
# NO_DASH
|
||||
# NO_ASH
|
||||
|
||||
pause() { ### @-
|
||||
### pause — the companion script of [`confirm`.](#confirm)
|
||||
|
|
5
sh/pegg
5
sh/pegg
|
@ -2,8 +2,7 @@
|
|||
# YES_ZSH
|
||||
# YES_BASH
|
||||
# YES_DASH
|
||||
|
||||
# TODO: source pippy here? this may affect dash compatibility.
|
||||
# YES_ASH
|
||||
|
||||
pegg() { ### @-
|
||||
### download and (pip) install a Python "egg" from a project on GitHub,
|
||||
|
@ -19,4 +18,6 @@ pegg() { ### @-
|
|||
pippy "https://github.com/$1/$2/tarball/${3:-master}#egg=$2"
|
||||
}
|
||||
|
||||
[ -n "${preload+-}" ] || . ~/sh/preload || exit 2
|
||||
eval ${preload:-preload} pippy
|
||||
[ -n "${preload+-}" ] || pegg "$@"
|
||||
|
|
10
sh/pippy
10
sh/pippy
|
@ -1,15 +1,17 @@
|
|||
#!/usr/bin/env sh
|
||||
# YES_ZSH
|
||||
|
||||
#. ~/sh/maybesudo
|
||||
#. ~/sh/has
|
||||
# YES_BASH
|
||||
# YES_DASH
|
||||
# YES_ASH
|
||||
|
||||
pippy() { ### @-
|
||||
### install Python packages using pip,
|
||||
### but only update their dependencies as required.
|
||||
### this uses [`maybesudo`](#maybesudo_-shmaybesudo) internally.
|
||||
local sudo="$(has sudo || echo maybesudo_)"
|
||||
"$sudo" py -m pip install --upgrade --upgrade-strategy only-if-needed "$@"
|
||||
"$sudo" python3 -m pip install --upgrade --upgrade-strategy only-if-needed "$@"
|
||||
}
|
||||
|
||||
[ -n "${preload+-}" ] || . ~/sh/preload || exit 2
|
||||
eval ${preload:-preload} has maybesudo
|
||||
[ -n "${preload+-}" ] || pippy "$@"
|
||||
|
|
1
sh/pre
1
sh/pre
|
@ -2,6 +2,7 @@
|
|||
# YES_ZSH
|
||||
# YES_BASH
|
||||
# YES_DASH
|
||||
# YES_ASH
|
||||
|
||||
pre() { ### @-
|
||||
### dump all the `#define`s that `$CC $CPPFLAGS $CFLAGS $LDFLAGS` would result in.
|
||||
|
|
1
sh/psbm
1
sh/psbm
|
@ -2,6 +2,7 @@
|
|||
# YES_ZSH
|
||||
# YES_BASH
|
||||
# YES_DASH
|
||||
# YES_ASH
|
||||
|
||||
psbm() { ### @-
|
||||
### display and order processes by their memory usage ascending, and their sum.
|
||||
|
|
|
@ -2,6 +2,9 @@
|
|||
# YES_ZSH
|
||||
# YES_BASH
|
||||
# YES_DASH
|
||||
# YES_ASH
|
||||
|
||||
# works with busybox.
|
||||
|
||||
randir() { ### @-
|
||||
### display a random directory in the current working directory.
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
# YES_ZSH
|
||||
# YES_BASH
|
||||
# YES_DASH
|
||||
# YES_ASH
|
||||
|
||||
refresh() { ### @- invoke `hash -r`.
|
||||
hash -r
|
||||
|
|
3
sh/rot13
3
sh/rot13
|
@ -2,6 +2,9 @@
|
|||
# YES_ZSH
|
||||
# YES_BASH
|
||||
# YES_DASH
|
||||
# YES_ASH
|
||||
|
||||
# works with busybox tr.
|
||||
|
||||
rot13() { ### @-
|
||||
### rot13 with numbers rotated as well.
|
||||
|
|
3
sh/rs
3
sh/rs
|
@ -1,5 +1,8 @@
|
|||
#!/usr/bin/env zsh
|
||||
# YES_ZSH
|
||||
# NO_BASH
|
||||
# NO_DASH
|
||||
# NO_ASH
|
||||
|
||||
rs() { ### @-
|
||||
### record screen. does not record audio.
|
||||
|
|
8
sh/sc
8
sh/sc
|
@ -1,4 +1,8 @@
|
|||
#!/usr/bin/env bash
|
||||
# NO_ZSH
|
||||
# YES_BASH
|
||||
# NO_DASH
|
||||
# NO_ASH
|
||||
|
||||
sc_shorten() {
|
||||
REPLY="${1:2:2}${1:5:2}${1:8:2}${1:11:12}"
|
||||
|
@ -16,7 +20,7 @@ copy_scr() {
|
|||
local r='20\d\d-\d\d-\d\d_\d\d\d\d\d\d\d\d.(png|jpg)'
|
||||
grep -Pq "$r" <<<"$short" || return 1
|
||||
|
||||
eaput "$fn" "$short"
|
||||
ea put "$fn" "$short"
|
||||
sc_shorten "$short"
|
||||
uri_encode "$REPLY"
|
||||
REPLY="$_REMOTE_DOMAIN/s/$REPLY"
|
||||
|
@ -27,7 +31,7 @@ copy_tmp() {
|
|||
local fn="$1"
|
||||
local short="$(basename "$fn")"
|
||||
|
||||
eaput "$fn" "$short"
|
||||
ea put "$fn" "$short"
|
||||
uri_encode "$short"
|
||||
REPLY="$_REMOTE_DOMAIN/t/$REPLY"
|
||||
return 0
|
||||
|
|
|
@ -2,6 +2,9 @@
|
|||
# YES_ZSH
|
||||
# YES_BASH
|
||||
# YES_DASH
|
||||
# YES_ASH
|
||||
|
||||
# does not work with busybox sed (yet?)
|
||||
|
||||
scramble() { ### @-
|
||||
### scrambles text in a predictable way using regex.
|
||||
|
|
|
@ -1,5 +1,8 @@
|
|||
#!/usr/bin/env zsh
|
||||
# YES_ZSH
|
||||
# YES_BASH
|
||||
# NO_DASH
|
||||
# NO_ASH
|
||||
|
||||
screeny() { ### @-
|
||||
### handle GNU screens.
|
||||
|
|
|
@ -2,6 +2,9 @@
|
|||
# YES_ZSH
|
||||
# YES_BASH
|
||||
# YES_DASH
|
||||
# YES_ASH
|
||||
|
||||
# does not work with busybox awk (yet?)
|
||||
|
||||
similar() { ### @-
|
||||
### highlight adjacent lines up to the first inequivalent character.
|
||||
|
|
3
sh/slit
3
sh/slit
|
@ -2,6 +2,9 @@
|
|||
# YES_ZSH
|
||||
# YES_BASH
|
||||
# YES_DASH
|
||||
# YES_ASH
|
||||
|
||||
# works with busybox ash.
|
||||
|
||||
slit() { ### @-
|
||||
### view specific columns of text.
|
||||
|
|
3
sh/slitt
3
sh/slitt
|
@ -2,6 +2,9 @@
|
|||
# YES_ZSH
|
||||
# YES_BASH
|
||||
# YES_DASH
|
||||
# YES_ASH
|
||||
|
||||
# works with busybox ash.
|
||||
|
||||
slitt() { ### @-
|
||||
### view specific columns of text.
|
||||
|
|
|
@ -2,6 +2,8 @@
|
|||
# awful things
|
||||
# YES_ZSH
|
||||
# YES_BASH
|
||||
# NO_DASH
|
||||
# NO_ASH
|
||||
|
||||
mpvs() { ### @- invoke mpv with some extra flags suited for streamed sources.
|
||||
mpv --quiet \
|
||||
|
|
1
sh/sum
1
sh/sum
|
@ -2,6 +2,7 @@
|
|||
# YES_ZSH
|
||||
# YES_BASH
|
||||
# YES_DASH
|
||||
# YES_ASH
|
||||
|
||||
sum() { ### @-
|
||||
### compute the summation of its arguments without forking processes.
|
||||
|
|
3
sh/sv
3
sh/sv
|
@ -2,6 +2,9 @@
|
|||
# YES_ZSH
|
||||
# YES_BASH
|
||||
# YES_DASH
|
||||
# YES_ASH
|
||||
|
||||
# works with busybox awk.
|
||||
|
||||
sv() { ### @-
|
||||
### collect the lastmost value of every key.
|
||||
|
|
1
sh/tpad
1
sh/tpad
|
@ -2,6 +2,7 @@
|
|||
# YES_ZSH
|
||||
# YES_BASH
|
||||
# YES_DASH
|
||||
# YES_ASH
|
||||
|
||||
tpad() { ### @-
|
||||
### add a 1px transparent border around an image to prevent twitter from mangling it into a jpg.
|
||||
|
|
1
sh/trash
1
sh/trash
|
@ -2,6 +2,7 @@
|
|||
# YES_ZSH
|
||||
# YES_BASH
|
||||
# YES_DASH
|
||||
# YES_ASH
|
||||
|
||||
trash() { ### @-
|
||||
### output a given number of bytes from `/dev/random`.
|
||||
|
|
3
sh/trunc
3
sh/trunc
|
@ -2,6 +2,9 @@
|
|||
# YES_ZSH
|
||||
# YES_BASH
|
||||
# YES_DASH
|
||||
# YES_ASH
|
||||
|
||||
# does not work with busybox awk (yet?)
|
||||
|
||||
trunc() { ### @-
|
||||
### truncate text to fit within your terminal using the unicode character `…`.
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
# YES_ZSH
|
||||
# NO_BASH
|
||||
# NO_DASH
|
||||
# NO_ASH
|
||||
|
||||
unscreen() { ### @-
|
||||
### handle closing of screens — this works alongside [`screeny`](#screeny).
|
||||
|
|
1
sh/wat
1
sh/wat
|
@ -2,6 +2,7 @@
|
|||
# YES_ZSH
|
||||
# NO_BASH
|
||||
# NO_DASH
|
||||
# NO_ASH
|
||||
|
||||
# wat - a better and recursive which/whence
|
||||
# via: https://leahneukirchen.org/dotfiles/tools.html
|
||||
|
|
5
sh/wipe
5
sh/wipe
|
@ -2,6 +2,7 @@
|
|||
# YES_ZSH
|
||||
# YES_BASH
|
||||
# YES_DASH
|
||||
# YES_ASH
|
||||
|
||||
wipe() { ### @-
|
||||
### clear the screen and its scrollback, then print a high-contrast horizontal line.
|
||||
|
@ -12,13 +13,13 @@ wipe() { ### @-
|
|||
[ $# -le 0 ] || { printf "%s\n" "$0: too many arguments" >&2; return 1; }
|
||||
clear
|
||||
clear # twice because mintty is weird
|
||||
echo $'\033[30m\033[107m' | tr -d '$'
|
||||
printf '\033[30m\033[107m\n'
|
||||
if [ -n "${ZSH_VERSION:-}" ]; then
|
||||
printf '*%.0s' {1..$COLUMNS}
|
||||
else
|
||||
tput cols | awk '{for(i=0;i<$0;i++)printf "*"}'
|
||||
fi
|
||||
echo $'\033[0m\n' | tr -d '$'
|
||||
printf '\033[0m\n\n'
|
||||
}
|
||||
|
||||
[ -n "${preload+-}" ] || wipe "$@"
|
||||
|
|
Loading…
Reference in New Issue
Block a user