You are not logged in.

#1 2016-04-14 15:34:48

inkdinky
Member
Registered: 2011-12-08
Posts: 66

Bash history disappearing? Or not being written to?

I am guilty of being lazy and sometimes I use my bash history as a set of aliases.
I also use tmux in my terminals. After restarts it appears as if my bash history has disappeared.
I'm unclear if it is a bash upgrade that simply starts anew or if tmux keeps its own bash history and I'm expecting to see items typed in tmux to persist after a reboot.
I'm guessing it is a bit of the =http://askubuntu.com/a/339925]latter.

Sorry for the vague question but I'm still trying to pin down when exactly things happen.

Offline

#2 2016-04-14 17:48:11

jasonwryan
Anarchist
From: .nz
Registered: 2009-05-09
Posts: 30,426
Website

Re: Bash history disappearing? Or not being written to?

What does this mean: "I use my bash history as a set of aliases"?
Please paste your .bashrc


Arch + dwm   •   Mercurial repos  •   Surfraw

Registered Linux User #482438

Offline

#3 2016-04-14 18:00:14

inkdinky
Member
Registered: 2011-12-08
Posts: 66

Re: Bash history disappearing? Or not being written to?

I meant it to mean that instead of adding an alias to my .bashrc e.g. alias Foo="python /dir/to/some/script.py -someoption=bar"  I will just Ctrl+R 'python' until I find the command I'd used previously as it was logged in history.

#
# ~/.bashrc
#

# If not running interactively, don't do anything
[[ $- != *i* ]] && return

alias ls='ls --color=auto'
PS1='[\u@\h \W]\$ '

[[ -s /home/fubar/.nvm/nvm.sh ]] && . /home/fubar/.nvm/nvm.sh 

alias SRC='source ~/.bashrc'
alias df='df -h'
alias pythonServe='python2 -m SimpleHTTPServer'

Offline

Board footer

Powered by FluxBB