Updated hyprsolusctl
If check command ran in terminal, pidof string is discarded and the notify-send message is echoed.
This commit is contained in:
parent
649b52a5db
commit
eb3868260a
|
|
@ -16,7 +16,7 @@ cache="$HOME/.cache/hyprsolus"
|
|||
check () {
|
||||
>&2 echo "Checking for Hyprland upgrades..."
|
||||
# ensure that Hyprland is even running
|
||||
if ! pidof hyprland
|
||||
if ! pidof hyprland >/dev/null
|
||||
then
|
||||
>&2 echo "Could not find Hyprland process. Is it even running?"
|
||||
exit 255
|
||||
|
|
@ -45,6 +45,8 @@ check () {
|
|||
echo "$origin" | jq -r ".[0]" >"$cache/release-metadata.json"
|
||||
notify-send -a "Hyprsolus" "Hyprland Update Available" \
|
||||
"A new version of Hyprland is available ($origin_vers)."
|
||||
[[ -t 0 ]] && echo "A new version of Hyprland is available \
|
||||
($origin_vers)."
|
||||
else
|
||||
>&2 echo "No upgrade available. Ensuring most recent metadata..."
|
||||
[[ -f "$cache/release-metadata.json" ]] && \
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user