diff --git a/.cvsignore b/.cvsignore index e74b592..11c4294 100644 --- a/.cvsignore +++ b/.cvsignore @@ -18,3 +18,4 @@ alsa-utils-1.0.15rc1.tar.bz2 alsa-utils-1.0.16.tar.bz2 alsa-utils-1.0.17.tar.bz2 alsa-utils-1.0.18rc3.tar.bz2 +alsa-utils-1.0.18.tar.bz2 diff --git a/alsa-info.sh b/alsa-info.sh index 8d1e944..795d389 100644 --- a/alsa-info.sh +++ b/alsa-info.sh @@ -1,6 +1,6 @@ #!/bin/bash -SCRIPT_VERSION=0.4.51 +SCRIPT_VERSION=0.4.52 CHANGELOG="http://www.alsa-project.org/alsa-info.sh.changelog" ################################################################################# @@ -46,26 +46,45 @@ update() { if [ "$REMOTE_VERSION" != "$SCRIPT_VERSION" ]; then if [[ -n $DIALOG ]] then - dialog --yesno "Newer version of ALSA-Info has been found\n\nDo you wish to install it?" 0 0 + if [ -w $0 ]; then + dialog --yesno "Newer version of ALSA-Info has been found\n\nDo you wish to install it?" 0 0 + else + dialog --yesno "Newer version of ALSA-Info has been found\n\nDo you wish to download it?" 0 0 + fi DIALOG_EXIT_CODE=$? if [[ $DIALOG_EXIT_CODE = 0 ]] then - cp /tmp/alsa-info.sh $0 - echo "ALSA-Info script has been updated to v $REMOTE_VERSION" + echo "Newer version detected: $REMOTE_VERSION" echo "To view the ChangeLog, please visit $CHANGELOG" - echo "Please re-run the script" + if [ -w $0 ]; then + cp /tmp/alsa-info.sh $0 + echo "ALSA-Info script has been updated to v $REMOTE_VERSION" + echo "Please re-run the script" + rm /tmp/alsa-info.sh 2>/dev/null + else + echo "ALSA-Info script has been downloaded as /tmp/alsa-info.sh." + echo "Please re-run the script from new location." + fi exit + else + rm /tmp/alsa-info.sh 2>/dev/null fi else - cp /tmp/alsa-info.sh $0 echo "Newer version detected: $REMOTE_VERSION" echo "To view the ChangeLog, please visit $CHANGELOG" - echo "ALSA-Info script has been updated. Please re-run it." - + if [ -w $0 ]; then + cp /tmp/alsa-info.sh $0 + echo "ALSA-Info script has been updated. Please re-run it." + rm /tmp/alsa-info.sh 2>/dev/null + else + echo "ALSA-Info script has been downloaded as /tmp/alsa-info.sh." + echo "Please, re-run it from new location." + fi exit fi + else + rm /tmp/alsa-info.sh 2>/dev/null fi - rm /tmp/alsa-info.sh 2>/dev/null } cleanup() { @@ -373,7 +392,7 @@ echo "" >> $FILE echo "" >> $FILE fi -if [ -d $SYSFS ] +if [ -d "$SYSFS" ] then echo "!!Loaded sound module options" >> $FILE echo "!!--------------------------" >> $FILE diff --git a/alsa-utils.spec b/alsa-utils.spec index f4d57f5..6c57479 100644 --- a/alsa-utils.spec +++ b/alsa-utils.spec @@ -1,10 +1,10 @@ -%define prever rc3 -%define prever_dot .rc3 +#define prever rc3 +#define prever_dot .rc3 Summary: Advanced Linux Sound Architecture (ALSA) utilities Name: alsa-utils Version: 1.0.18 -Release: 3%{?prever_dot}%{?dist} +Release: 4%{?prever_dot}%{?dist} License: GPLv2+ Group: Applications/Multimedia URL: http://www.alsa-project.org/ @@ -96,6 +96,10 @@ if [ -s /etc/alsa/asound.state -a ! -s /etc/asound.state ] ; then fi %changelog +* Tue Nov 04 2008 Jaroslav Kysela 1.0.18-4 +- updated to 1.0.18 final +- updated alsa-info.sh script + * Thu Sep 18 2008 Jaroslav Kysela 1.0.18-3.rc3 - fixed alsa-info.sh link diff --git a/sources b/sources index 4bf0eba..e779a9f 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -31ff44de50e6725974b3d2e032ab214d alsa-utils-1.0.18rc3.tar.bz2 +0a6b26d27cc2adfd591d91d8c155fdb7 alsa-utils-1.0.18.tar.bz2