From 0284b8765e79e544e7086ea50a90c4add4748f03 Mon Sep 17 00:00:00 2001 From: Joe Groocock Date: Tue, 3 Oct 2017 10:15:34 +0100 Subject: [PATCH] zshrc: ensure GPG prompt is the current TTY --- .zshrc | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/.zshrc b/.zshrc index 5d12551..ea93de4 100644 --- a/.zshrc +++ b/.zshrc @@ -17,6 +17,12 @@ HISTSIZE=100000 SAVEHIST=100000 setopt sharehistory histignoredups histignorespace histreduceblanks autocd autopushd extendedglob alwaystoend dvorak +# Only set tty if running interactively +if tty -s; then + # Resolve at shell runtime + export GPG_TTY="$(tty)" +fi + export WORDCHARS='*?_[]~=&;!#$%^(){}' bindkey -e