Last change
on this file since 373 was 373, checked in by Rick van der Zwet, 13 years ago |
Auto-updating scripts is always handy.
|
-
Property svn:executable
set to
*
|
File size:
790 bytes
|
Rev | Line | |
---|
[368] | 1 | #!/bin/sh
|
---|
| 2 | #
|
---|
| 3 | # Unattended FreeBSD Ports upgrade cycle, please note that starting and stopping
|
---|
| 4 | # of services is taken care of in the pkgtools.conf
|
---|
| 5 | #
|
---|
| 6 | # Rick van der Zwet <info@rickvanderzwet.nl>
|
---|
| 7 | #
|
---|
| 8 | PATH=$PATH:/usr/local/sbin:/usr/local/bin
|
---|
| 9 | WC=`cd $(dirname $0); pwd -P`
|
---|
| 10 |
|
---|
| 11 | if [ `id -u` -ne 0 ]; then
|
---|
| 12 | echo "Root only!" 1>&2
|
---|
| 13 | exit 1
|
---|
| 14 | fi
|
---|
| 15 |
|
---|
[373] | 16 | # Make sure we always using the latest version
|
---|
| 17 | svn up --non-interactive `dirname $0` | grep '^[A-Z] ' && {
|
---|
| 18 | sh $0
|
---|
| 19 | exit 0
|
---|
| 20 | }
|
---|
| 21 |
|
---|
[368] | 22 | portmaster --version 1>/dev/null 2>/dev/null || make -C /usr/ports/ports-mgmt/portmaster BATCH=yes install clean
|
---|
| 23 |
|
---|
| 24 | # Fetch the latest details and provide listing of packages to be updated
|
---|
| 25 | portsnap fetch update || exit 1
|
---|
| 26 |
|
---|
| 27 | # Make sure the internal database is consistent
|
---|
| 28 | pkgdb -Fa || exit 1
|
---|
| 29 |
|
---|
| 30 | # Install via portmaster
|
---|
| 31 | portmaster -adG
|
---|
Note:
See
TracBrowser
for help on using the repository browser.