ansible_host: ShellCheck fixes
This commit is contained in:
parent
3e216a2d30
commit
fd7e470914
1 changed files with 7 additions and 3 deletions
|
@ -1,3 +1,4 @@
|
||||||
|
# shellcheck shell=sh
|
||||||
# .bashrc
|
# .bashrc
|
||||||
|
|
||||||
# User specific aliases and functions
|
# User specific aliases and functions
|
||||||
|
@ -8,12 +9,15 @@ alias mv='mv -i'
|
||||||
|
|
||||||
# Source global definitions
|
# Source global definitions
|
||||||
if [ -f /etc/bashrc ]; then
|
if [ -f /etc/bashrc ]; then
|
||||||
|
# shellcheck source=/dev/null
|
||||||
. /etc/bashrc
|
. /etc/bashrc
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# make sure that ssh agent is running and connect to it
|
# make sure that ssh agent is running and connect to it
|
||||||
[ -f /root/.ssh/agent ] && source /root/.ssh/agent > /dev/null
|
# shellcheck source=/dev/null
|
||||||
if ! kill -0 "${SSH_AGENT_PID}" > /dev/null 2>&1 ; then
|
[ -f /root/.ssh/agent ] && . /root/.ssh/agent > /dev/null
|
||||||
|
if ! kill -0 "$SSH_AGENT_PID" > /dev/null 2>&1 ; then
|
||||||
ssh-agent -s > /root/.ssh/agent
|
ssh-agent -s > /root/.ssh/agent
|
||||||
source /root/.ssh/agent > /dev/null
|
# shellcheck source=/dev/null
|
||||||
|
. /root/.ssh/agent > /dev/null
|
||||||
fi
|
fi
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue