From 4c85a02fe043b884e32370bb4176423c57bb4a1e Mon Sep 17 00:00:00 2001 From: DragonSlayer_14 Date: Sat, 8 Mar 2025 11:19:14 +0100 Subject: [PATCH] Ref: Konsolidiert die Funktionen in eine gruppierte sh-Datei --- Utility/IsMounted.sh | 18 ++++++++++++++++++ Utility/IsWebdavMounted.sh | 10 ---------- 2 files changed, 18 insertions(+), 10 deletions(-) delete mode 100644 Utility/IsWebdavMounted.sh diff --git a/Utility/IsMounted.sh b/Utility/IsMounted.sh index c68ac47..b10ba16 100644 --- a/Utility/IsMounted.sh +++ b/Utility/IsMounted.sh @@ -8,3 +8,21 @@ is_mounted() { return 1 # Nicht gemountet fi } + +is_webdav_mounted() { + local mount_point="$1" + if mount | grep -q "on $mount_point type davfs"; then + return 0 # WebDAV ist gemountet + else + return 1 # WebDAV ist nicht gemountet + fi +} + +is_nfs_mounted() { + local mount_point="$1" + if mount | grep -q "on $mount_point type nfs"; then + return 0 # NFS ist gemountet + else + return 1 # NFS ist nicht gemountet + fi +} diff --git a/Utility/IsWebdavMounted.sh b/Utility/IsWebdavMounted.sh deleted file mode 100644 index b9f5cc3..0000000 --- a/Utility/IsWebdavMounted.sh +++ /dev/null @@ -1,10 +0,0 @@ -#!/bin/bash - -is_webdav_mounted() { - local mount_point="$1" - if mount | grep -q "on $mount_point type davfs"; then - return 0 # WebDAV ist gemountet - else - return 1 # WebDAV ist nicht gemountet - fi -}