Only set shell variables for the specific shell

Signed-off-by: Severin Kaderli <severin@kaderli.dev>
This commit is contained in:
Severin Kaderli 2023-02-09 13:35:39 +01:00
parent 1c8f55b666
commit 9dc64008ea
Signed by: severinkaderli
GPG key ID: F419F8835B72F0C4
2 changed files with 7 additions and 6 deletions

View file

@ -1,5 +0,0 @@
# Zsh
HISTCONTROL="ignoreboth"
HISTSIZE="10000"
SAVEHIST="${HISTSIZE}"
HISTFILESIZE="${HISTSIZE}"

View file

@ -12,9 +12,15 @@
# USAGE:
# This script is automatically executed when you start a login shell.
# Load env variables
# Load env variables (might have problems with spaces on Zsh)
export $(/usr/lib/systemd/user-environment-generators/30-systemd-environment-d-generator)
# Set shell specific env variables
export HISTCONTROL="ignoreboth"
export HISTSIZE="10000"
export SAVEHIST="${HISTSIZE}"
export HISTFILESIZE="${HISTSIZE}"
if [[ -f "${HOME}/.config/zsh/.zshrc" ]]; then
. "${HOME}/.config/zsh/.zshrc"
fi