screen-monitor/uninstall.sh

19 lines
405 B
Bash
Raw Normal View History

2024-08-02 00:52:13 +00:00
#!/bin/bash
# Stop the service
systemctl --user stop screenmonitor
# Disable the service
systemctl --user disable screenmonitor
# Remove the service file
rm ~/.config/systemd/user/screenmonitor.service
# Reload systemd to apply changes
systemctl --user daemon-reload
# Optionally remove the script and output directory
rm -rf ~/.screenmonitor
echo "Service uninstalled successfully for user $USER."