Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
home:munix9
AppImageUpdate
appimage-update.sh
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File appimage-update.sh of Package AppImageUpdate
#!/bin/bash # # appimage-update.sh wrapper # # Author: munix9@googlemail.com # License: MIT # export TEXTDOMAIN="appimage-update.sh" export TEXTDOMAINDIR="/usr/share/locale" _t () { local t="${1:-???}" echo "$(gettext -s "$t")" } _file="$1" _old="${_file}.zs-old" _title="AppImageUpdate - $(_t "Check for update")" _sp="$(printf " %0.s " {1..50})" [[ -n $_file ]] || { kdialog --title "$_title" --error "$_sp<br><b>$(_t "Missing file operand.")</b><br>" exit 1 } [[ -r $_file ]] || { kdialog --title "$_title" --error "$_file<br>$_sp<br><b>$(_t "File not found.")</b><br>" exit 1 } # check for update /usr/bin/AppImageUpdate -j "$_file" >/dev/null 2>&1 if [[ $? -eq 0 ]] ; then kdialog --title "$_title" --msgbox "$_file<br>$_sp<br><b>$(_t "AppImage already up to date.")</b><br>" elif [[ $? -eq 1 ]] ; then kdialog --title "$_title" --yesno "$_file<br>$_sp<br><b>$(_t "Update available. Perform update?")</b><br>" [[ $? -eq 0 ]] && { /usr/bin/AppImageUpdate "$_file" [[ $? -eq 0 ]] && [[ -f $_old ]] && { kdialog --title "$_title" --yesno "$_old<br>$_sp<br><b>$(_t "Remove old AppImage file?")</b><br>" [[ $? -eq 0 ]] && rm -f "$_old" } } #[[ $? -eq 0 ]] && kdialog --title "$_title" --msgbox "run AppImageUpdate" else kdialog --title "$_title" --error "$_file<br>$_sp<br><b>$(_t "Error checking file for updates.")</b><br>" fi
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor