Do not run expensive env initializations for non-interactive shells

This commit is contained in:
Alexander Gehrke 2025-03-04 14:59:59 +01:00 committed by Alexander Roso
parent 87ced67ef2
commit 03e0518f6f
4 changed files with 13 additions and 1 deletions

View file

@ -1,3 +1,5 @@
[[ $- == *i* ]] || return 0
if command -v podman &>/dev/null; then
export DOCKER_SOCKET=$(podman system info -f '{{.Host.RemoteSocket.Path}}')
export DOCKER_HOST=unix://$DOCKER_SOCKET