aboutsummaryrefslogtreecommitdiff
path: root/src/usr
diff options
context:
space:
mode:
Diffstat (limited to 'src/usr')
-rw-r--r--src/usr/libexec/myautomount/myautomount-initialize.sh6
-rw-r--r--src/usr/share/applications/myautomount-trayicon.desktop10
-rw-r--r--src/usr/share/applications/myautomountd.desktop10
3 files changed, 23 insertions, 3 deletions
diff --git a/src/usr/libexec/myautomount/myautomount-initialize.sh b/src/usr/libexec/myautomount/myautomount-initialize.sh
index e1cc6a8..67fe2f3 100644
--- a/src/usr/libexec/myautomount/myautomount-initialize.sh
+++ b/src/usr/libexec/myautomount/myautomount-initialize.sh
@@ -1,7 +1,7 @@
#!/bin/sh
# SPDX-License-Identifier: BSD-2-Clause
-# Only needs to be run once. This is more for reference than for using. The package should handle these tasks.
-# MYA_SKIP_RESTART is for when you are building a package
+# The daemon will call this once upon starting.
+# MYA_SKIP_RESTART is for when you are building a package. Set it to any value, to skip the `service autofs restart`.
fail() {
echo "${@}" 1>&2
@@ -19,7 +19,7 @@ setupSystem() {
{ touch "${MYA_PREFIX}${AUTOMOUNT_DIR_FILE}" && echo "${AUTOMOUNT_BROWSEDIR} ${AUTOMOUNT_FILE} --timeout=5 " > "${MYA_PREFIX}${AUTOMOUNT_DIR_FILE}" ; } || fail "Could not setup autofs rules! Check if this is being run as root?"
_needrestart=1
}
- test ${_needrestart} -eq 1 && test -n "${MYA_SKIP_RESTART}" eval "service autofs restart"
+ test ${_needrestart} -eq 1 && test -z "${MYA_SKIP_RESTART}" && eval "service autofs restart"
}
. ${MYA_PREFIX}/etc/myautomount.conf
diff --git a/src/usr/share/applications/myautomount-trayicon.desktop b/src/usr/share/applications/myautomount-trayicon.desktop
new file mode 100644
index 0000000..061454d
--- /dev/null
+++ b/src/usr/share/applications/myautomount-trayicon.desktop
@@ -0,0 +1,10 @@
+[Desktop Entry]
+Comment=Tray icon for managing removable media
+Exec=/usr/bin/myautomount-trayicon
+GenericName=Automount helper tray icon
+Icon=media-removable
+Keywords=automount;
+Name=MyAutoMount tray icon
+NoDisplay=true
+Terminal=false
+Type=Application
diff --git a/src/usr/share/applications/myautomountd.desktop b/src/usr/share/applications/myautomountd.desktop
new file mode 100644
index 0000000..57a147a
--- /dev/null
+++ b/src/usr/share/applications/myautomountd.desktop
@@ -0,0 +1,10 @@
+[Desktop Entry]
+Comment=Monitor udevadm for removable media
+Exec=/usr/bin/myautomountd
+GenericName=Automount helper daemon
+Icon=media-removable
+Keywords=automount;
+Name=MyAutoMount daemon
+NoDisplay=true
+Terminal=false
+Type=Application
bgstack15