From 449c1b246f133eb58045a4ebaa8c1f11d79f347b Mon Sep 17 00:00:00 2001 From: Tom Ryder Date: Mon, 22 Aug 2016 12:47:37 +1200 Subject: Move .bashrc interactivity test to top --- bash/bashrc | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/bash/bashrc b/bash/bashrc index d6b2adca..d2562749 100644 --- a/bash/bashrc +++ b/bash/bashrc @@ -1,3 +1,9 @@ +# Make sure the shell is interactive +case $- in + *i*) ;; + *) return ;; +esac + # Ensure we're using at least version 2.05. Weird arithmetic syntax needed here # due to leading zeroes and trailing letters in some 2.x version numbers (e.g. # 2.05a). @@ -6,12 +12,6 @@ ((10#${BASH_VERSINFO[1]%%[![:digit:]]*} < 5)) && return -# Make sure the shell is interactive -case $- in - *i*) ;; - *) return ;; -esac - # Don't do anything if running a restricted shell shopt -q restricted_shell && return -- cgit v1.2.3