#!/bin/sh # # Script: suspend # License: MIT # Author: Arkaprabha Chakraborty # Created: 12-05-24 # Dependencies: None # # Copyright (C) 2024 Arkaprabha Chakraborty # Call systemctl suspend systemctl suspend # Check the return status of systemctl suspend if [ $? -ne 0 ]; then echo "Error: Failed to suspend the system." >&2 exit 1 fi echo "System suspended successfully." exit 0