GSP
Quick Navigator

Search Site

Unix VPS
A - Starter
B - Basic
C - Preferred
D - Commercial
MPS - Dedicated
Previous VPSs
* Sign Up! *

Support
Contact Us
Online Help
Handbooks
Domain Status
Man Pages

FAQ
Virtual Servers
Pricing
Billing
Technical

Network
Facilities
Connectivity
Topology Map

Miscellaneous
Server Agreement
Year 2038
Credits
 

USA Flag

 

 

Man Pages
CPAN-UPLOAD-HTTP(1) User Contributed Perl Documentation CPAN-UPLOAD-HTTP(1)

cpan-upload-http - upload one or more files to CPAN, using PAUSE

cpan-upload-http [OPTIONS] file1 .. fileN

cpan-upload-http is a script which automates the process of uploading a file to CPAN using PAUSE, the Perl Authors Upload Server. For example, to upload a recent version of the Net::Dict module I ran:

    % cpan-upload-http -verbose Net-Dict-1.07.tar.gz

If everything went OK, you'll get two mail messages from the PAUSE monitor: one to acknowledge the upload, and one to let you know if your upload made it through to CPAN.

Given one or more files to upload, cpan-upload-http carries out the following two steps:

HTTP file upload and register the module by POSTing to the PAUSE web server.

This is just one of the ways you can upload something to PAUSE. See the PAUSE FAQ for details (referenced in SEE ALSO section below).

Before using cpan-upload-http you must register with PAUSE, to get a username and password. If you are a regular uploader to PAUSE, you'll probably want to create a ".pause" configuration file, as described in "CONFIGURATION FILE" below. If not, you can just use the command-line options, as described in "OPTIONS" below. If you don't provide your password (via configuration file or command-line), then you will be prompted for it. Echo'ing will be turned off while you type your password. This behaviour can be suppressed with the -non_interactive option, described below.

-user <string>
Your PAUSE username (which you previously registered with PAUSE).
-password <string>
The password for your PAUSE username.
-directory <string> | -dir <string>
A subdirectory in your CPAN area where the file should be uploaded to.
-mailto <email>
Your email address to include the HTTP request header.
-http_proxy <URL>
Specifies the URL for a proxy to use when making HTTP requests.
-non_interactive | -ni
cpan-upload-http should not prompt for any missing information (eg password), it should just warn or die, as appropriate.
-help
Displays a short help message with the OPTIONS section from the cpan-upload-http documentation.
-doc
Display the full documentation for cpan-upload-http.
-verbose
Turns on verbose information as the script runs.
-debug
Turns on debugging information. Useful mainly for the developer, it displays the HTTP request and response.
-version
Display the version number of the cpan-upload-http script.

You can provide the configuration information needed via a .pause file in your home directory. If you upload files at all regularly you will want to set up one of these.
user username
This is used to specify your PAUSE username. This just saves you from typing it every time you run the script.
password password
This is used to specify your PAUSE password.
directory path
Specify a subdirectory in your CPAN area.
http_proxy URL
The URL for the proxy to use when making HTTP requests to the PAUSE web server. For example:

    http_proxy = http://proxy/
    
mailto EMAIL
Specifies the email address which is passed in the header of the HTTP request. You must provide this.
non_interactive
Specifies that cpan-upload-http should never prompt the user (eg for password), but should take a default action.

The following is a sample .pause file:

    # example .pause for user neilb
    # the user is your registered PAUSE username
    user NEILB
    password thisisnotmyrealpassword

    mailto      = neil@bowers.com
    http_proxy  = http://proxy.cre.canon.co.uk/

    non_interactive

Note that your .pause must not be readable by others, since it can contain your PAUSE password. The cpan-upload-http script refuses to run if your config file can be read by others.

Also, let me know if you ever have occasion to wish that the features below had been implemented. I probably won't do them unless someone would like to see them in.

I'd be happy to hear any more suggestions.

  • As with the password, prompt for PAUSE username and email address if not provided (by .pause file or on the command-line).
  • Add configuration options for specifying the URI we POST to. This would let you deal with any changes without requiring a new release. These aren't likely to change on any regular basis, so seem gratuitous.

www.cpan.org
The home page for the Comprehensive Perl Archive Network.
PAUSE
The Perl Authors Upload SErver. The PAUSE FAQ can be seen on CPAN:

    http://www.cpan.org/modules/04pause.html
    
libwww-perl5
The LWP distribution which provides the modules used by this script to talk to the PAUSE web server. You can get the latest version from:

    http://www.cpan.org/modules/by-module/LWP/
    
AppConfig::Std
The module used to handle command-line options and the configuration file.

    http://www.cpan.org/authors/id/NEILB/
    

This is actually a subclass of "AppConfig", which you'll also need.

    http://www.cpan.org/authors/id/ABW/
    
Term::ReadKey
The module used to turn off echo'ing if we prompt the user for a PAUSE password.

$Revision: 2.2 $

CPAN

AppConfig::Std HTTP::Request::Common LWP::UserAgent HTTP::Status File::Basename Term::ReadKey

Neil Bowers <neil@bowers.com>

Brad Fitzpatrick <brad@danga.com> -- HTTP upload support, FTP removal.

Copyright (c) 2001-2002 Neil Bowers.

Copyright (c) 1998-2001 Canon Research Centre Europe. All rights reserved.

This script is free software; you can redistribute it and/or modify it under the same terms as Perl itself.

2007-04-17 perl v5.32.1

Search for    or go to Top of page |  Section 1 |  Main Index

Powered by GSP Visit the GSP FreeBSD Man Page Interface.
Output converted with ManDoc.