Delete command line history permanently?
-
BallerShotCaller -
March 15, 2020 at 8:36 AM -
Thread is Unresolved
-
-
Delete
/storage/.ash_history
-
Delete
/storage/.ash_history
Thank you, this works for a one-time erase. But what I really want is to disable history completely.
The command
gives me the following output
so I've tried the following command which is being executed without any error
but after exit and login via SSH the /storage/.ash_history file is being created again.
-
Well, after messing around with this a while now I did not found the solution but I want to share my workaround with you which will delete the according history file on every system startup, system halt, system reboot and system poweroff/shutdown:
According to this tutorial I have created the two files autostart.sh and shutdown.sh inside the /storage/.config folder:
Content of autostart.sh:
Contect of shutdown.sh:
Code
Display Morecase "$1" in halt) # your commands here ;; poweroff) # your commands here ;; reboot) # your commands here ;; *) rm -rf /storage/.ash_history ;; esac
After creating those files with the according content make both files executable:
Maybe this helps someone else but me too.