X-Git-Url: https://git.grml.org/?a=blobdiff_plain;f=etc%2Fgrml%2Flsb-functions;h=42e89fb21fb04c4445211133021868721067a18a;hb=fcb1f5a4c443b8c2e2ba359170dd8bb88a899fdb;hp=5f0f145f01acfe8b6182464f8cf563603d1931af;hpb=2eb0a57ff591566506abc54810333d464f10e3a5;p=grml-etc-core.git diff --git a/etc/grml/lsb-functions b/etc/grml/lsb-functions index 5f0f145..42e89fb 100644 --- a/etc/grml/lsb-functions +++ b/etc/grml/lsb-functions @@ -167,23 +167,6 @@ RC_DEFAULT_INDENT=2 #RC_DOT_PATTERN=' .' RC_DOT_PATTERN='' -# void splash(...) -# -# Notify bootsplash/splashutils/gensplash/whatever about -# important events. -# -splash() { - return 0 -} - -# void profiling(...) -# -# Notify bootsplash/whatever about important events. -# -profiling() { - return 0 -} - # void get_bootconfig() # # Get the BOOTLEVEL and SOFTLEVEL by setting @@ -503,57 +486,6 @@ add_suffix() { return 0 } -# Network filesystems list for common use in rc-scripts. -# This variable is used in is_net_fs and other places such as -# localmount. -NET_FS_LIST="afs cifs coda gfs ncpfs nfs nfs4 shfs smbfs" - -# bool is_net_fs(path) -# -# return 0 if path is the mountpoint of a networked filesystem -# -# EXAMPLE: if is_net_fs / ; then ... -# -is_net_fs() { - local fstype - # /proc/mounts is always accurate but may not always be available - if [ -e /proc/mounts ]; then - fstype="$( sed -n -e '/^rootfs/!s:.* '"$1"' \([^ ]*\).*:\1:p' /proc/mounts )" - else - fstype="$( mount | sed -n -e 's:.* on '"$1"' type \([^ ]*\).*:\1:p' )" - fi - case " ${NET_FS_LIST} " in - *" ${fstype} "*) - return 0 - ;; - *) - return 1 - ;; - esac -} - -# bool is_uml_sys() -# -# return 0 if the currently running system is User Mode Linux -# -# EXAMPLE: if is_uml_sys ; then ... -# -is_uml_sys() { - grep -qs 'UML' /proc/cpuinfo - return $? -} - -# bool is_vserver_sys() -# -# return 0 if the currently running system is a Linux VServer -# -# EXAMPLE: if is_vserver_sys ; then ... -# -is_vserver_sys() { - grep -qs '^s_context:[[:space:]]*[1-9]' /proc/self/status - return $? -} - # bool get_mount_fstab(path) # # return the parameters to pass to the mount command generated from fstab