From 0da0d0b643425bc9227c6364a427014b1f77e553 Mon Sep 17 00:00:00 2001 From: Johannes Löthberg Date: Wed, 15 Oct 2014 18:49:01 +0200 Subject: leeloo-profile stuff should only be sourced as my user.. --- zsh/profile-leeloo | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) (limited to 'zsh') diff --git a/zsh/profile-leeloo b/zsh/profile-leeloo index aa2f947..96d23b3 100644 --- a/zsh/profile-leeloo +++ b/zsh/profile-leeloo @@ -1,11 +1,12 @@ -export LD_PRELOAD="$HOME"/.local/lib/libwcwidth.so +if (( UID )); then + export LD_PRELOAD="$HOME"/.local/lib/libwcwidth.so -export PERL5LIB="$HOME"/misc/grawity/code/lib/perl5"${PERL5LIB+:}$PERL5LIB"; -source <(perl -Mlocal::lib="$HOME"/.local) + export PERL5LIB="$HOME"/misc/grawity/code/lib/perl5"${PERL5LIB+:}$PERL5LIB"; + source <(perl -Mlocal::lib="$HOME"/.local) -export GPG_AGENT_INFO=/run/user/"$UID"/keyring/gpg:0:1 + export GPG_AGENT_INFO=/run/user/"$UID"/keyring/gpg:0:1 -function { + function { local envfile="$XDG_RUNTIME_DIR"/ssh-agent.env local pid=$(awk -F'[=;]' 'FNR == 2 {print $2}' "$envfile" 2>/dev/null) if [[ -n "$pid" ]] && kill -0 "$pid" &>/dev/null; then @@ -18,4 +19,5 @@ function { source "$HOME"/misc/grawity/code/kerberos/kc.sh +fi # vim: ft=zsh -- cgit v1.2.3-70-g09d2