diff options
author | rhatto <rhatto@04377dda-e619-0410-9926-eae83683ac58> | 2006-12-10 22:44:26 +0000 |
---|---|---|
committer | rhatto <rhatto@04377dda-e619-0410-9926-eae83683ac58> | 2006-12-10 22:44:26 +0000 |
commit | a97dbb50966ae76345c7afba88acb3c061957667 (patch) | |
tree | 0e4c732d697fbaccbd15aa1d6f0daa767903f00b /src | |
parent | b467d6ba61cf820d62e9a0128c5fa1dbcf342b74 (diff) | |
download | simplepkg-a97dbb50966ae76345c7afba88acb3c061957667.tar.gz simplepkg-a97dbb50966ae76345c7afba88acb3c061957667.tar.bz2 |
simplaret: simplaret_search_and_download_patch one more fix
git-svn-id: svn+slack://slack.fluxo.info/var/svn/simplepkg@68 04377dda-e619-0410-9926-eae83683ac58
Diffstat (limited to 'src')
-rwxr-xr-x | src/simplaret | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/src/simplaret b/src/simplaret index bd50712..1c32166 100755 --- a/src/simplaret +++ b/src/simplaret @@ -436,8 +436,16 @@ function simplaret_get { function simplaret_search_and_download_patch { + local package_version package_build + + # get just the file name candidate="`basename $(echo $candidate | cut -d , -f 1)`" + # now split the file name into pieces + package_version="`package_version $candidate`" + package_build="`package_build $candidate`" + candidate="`package_name $candidate`" + # check if the patch was already downloaded if echo $DOWNLOADED_PATCHES | grep -q " $candidate "; then return @@ -448,7 +456,7 @@ function simplaret_search_and_download_patch { if [ ! -z "$installed_packs" ]; then for installed in $installed_packs; do - if [[ "`package_name $candidate`" == "`package_name $installed.tgz`" ]]; then + if [[ "$candidate" == "`package_name $installed.tgz`" ]]; then package_installed="1" break fi @@ -458,7 +466,7 @@ function simplaret_search_and_download_patch { if [[ "$package_installed" != "1" ]]; then # TODO: verificar se eh a mesma versao e build number? # DOWNLOAD_EVEN_IF_APPLIED? - simplaret_get `package_name $candidate` + simplaret_get $candidate DOWNLOADED_PATCHES="$DOWNLOADED_PATCHES $candidate " # the ending space is important fi |