Fix: Passt die is_interactive-Prüfung an.

This commit is contained in:
DragonSlayer_14 2025-03-06 10:46:43 +01:00
parent 94b359fded
commit 3b11d0e75a

View File

@ -1,8 +1,10 @@
#!/bin/bash #!/bin/bash
is_interactive() { is_interactive() {
case $- in # Prüft, ob ein Terminal verfügbar ist
*i*) return 1 ;; # Interaktive Shell if [ -t 0 ] || [ -t 1 ] || [ -t 2 ]; then
*) return 0 ;; # Nicht-interaktive Shell return 0
esac else
return 1
fi
} }