From 0081f618d5d5cbd483deba16de48218c6778526a Mon Sep 17 00:00:00 2001 From: Steve Loughran Date: Wed, 2 Jan 2002 05:16:04 +0000 Subject: [PATCH] username and password doced and exampled; some tab to space corrections. git-svn-id: https://svn.apache.org/repos/asf/ant/core/trunk@270501 13f79535-47bb-0310-9956-ffa450edef68 --- docs/manual/CoreTasks/get.html | 53 ++++++++++++++++++++++++++-------- 1 file changed, 41 insertions(+), 12 deletions(-) diff --git a/docs/manual/CoreTasks/get.html b/docs/manual/CoreTasks/get.html index f5bef9bc5..27a16cb19 100644 --- a/docs/manual/CoreTasks/get.html +++ b/docs/manual/CoreTasks/get.html @@ -2,7 +2,7 @@ -Apache Ant User Manual +Get @@ -10,16 +10,27 @@

Get

Description

Gets a file from a URL. When the verbose option is "on", this task -displays a '.' for every 100 Kb retrieved.

+displays a '.' for every 100 Kb retrieved. Any URL schema supported by +the runtime is valid here, including http:, ftp:, and the classpath; +https: is only valid if the appropriate support is added to the pre-1.4 Java +runtimes. + +

This task should be preferred above the CVS task when -doing automated builds. CVS is significantly slower than loading a compressed -archive with http/ftp.

+fetching remote content. CVS is significantly slower than loading a compressed +archive compared to http/ftp.

The usetimestamp option enables you to control downloads so that the remote file is only fetched if newer than the local copy. If there is no local copy, the download always takes place. When a file is downloaded, the timestamp of the downloaded file is set to the remote timestamp, if the JVM is Java1.2 or later. NB: This timestamp facility only works on downloads using the HTTP protocol. +

+A username and password can be specified, in which case basic 'slightly encoded +plain text' authentication is used. This is only a secure authentication +mechanism over an HTTPS link. +

+

Parameters

@@ -40,34 +51,52 @@ NB: This timestamp facility only works on downloads using the HTTP protocol. - + - + - - + + + + + + + + + + + + +
verbose show verbose progress information ("on"/"off").NoNo; default "false"
ignoreerrors Log errors but don't treat as fatal.NoNo; default "false"
usetimestampconditionally download a file based on the timestamp of the local copy. - HTTP onlyNoconditionally download a file based on the timestamp of the + local copy. HTTP onlyNo; default "false"
usernameusername for 'BASIC' http authenticationif password is set
passwordpassword: required if username is set

Examples

  <get src="http://jakarta.apache.org/" dest="help/index.html"/>

Gets the index page of http://jakarta.apache.org/, and stores it in the file help/index.html.

  <get src="http://jakarta.apache.org/builds/tomcat/nightly/ant.zip" 
-	dest="optional.jar" 
-	verbose="true"
-	usetimestamp="true"/>
+ dest="optional.jar" + verbose="true" + usetimestamp="true"/>

Gets the nightly ant build from the tomcat distribution, if the local copy is missing or out of date. Uses the verbose option for progress information.

+
  <get src="https://insecure-bank.org/statement/user=1214" 
+    dest="statement.html" 
+    username="1214";
+    password="secret" />
+

+Fetches some file from a server with access control. Because https is being used the +fact that basic auth sends passwords in plaintext is moot.


Copyright © 2000,2001 Apache Software Foundation. All rights Reserved.