diff options
author | Aaron LI <aly@aaronly.me> | 2018-03-10 19:39:12 +0800 |
---|---|---|
committer | Aaron LI <aly@aaronly.me> | 2018-03-10 19:39:12 +0800 |
commit | 1d36cf530b77105d1b844b5b2ca28525576a86ef (patch) | |
tree | e5b26800c31ad8bee7e6b9ae45805fc572cc9ea1 | |
parent | 97e0ab7de5f92b375715cc5c3e082fccdb809b13 (diff) | |
download | dfly-update-1d36cf530b77105d1b844b5b2ca28525576a86ef.tar.bz2 |
Fix get_latest_image() to return _md5 correctly
-rwxr-xr-x | dfly-update | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/dfly-update b/dfly-update index c76d45e..beb9f8a 100755 --- a/dfly-update +++ b/dfly-update @@ -81,7 +81,7 @@ get_local_version() { # Get the latest remote system image # Returns: -# "_filename=<latest.iso/img>; _md5=<md5/of/latest.iso/img>" +# "_filename='<latest.iso/img>'; _md5='<md5/of/latest.iso/img>'" get_latest_image() { local latest_filename latest_md5 line if [ "${branch}" = "DEVELOPMENT" ]; then @@ -102,8 +102,9 @@ get_latest_image() { fgrep -v 'gui-' | tail -n 1) fi latest_filename=$(echo "${line}" | awk -F'[()]' '{ print $2 }') - latest_md5=$(echo "${line}" | awk '{ print $5 }') + latest_md5=$(echo "${line}" | awk '{ print $4 }') rm -f ${tmpchecksum} + debug "_filename='${latest_filename}'; _md5='${latest_md5}'" echo "_filename='${latest_filename}'; _md5='${latest_md5}'" } |