summaryrefslogtreecommitdiffstats
path: root/usr.sbin/portsnap
Commit message (Collapse)AuthorAgeFilesLines
* Make "missing dependency" errors more useful by indicating which portcperciva2005-12-011-10/+10
| | | | | | | is trying to depend upon the non-existent port. Suggested by: kris MFC after: 3 days
* An empty file does not have a positive number of lines.cperciva2005-11-201-0/+7
| | | | | | | | Make sure that the number of lines read is non-zero before in order to avoid dumping core. Reported by: Wojciech A. Koszek Pointy hat to: cperciva
* Correctly handle a TCP connection being shutdown by the server whilecperciva2005-11-171-1/+2
| | | | | | | | | we're reading response headers. (Handle it as a connection-killing error, rather than entering an infinite loop reading zero bytes.) Reported by: simon Discovered thanks to: A not-very-transparent transparent HTTP proxy. MFC after: 3 days
* Add HTTP proxy authentication, via the HTTP_PROXY_AUTH environmentcperciva2005-09-221-1/+101
| | | | | | | variable. Tested by: Emil Mikulic X-MFC-After: 6.0-RELEASE
* Style fix: "if (pointer)" -> "if (pointer != NULL)"cperciva2005-09-211-1/+1
|
* Add a note pointing out that certain information (IP address, list ofcperciva2005-09-181-0/+15
| | | | | | files fetched, FreeBSD release level) is transmitted to the portsnap server when portsnap is run, but that this information is only used anonymously and in aggregate.
* Handle circular dependencies properly (via errx(3)) rather than dumpingcperciva2005-09-171-2/+15
| | | | | | | core. This bug was made visible by a recent change to the audio/timidity++ port, which now has itself as a run dependency. Reported by: Emil Mikulic, Andreas Klemm
* Portsnap uses host(1) to search for mirrors, but this is only availablecperciva2005-09-151-0/+6
| | | | | | | | when the base system is not compiled with NO_BIND set. Before we start searching for mirrors, make sure that host(1) can be found, and if it doesn't exist then fallback to the A record instead of the SRV records. Submitted by: Luca Morettoni
* Fix typo: ${PORTDIR} -> ${PORTSDIR}.cperciva2005-09-111-1/+1
| | | | | | | | | Apologies to everyone who has run portsnap in 7.0-CURRENT since Tuesday; if there is a file "/.portsnap.INDEX" on your system, you can delete it (or even better, move it to /usr/ports/.portsnap.INDEX). Big pointy hat to: cperciva Reported that things weren't working properly: Aleksander Fafula
* Fix typo: Cowarly -> Cowardly.cperciva2005-09-071-1/+1
| | | | Reported by: Joerg Sonnenberger
* Teach portsnap how to ignore unwanted parts of the ports tree. A linecperciva2005-09-061-6/+66
| | | | | | | | | | | | | | | of the form "REFUSE foo" in portsnap.conf will result in parts of the tree matching "^foo" being (a) not extracted by "portsnap extract", (b) not updated by "portsnap update", and (c) not having any patches or new ports downloaded by "portsnap fetch" or "portsnap cron". The example shown in portsnap.conf demonstrates ignoring all the language categories. As mentioned in portsnap.conf.5, the use of an imcomplete ports tree is not officially supported; but this is something which many users have requested, so I'm adding it anyway. PR: bin/85619 (but not the patch provided therein) MFC after: 1 month
* Spell "cmp > /dev/null" as "cmp -s".cperciva2005-08-141-1/+1
| | | | Suggested by: dougb
* Correctly exit from extract_run() and update_run() if files needed arecperciva2005-08-131-4/+9
| | | | | | | | | | | | | | | | | | | | | missing from ${WORKDIR}/files/. This bug was caused by the astonishing interaction of "return" and pipelines; in the following code, the "return" does not exit the function, but instead exits the subshell which was spawned for the last element of the pipeline; consequently, the output produced is "foo". foo() { echo bar | while read baz; do if [ ${baz} = "bar" ]; then return 1 fi done echo foo } Reported by: simon
* Misc mdoc(7) fixes:simon2005-08-131-7/+10
| | | | | | | | | - Bump document date for recent updates. - Use .Fx for FreeBSD. - Remove EOL whitespace. - Start new sentences on new lines. Reviewed by: cperciva
* Allow multiple commands to be specified on a single command line, e.g.,cperciva2005-08-132-7/+11
| | | | | | | | | "portsnap fetch update" or "portsnap -I cron update". They will be executed in the order that they appear, and duplicates are not removed (so "portsnap fetch fetch fetch fetch" is meaningful, albeit rather silly). Requested by: Roman Divacky
* Fix the progress statistics code by printing the right variable. Icperciva2005-08-131-1/+1
| | | | | | | missed this when I changed the stats code in the ports -> base transition. Pointed out by: simon
* When using cmp(1) to determine if the ports tree is already up to date,cperciva2005-08-121-1/+2
| | | | | | | we want the exit code, but not the actual output; add a redirect to /dev/null. Pointy hat to: cperciva
* If the ports tree is already up to date when we run `portsnap update`,cperciva2005-08-111-0/+5
| | | | | | | exit early; this avoids spending five seconds rebuilding the INDEX files. Requested by: somebody on IRC, but I can't remember who
* Remove unused variable.cperciva2005-08-101-2/+1
| | | | Reported by: stefanf
* Check that malloc() succeeds in makelist.cperciva2005-08-091-0/+2
| | | | | Submitted by: Roman Divacky (who did a very complete review of both make_index.c and phttpget.c)
* Replace INT_MAX with OFF_MAX. I used INT_MAX originally (in ports)cperciva2005-08-091-3/+3
| | | | because OFF_MAX wasn't defined on FreeBSD 4.x.
* When parsing the HTTP_PROXY environment variable, strip a trailing /cperciva2005-08-091-1/+5
| | | | | | | | | from the port number (if any exists). This unbreaks env HTTP_PROXY="http://localhost:3128/" portsnap fetch While I'm here, list both the host and the port in the error message output if getaddrinfo() fails, since either of them could be responsible for the failure.
* Add a missing EOL when printing "Latest snapshot on server is oldercperciva2005-08-091-5/+7
| | | | | | | | | | than what we already have" message. [1] When operating with the undocumented --debug option, replace "xargs phttpget" with "xargs -t phttpget", since that might conceivably help debugging. Noticed by: simon [1]
* Add portsnap to the base system. This is a secure, easy to use,cperciva2005-08-089-0/+2232
fast, lightweight, and generally good way for users to keep their ports trees up to date. This is version 0.9.4 from the ports tree (sysutils/portsnap) with the following changes: 1. The experimental pipelined http code is enabled. No seatbelts in -CURRENT. (^_^) 2. The working directory has moved from /usr/local/portsnap to /var/db/portsnap (as discussed on -arch two days ago). 3. Portsnap now fetches a list of mirrors (distributed as DNS SRV records) and selects one randomly. This should help to avoid the uneven loading which plagues the cvsup mirror network. 4. The license is now 2-clause BSD instead of 3-clause BSD. 5. Various incidental changes to make portsnap fit into the base system's build mechanics. X-MFC-After: 6.0-RELEASE X-MFC-Before: 5.5-RELEASE X-MFC-To: RELENG_6, RELENG_5, ports discussed on: -arch and several other places "yes please" from: simon, remko, flz, Diane Bruce thinks this is a great idea: bsdimp Hopes he didn't forget any files: cperciva
OpenPOWER on IntegriCloud