Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 16 Apr 2016 17:20:45 +0200
From:      Polytropon <freebsd@edvax.de>
To:        JosC <bsduser@cloudzeeland.nl>
Cc:        FreeBSD Questions <freebsd-questions@freebsd.org>
Subject:   Re: Ports upgrade script
Message-ID:  <20160416172045.8010cc7b.freebsd@edvax.de>
In-Reply-To: <2e223983-d2ff-fd97-caba-732fd92aa20b@cloudzeeland.nl>
References:  <2daca22c-7719-0776-fbe8-3c37021298bf@cloudzeeland.nl> <CAA2O=b9kHNz-q8NP_txAveRRw57jLWg8yMnTZvcQm0F4M98hOA@mail.gmail.com> <2e223983-d2ff-fd97-caba-732fd92aa20b@cloudzeeland.nl>

Next in thread | Previous in thread | Raw E-Mail | Index | Archive | Help
On Sat, 16 Apr 2016 16:34:16 +0200, JosC wrote:
> 
> In een bericht van 16-4-2016 12:18:
> >
> > Portsnap isn't compatible with svn.
> >
> So I think I should revise the way I update my ports.
> What I did with my 9.3 BSD was the following script (which worked 
> perfectly):
> 
> !/bin/sh
> cd /local/user/etc
> svn update /usr/src
> svn update /usr/ports
> #
> cd /usr/ports
> make fetchindex
> portsdb -fu
> #
> #
> cd /usr/local/etc
> portupgrade -na
> #
> 
> So this part I replaced now with:
> 
> portsnap fetch update
> 
> kind of lost how to continue now...

Your script does _more_ than just update installed ports. It also
updates the OS sources, but it does _not_ upgrade the OS according
to those sources.

If that's what you intend, try the following:



#!/bin/sh
# update OS sources
svn update /usr/src
# update ports tree
svn update /usr/ports
make fetchindex
portsdb -fu
# upgrade all installed ports
portupgrade -na



You can exchange 

	# update ports tree
	svn update /usr/ports

with the following:

	# update ports tree
	portsnap fetch extract

But you should keep _one_ of those two methods. It's usually wise to
start with an empty /usr/ports directory and have the desired tool
populate it for the first time, then apply changes on further runs.




-- 
Polytropon
Magdeburg, Germany
Happy FreeBSD user since 4.0
Andra moi ennepe, Mousa, ...



Want to link to this message? Use this URL: <http://docs.FreeBSD.org/cgi/mid.cgi?20160416172045.8010cc7b.freebsd>