| 1 | |
| 2 | |
| 3 | |
| 4 | |
| 5 | |
| 6 | |
| 7 | |
| 8 | |
| 9 | |
| 10 | |
| 11 | |
| 12 | |
| 13 | |
| 14 | |
| 15 | |
| 16 | |
| 17 | |
| 18 | |
| 19 | |
| 20 | |
| 21 | |
| 22 | |
| 23 | |
| 24 | |
| 25 |
|
| 26 | (define-module (gnu packages wget)
|
| 27 | #:use-module ((guix licenses) #:prefix license:)
|
| 28 | #:use-module (guix gexp)
|
| 29 | #:use-module (gnu packages)
|
| 30 | #:use-module (gnu packages bash)
|
| 31 | #:use-module (gnu packages compression)
|
| 32 | #:use-module (gnu packages documentation)
|
| 33 | #:use-module (gnu packages gnunet)
|
| 34 | #:use-module (gnu packages gnupg)
|
| 35 | #:use-module (gnu packages libidn)
|
| 36 | #:use-module (gnu packages pcre)
|
| 37 | #:use-module (gnu packages perl)
|
| 38 | #:use-module (gnu packages pkg-config)
|
| 39 | #:use-module (gnu packages python)
|
| 40 | #:use-module (gnu packages tls)
|
| 41 | #:use-module (gnu packages web)
|
| 42 | #:use-module (gnu packages xdisorg)
|
| 43 | #:use-module (guix packages)
|
| 44 | #:use-module (guix download)
|
| 45 | #:use-module (guix git-download)
|
| 46 | #:use-module (guix build-system gnu))
|
| 47 |
|
| 48 | (define-public wget
|
| 49 | (package
|
| 50 | (name "wget")
|
| 51 | (version "1.25.0")
|
| 52 | (source
|
| 53 | (origin
|
| 54 | (method url-fetch)
|
| 55 | (uri (string-append "mirror://gnu/wget/wget-" version ".tar.lz"))
|
| 56 | (sha256
|
| 57 | (base32 "07waw3s51zmjqzqq717xyyd353qc1ajcd38lh7y8i85hav3mq8hr"))))
|
| 58 | (build-system gnu-build-system)
|
| 59 | (inputs
|
| 60 | (list gnutls libidn2 libpsl))
|
| 61 | (native-inputs
|
| 62 | (list lzip
|
| 63 | pkg-config
|
| 64 | perl
|
| 65 | python |
| 66 | perl-http-daemon
|
| 67 | perl-io-socket-ssl))
|
| 68 | (home-page "https://www.gnu.org/software/wget/")
|
| 69 | (synopsis "Non-interactive command-line utility for downloading files")
|
| 70 | (description
|
| 71 | "GNU Wget is a non-interactive tool for fetching files using the HTTP,
|
| 72 | HTTPS and FTP protocols. It can resume interrupted downloads, use file name
|
| 73 | wild cards, supports proxies and cookies, and it can convert absolute links
|
| 74 | in downloaded documents to relative links.")
|
| 75 | (license license:gpl3+))) |
| 76 |
|
| 77 | (define-public wgetpaste
|
| 78 | (package
|
| 79 | (name "wgetpaste")
|
| 80 | (version "2.34")
|
| 81 | (source
|
| 82 | (origin
|
| 83 | (method git-fetch)
|
| 84 | (uri (git-reference
|
| 85 | (url "https://github.com/zlin/wgetpaste")
|
| 86 | (commit version)))
|
| 87 | (file-name (git-file-name name version))
|
| 88 | (sha256
|
| 89 | (base32 "1z70wfzkrzlhhqm82i5gdk6clmsc06n9gsf2wizb1kzk3h61h296"))))
|
| 90 | (build-system gnu-build-system)
|
| 91 | (arguments
|
| 92 | `(#:modules ((guix build gnu-build-system)
|
| 93 | (guix build utils)
|
| 94 | (srfi srfi-1))
|
| 95 | #:phases
|
| 96 | (modify-phases %standard-phases
|
| 97 | (delete 'configure)
|
| 98 | (delete 'build)
|
| 99 | (replace 'install
|
| 100 | (lambda* (#:key outputs #:allow-other-keys)
|
| 101 | (let* ((out (assoc-ref outputs "out"))
|
| 102 | (bin (string-append out "/bin"))
|
| 103 | (zsh (string-append out "/share/zsh/site-functions")))
|
| 104 | (install-file "wgetpaste" bin)
|
| 105 | (install-file "_wgetpaste" zsh))))
|
| 106 | (add-after 'install 'wrap-program
|
| 107 | |
| 108 | |
| 109 | |
| 110 | (lambda* (#:key outputs #:allow-other-keys)
|
| 111 | (let ((out (assoc-ref outputs "out")))
|
| 112 | (wrap-program (string-append out "/bin/wgetpaste")
|
| 113 | `("PATH" ":" =
|
| 114 | ,(delete-duplicates
|
| 115 | (map (lambda (command) (dirname (which command)))
|
| 116 | (list "bash" "mktemp" "sed" "sort" "tee" "tr"
|
| 117 | "wget" "xclip")))))))))
|
| 118 | #:tests? #f)) |
| 119 | (inputs
|
| 120 | (list bash-minimal wget xclip))
|
| 121 | (home-page "https://wgetpaste.zlin.dk/")
|
| 122 | (synopsis "Script that automates pasting to a number of pastebin services")
|
| 123 | (description
|
| 124 | "@code{wgetpaste} is an extremely simple command-line interface to various
|
| 125 | online pastebin services.")
|
| 126 | (license license:expat)))
|
| 127 |
|
| 128 | (define-public wget2
|
| 129 | (package
|
| 130 | (name "wget2")
|
| 131 | (version "2.2.1")
|
| 132 | (source (origin
|
| 133 | (method url-fetch)
|
| 134 | (uri (string-append "mirror://gnu/wget/wget2-" version ".tar.gz"))
|
| 135 | (sha256
|
| 136 | (base32
|
| 137 | "1d27nhgywchsn3xy0hcmmgbc32k881gmzkjg4h0yc63zwc9lnm6p"))))
|
| 138 | (build-system gnu-build-system)
|
| 139 | (arguments
|
| 140 | (list #:phases #~(modify-phases %standard-phases
|
| 141 | (add-after 'unpack 'skip-network-tests
|
| 142 | (lambda _
|
| 143 | (substitute* "tests/Makefile.in"
|
| 144 | (("test-gpg-verify-no-file\\$\\(EXEEXT)") "")
|
| 145 | (("test-gpg-valid\\$\\(EXEEXT)") "")
|
| 146 | (("test-gpg-styles\\$\\(EXEEXT)") "")))))
|
| 147 | #:configure-flags
|
| 148 | #~(list "--enable-static=no"
|
| 149 | "--with-bzip2=yes"
|
| 150 | "--with-lzma=yes")))
|
| 151 | (inputs (list brotli
|
| 152 | bzip2
|
| 153 | gnutls/dane
|
| 154 | gpgme
|
| 155 | libidn2
|
| 156 | libmicrohttpd
|
| 157 | libpsl
|
| 158 | `(,nghttp2 "lib")
|
| 159 | pcre2
|
| 160 | xz
|
| 161 | zlib
|
| 162 | `(,zstd "lib")))
|
| 163 | |
| 164 | (native-inputs (list pkg-config))
|
| 165 | (home-page "https://gitlab.com/gnuwget/wget2")
|
| 166 | (synopsis "Successor of GNU Wget")
|
| 167 | (description
|
| 168 | "GNU Wget2 is the successor of GNU Wget, a file and recursive website
|
| 169 | downloader. Designed and written from scratch it wraps around libwget, that
|
| 170 | provides the basic functions needed by a web client.")
|
| 171 | (properties '((ftp-directory . "/gnu/wget")))
|
| 172 | (license (list license:gpl3+ license:lgpl3+))))
|