Skip to main content
added 128 characters in body
Source Link
nohillside
  • 104.5k
  • 42
  • 222
  • 275

The code for this is in /etc/{bashrc,zshrc}_Apple_Terminal, in the default configuration it includesensures that shell history is preserved even if you have several tabs open in Terminal.

Both files include details about configuration options and also lists the wayexplain how to disable it as a whole.

To disable in zsh

# The save/restore mechanism as a whole can be disabled by setting an
# environment variable (typically in `${ZDOTDIR:-$HOME}/.zshenv`):
#
#   SHELL_SESSIONS_DISABLE=1

To disable in bash

# The save/restore mechanism is disabled if the following file exists:
#
#   ~/.bash_sessions_disable

The code for this is in /etc/{bashrc,zshrc}_Apple_Terminal, it includes details about configuration options and also lists the way to disable it as a whole.

To disable in zsh

# The save/restore mechanism as a whole can be disabled by setting an
# environment variable (typically in `${ZDOTDIR:-$HOME}/.zshenv`):
#
#   SHELL_SESSIONS_DISABLE=1

To disable in bash

# The save/restore mechanism is disabled if the following file exists:
#
#   ~/.bash_sessions_disable

The code for this is in /etc/{bashrc,zshrc}_Apple_Terminal, in the default configuration it ensures that shell history is preserved even if you have several tabs open in Terminal.

Both files include details about configuration options and also explain how to disable it as a whole.

To disable in zsh

# The save/restore mechanism as a whole can be disabled by setting an
# environment variable (typically in `${ZDOTDIR:-$HOME}/.zshenv`):
#
#   SHELL_SESSIONS_DISABLE=1

To disable in bash

# The save/restore mechanism is disabled if the following file exists:
#
#   ~/.bash_sessions_disable
Source Link
nohillside
  • 104.5k
  • 42
  • 222
  • 275

The code for this is in /etc/{bashrc,zshrc}_Apple_Terminal, it includes details about configuration options and also lists the way to disable it as a whole.

To disable in zsh

# The save/restore mechanism as a whole can be disabled by setting an
# environment variable (typically in `${ZDOTDIR:-$HOME}/.zshenv`):
#
#   SHELL_SESSIONS_DISABLE=1

To disable in bash

# The save/restore mechanism is disabled if the following file exists:
#
#   ~/.bash_sessions_disable