aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/ssh/.config/profile.d/10-ssh.sh
diff options
context:
space:
mode:
authorToby Vincent <tobyv@tobyvin.dev>2024-02-28 19:45:38 -0600
committerToby Vincent <tobyv@tobyvin.dev>2024-02-29 16:22:28 -0600
commit3c4e656c69a8ed34bc2d6f6bd167727b92e47326 (patch)
tree68d2fa04885297b8d56aca05312ecc9d2a563f60 /ssh/.config/profile.d/10-ssh.sh
parent6449aded68456ee97a314afc716743760a2f3e30 (diff)
fix(ssh): skip ssh agent setup on remotes
Diffstat (limited to 'ssh/.config/profile.d/10-ssh.sh')
-rw-r--r--ssh/.config/profile.d/10-ssh.sh4
1 files changed, 3 insertions, 1 deletions
diff --git a/ssh/.config/profile.d/10-ssh.sh b/ssh/.config/profile.d/10-ssh.sh
index 82e3b31..af52410 100644
--- a/ssh/.config/profile.d/10-ssh.sh
+++ b/ssh/.config/profile.d/10-ssh.sh
@@ -1,3 +1,5 @@
#!/bin/sh
-export SSH_AUTH_SOCK="$XDG_RUNTIME_DIR/ssh-agent.socket"
+if [ -z "$SSH_CONNECTION" ]; then
+ export SSH_AUTH_SOCK="$XDG_RUNTIME_DIR/ssh-agent.socket"
+fi