diff options
| author | Egor Tensin <egor@tensin.name> | 2026-10-22 23:33:13 +0300 |
|---|---|---|
| committer | Egor Tensin <egor@tensin.name> | 2026-10-22 23:33:13 +0300 |
| commit | 5e42747d92537d28028baefbbffe0bc507f59f70 (patch) | |
| tree | ab6a62eea60135224a6d775fe8d4f8e14b19aa40 | |
| parent | ssh: disable annoying warnings (diff) | |
| download | linux-home-5e42747d92537d28028baefbbffe0bc507f59f70.tar.gz linux-home-5e42747d92537d28028baefbbffe0bc507f59f70.zip | |
.profile: enable ssh-agent via systemd
| -rw-r--r-- | %HOME%/.profile | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/%HOME%/.profile b/%HOME%/.profile index f74af3b..aefb9ff 100644 --- a/%HOME%/.profile +++ b/%HOME%/.profile @@ -9,6 +9,11 @@ elif command -v nano > /dev/null 2>&1; then export EDITOR=nano fi +# https://wiki.archlinux.org/title/SSH_keys#Start_ssh-agent_with_systemd_user +if systemctl --user is-enabled --quiet ssh-agent > /dev/null 2>&1; then + export SSH_AUTH_SOCK="$XDG_RUNTIME_DIR/ssh-agent.socket" +fi + path_export() { local path for path; do |
