From 9e0019a30f6c132c0b30c5f2ff6cf3c290dc4a12 Mon Sep 17 00:00:00 2001 From: SoniEx2 Date: Tue, 30 Jul 2024 22:40:38 -0300 Subject: Initial commit --- skullbashed | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) create mode 100755 skullbashed diff --git a/skullbashed b/skullbashed new file mode 100755 index 0000000..72bc92b --- /dev/null +++ b/skullbashed @@ -0,0 +1,17 @@ +#!/usr/bin/env bash +# SkullbashEd - inspired by ed(1) +if [ -z "$1" ]; then + echo 'A filename is required' + exit 1 +fi +unset HISTFILE +bash --init-file <(printf '%s\n' \ + 'source ~/.bashrc' \ + 'HISTFILESIZE=-1' \ + 'HISTCONTROL=ignorespace' \ + ; + printf 'HISTFILE=%q\n' "$1" + printf '%s\n' \ + 'history -c' \ + ; +) -- cgit 1.4.1