diff --git a/.local/bin/scripts/ex b/.local/bin/scripts/ex index 9973b3d..52540e5 100755 --- a/.local/bin/scripts/ex +++ b/.local/bin/scripts/ex @@ -1,6 +1,7 @@ #!/bin/sh -e # ex - archive extractor # usage: ex +# depends: rewrite(in dotfiles) for arg do if test -r "$arg"; then path="$(realpath "$arg")" diff --git a/.local/bin/scripts/rewrite b/.local/bin/scripts/rewrite new file mode 100755 index 0000000..1b1c31e --- /dev/null +++ b/.local/bin/scripts/rewrite @@ -0,0 +1,3 @@ +#!/bin/sh +# Pipe a command into this and each output line will rewrite the previous one +sed --unbuffered '2,$s|^|\\e[1A\\e[K|' | xargs -d '\n' -L 1 echo -e