noob question: can't find a new port

Ryan Schmidt ryandesign at macports.org
Tue Dec 2 14:41:11 PST 2008


On Dec 2, 2008, at 15:11, Joshua Root wrote:

> Jeremy Huddleston wrote:
>
>> This is a bit of a noob question, and I'm sure it's buried in
>> documentation somewhere, but I didn't see it...  I'm trying to test a
>> new port which isn't committed yet that has a dependency on a
>> just-committed port... but it's not finding it.  Am I missing a step?
>
> It hasn't reached the PortIndex yet (regenerated every hour if  
> needed).
> You can regenerate it yourself with the portindex command if you want

And note that you need to be in the dports directory when you issue  
the portindex command for it to work.

cd $(port dir MacPorts)/../..
portindex

On my machine the portindex command takes about 8 minutes to run,  
which is a bit annoying.


> (but watch out for conflicts when updating).

For this reason, I define my own "port sync" command which first  
reverts the PortIndex, in case I've made any modifications, then does  
the svn update. Simplified a bit from what's in my .bash_profile:


port() {
	case "$1" in
		sync)
			PORTS_DIR=$(cd $(command port dir MacPorts)/../.. && pwd)
			svn revert ${PORTS_DIR}/PortIndex | sed s%${PORTS_DIR}/%%
			svn update ${PORTS_DIR} | sed s%${PORTS_DIR}/%%
			;;
		*)
			command port "$@"
			;;
	esac
}




More information about the macports-dev mailing list