Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 9 Nov 2009 07:19:25 +0000 (UTC)
From:      Doug Barton <dougb@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-user@freebsd.org
Subject:   svn commit: r199068 - user/dougb/portmaster
Message-ID:  <200911090719.nA97JPdF011731@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: dougb
Date: Mon Nov  9 07:19:25 2009
New Revision: 199068
URL: http://svn.freebsd.org/changeset/base/199068

Log:
  Pick the latest version of the package from a different spot in the
  HTML. This should avoid the problem of the web server truncating
  the file name, but adds the tiny cost of needing to sub out the
  URL encoding for the ',' character if it's present.

Modified:
  user/dougb/portmaster/portmaster

Modified: user/dougb/portmaster/portmaster
==============================================================================
--- user/dougb/portmaster/portmaster	Mon Nov  9 02:54:16 2009	(r199067)
+++ user/dougb/portmaster/portmaster	Mon Nov  9 07:19:25 2009	(r199068)
@@ -2288,7 +2288,9 @@ if [ -n "$PM_PACKAGES" ]; then
 
 	sitepath="${sitepath%/}/${portdir%/*}/"
 
+#echo ''
 #echo "Debug> sitepath: $sitepath"
+#echo ''
 
 	[ -n "$PM_VERBOSE" ] && echo "===>>> Checking package repository"
 	latest_link=`pm_make -V LATEST_LINK`
@@ -2303,10 +2305,15 @@ if [ -n "$PM_PACKAGES" ]; then
 		echo "       on setting the PACKAGESITE environment variable"
 		fail 'No package archive found'
 	fi
-	latest_pv=${latest_pv#*tbz\">}
+	latest_pv=${latest_pv#*href=\"}
 	latest_pv=${latest_pv%%\.tbz*}
+	case "$latest_pv" in
+	*%2[cC]*)	latest_pv=`echo $latest_pv | sed s#%2[cC]#,#` ;;
+	esac
 
+#echo ''
 #echo "Debug> new_port: $new_port latest_pv: $latest_pv"
+#echo ''
 
 notnewer () {
 	echo ''



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200911090719.nA97JPdF011731>