Monday, July 2, 2018

Bash to save history with time stamp

Some Useful bashrc stuff

Please put below in /etc/bash.bashrc

## No duplicates in the history
export HISTCONTROL=ignoredups

## for setting history length see HISTSIZE and HISTFILESIZE in bash
export HISTSIZE=100000
export HISTFILESIZE=100000

## Timestamp history
export HISTTIMEFORMAT="%b %d %a %T "

## Don't Overwrite. Append to bash history.
shopt -s histappend

##Adding costume $PATH
export PATH="/usr/local/zabbix/bin:$PATH"

##Adding Vim as default editor
export EDITOR=vim

No comments:

Post a Comment

Renew k8s certificates

Check If certificate expires: amikum@~:03:06:54(⎈ |local-cluster:default):sudo kubeadm certs check-expiration CERTIFICATE                EXP...