wget

From Gentoo Wiki
Jump to:navigation Jump to:search
This article is a stub. Please help out by expanding it - how to get started.

wget is a robust non-interactive HTTP, HTTPS, and FTP client for the terminal that supports the retrieval of data from the world wide web. Originally wget was developed in 1996, written in portable C, as a combined HTTP and FTP client with a consistent ABI for the two protocols. Today, wget is commonly used for scripted data retrieval of content published on the Internet and is the backbone of a great many shell scripts written for this purpose.

It is expected that wget2 will slowly replace the original wget client. Being a complete rewrite, wget2 has a number of architectural improvements over the original such as parallel connections and HTTP/2 support.

Installation

USE flags

USE flags for net-misc/wget Network utility to retrieve files from the WWW

+ssl Add support for SSL/TLS connections (Secure Socket Layer / Transport Layer Security)
cookie-check Enable cookie checks via net-libs/libpsl
debug Enable extra debug codepaths, like asserts and extra output. If you want to get meaningful backtraces see https://wiki.gentoo.org/wiki/Project:Quality_Assurance/Backtraces
gnutls Prefer net-libs/gnutls as SSL/TLS provider (ineffective with USE=-ssl)
idn Enable support for Internationalized Domain Names
ipv6 Add support for IP version 6
libproxy Support for automatic proxy configuration management through net-libs/libproxy.
metalink Enable support for media-libs/libmetalink
nls Add Native Language Support (using gettext - GNU locale utilities)
ntlm Enable support for NTLM (Windows-based) authorization
pcre Add support for Perl Compatible Regular Expressions
static !!do not set this during bootstrap!! Causes binaries to be statically linked instead of dynamically
test Enable dependencies and/or preparations necessary to run tests (usually controlled by FEATURES=test but can be toggled independently)
uuid Generate UUIDs for the WARC (Web ARChive file format) using libuuid; otherwise use a simple RNG (random number generator)
verify-sig Verify upstream signatures on distfiles
zlib Add support for zlib compression

Emerge

root #emerge --ask net-misc/wget

Configuration

Environment variables

  • http_proxy and https_proxy If set these variables contain the HTTP and/or HTTPS proxy URLs.
  • ftp_proxy If set this variable contains the FTP proxy URL.
  • no_proxy If set this variable contains a comma separated list of domains that will not be routed through a proxy server. This variable is typically used to eliminate the need to route trusted Intranet traffic through a proxy.

Files

  • /etc/wgetrc the default location of the system-wide wget configuration file.
  • ~/.wgetrc the user specific wget configuration file.

Usage

Invocation

user $wget --help

See also