2020-10-17 02:57:30 +02:00
|
|
|
;;; url-vars.el --- Variables for Uniform Resource Locator tool -*- lexical-binding:t -*-
|
2004-10-19 21:37:32 +00:00
|
|
|
|
2025-01-01 07:39:17 +00:00
|
|
|
;; Copyright (C) 1996-2025 Free Software Foundation, Inc.
|
2004-10-19 21:37:32 +00:00
|
|
|
|
2004-04-04 01:21:46 +00:00
|
|
|
;; Keywords: comm, data, processes, hypermedia
|
|
|
|
|
2004-10-19 21:37:32 +00:00
|
|
|
;; This file is part of GNU Emacs.
|
|
|
|
|
2008-05-06 04:29:13 +00:00
|
|
|
;; GNU Emacs is free software: you can redistribute it and/or modify
|
2004-10-19 21:37:32 +00:00
|
|
|
;; it under the terms of the GNU General Public License as published by
|
2008-05-06 04:29:13 +00:00
|
|
|
;; the Free Software Foundation, either version 3 of the License, or
|
|
|
|
;; (at your option) any later version.
|
2004-10-19 21:37:32 +00:00
|
|
|
|
|
|
|
;; GNU Emacs is distributed in the hope that it will be useful,
|
|
|
|
;; but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
;; GNU General Public License for more details.
|
|
|
|
|
|
|
|
;; You should have received a copy of the GNU General Public License
|
2017-09-13 15:52:52 -07:00
|
|
|
;; along with GNU Emacs. If not, see <https://www.gnu.org/licenses/>.
|
2004-10-19 21:37:32 +00:00
|
|
|
|
2021-09-21 11:14:14 +02:00
|
|
|
;;; Commentary:
|
|
|
|
|
2004-10-19 21:37:32 +00:00
|
|
|
;;; Code:
|
2004-04-04 01:21:46 +00:00
|
|
|
|
|
|
|
(defgroup url nil
|
2005-07-04 01:13:26 +00:00
|
|
|
"Uniform Resource Locator tool."
|
2005-02-09 15:50:47 +00:00
|
|
|
:version "22.1"
|
2014-01-25 20:15:42 +01:00
|
|
|
:link '(custom-manual "(url) Top")
|
|
|
|
:link '(info-link "(url) Customization")
|
2010-03-12 14:13:38 -05:00
|
|
|
:group 'comm)
|
2004-04-04 01:21:46 +00:00
|
|
|
|
|
|
|
(defgroup url-file nil
|
2005-07-04 01:13:26 +00:00
|
|
|
"URL storage."
|
2004-04-04 01:21:46 +00:00
|
|
|
:prefix "url-"
|
|
|
|
:group 'url)
|
|
|
|
|
|
|
|
(defgroup url-cache nil
|
2005-07-04 01:13:26 +00:00
|
|
|
"URL cache."
|
2004-04-04 01:21:46 +00:00
|
|
|
:prefix "url-"
|
|
|
|
:prefix "url-cache-"
|
|
|
|
:group 'url)
|
|
|
|
|
|
|
|
(defgroup url-mime nil
|
2005-07-04 01:13:26 +00:00
|
|
|
"MIME options of URL."
|
2004-04-04 01:21:46 +00:00
|
|
|
:prefix "url-"
|
|
|
|
:group 'url)
|
|
|
|
|
|
|
|
(defgroup url-hairy nil
|
2005-07-04 01:13:26 +00:00
|
|
|
"Hairy options of URL."
|
2004-04-04 01:21:46 +00:00
|
|
|
:prefix "url-"
|
|
|
|
:group 'url)
|
|
|
|
|
|
|
|
|
Prefer defvar-local in remaining libraries
* lisp/align.el (align-mode-rules-list)
(align-mode-exclude-rules-list):
* lisp/bookmark.el (bookmark-current-bookmark)
(bookmark-annotation-name)
(bookmark--annotation-from-bookmark-list):
* lisp/calc/calc-embed.el (calc-embedded-all-active)
(calc-embedded-some-active):
* lisp/comint.el (comint-password-function):
* lisp/completion.el (completion-syntax-table):
* lisp/dframe.el (dframe-track-mouse-function)
(dframe-help-echo-function, dframe-mouse-click-function)
(dframe-mouse-position-function, dframe-timer)
(dframe-attached-frame, dframe-controlled):
* lisp/ehelp.el (electric-help-orig-major-mode):
* lisp/eshell/esh-util.el (eshell-path-env):
* lisp/expand.el (expand-pos, expand-index, expand-point):
* lisp/face-remap.el (text-scale-mode-remapping)
(text-scale-mode-lighter, text-scale-mode-amount)
(text-scale-remap-header-line, buffer-face-mode-remapping):
* lisp/ffap.el (ffap-menu-alist):
* lisp/files-x.el (connection-local-variables-alist):
* lisp/foldout.el (foldout-fold-list, foldout-mode-line-string):
* lisp/follow.el (follow-start-end-invalid):
* lisp/forms.el (forms--mode-setup):
* lisp/gnus/message.el (message-cross-post-old-target)
(message-options):
* lisp/help-mode.el (help-xref-stack, help-xref-forward-stack)
(help-xref-stack-item, help-xref-stack-forward-item):
* lisp/hexl.el (hexl-mode--old-var-vals, hexl-ascii-overlay):
* lisp/hilit-chg.el (hilit-chg-string):
* lisp/ido.el (ido-eoinput):
* lisp/imenu.el (imenu-generic-expression)
(imenu-create-index-function, imenu-default-goto-function)
(imenu-prev-index-position-function)
(imenu-extract-index-name-function, imenu-name-lookup-function)
(imenu-syntax-alist, imenu-case-fold-search):
* lisp/jka-compr.el (jka-compr-really-do-compress):
* lisp/language/ethio-util.el (ethio-prefer-ascii-space):
* lisp/leim/quail/hangul.el (hangul-input-method-help-text):
* lisp/leim/quail/japanese.el (quail-japanese-package-saved):
* lisp/linum.el (linum-overlays, linum-available):
* lisp/man.el (Man-original-frame, Man-arguments, Man--sections)
(Man--refpages, Man-page-list, Man-current-page)
(Man-page-mode-string):
* lisp/pcomplete.el (pcomplete-current-completions)
(pcomplete-last-completion-length)
(pcomplete-last-completion-stub, pcomplete-last-completion-raw)
(pcomplete-last-window-config, pcomplete-window-restore-timer):
* lisp/reveal.el (reveal-open-spots, reveal-last-tick):
* lisp/ruler-mode.el (ruler-mode):
* lisp/scroll-lock.el (scroll-lock-preserve-screen-pos-save):
* lisp/server.el (server-buffer-clients, server-existing-buffer):
* lisp/tab-line.el (tab-line-exclude):
* lisp/tar-mode.el (tar-data-buffer, tar-data-swapped):
* lisp/thumbs.el (thumbs-current-tmp-filename)
(thumbs-current-image-filename, thumbs-extra-images)
(thumbs-image-num, thumbs-buffer, thumbs-marked-list):
* lisp/tutorial.el (tutorial--point-before-chkeys)
(tutorial--point-after-chkeys, tutorial--lang):
* lisp/url/url-vars.el (url-current-object)
(url-current-mime-headers, url-current-lastloc):
* lisp/view.el (view-mode, view-old-buffer-read-only)
(view-old-Helper-return-blurb, view-page-size)
(view-half-page-size, view-last-regexp, view-return-to-alist)
(view-exit-action, view-overlay):
* lisp/wid-edit.el (widget-global-map, widget-field-new)
(widget-field-list, widget-field-last, widget-field-was):
* lisp/woman.el (woman-imenu-done): Prefer defvar-local.
2021-02-02 09:55:40 +01:00
|
|
|
(defvar-local url-current-object nil
|
Typo and docstring fixes.
* url.el (url-do-setup):
* url-dired.el (url-dired-minor-mode):
* url-file.el (url-file-find-possibly-compressed-file):
* url-gw.el (url-gateway-broken-resolution):
* url-handlers.el (url-handler-regexp):
* url-imap.el (url-imap-default-port):
* url-methods.el (url-scheme-get-property): Fix typos in docstrings.
* url-auth.el (url-basic-auth-storage, url-digest-auth):
Fix typos in docstrings.
(url-digest-auth-storage, url-register-auth-scheme): Reflow docstrings.
* url-cache.el (url-cache-prepare): Doc fix.
(url-cache-create-filename-human-readable, url-cache-extract):
Fix typos in docstrings.
* url-dav.el (url-intersection, url-dav-iso8601-regexp)
(url-dav-delete-something): Fix typos in docstrings.
(url-dav-http-success-p, url-dav-file-name-all-completions)
(url-dav-directory-files, url-dav-file-name-completion): Doc fixes.
* url-http.el (url-http-idle-sentinel): Doc fix.
* url-irc.el (url-irc-default-port): Fix typo in docstring.
(url-irc-function): Doc fix.
* url-util.el (url-get-url-filename-chars, url-unhex-string):
Fix typos in docstrings.
(url-file-extension): Doc fix.
* url-vars.el (url-current-object, url-current-mime-headers)
(url-privacy-level, url-mail-command, url-mime-language-string):
Fix typos in docstrings.
(url-honor-refresh-requests): Reflow docstring.
(url-using-proxy): Doc fix.
2008-07-02 11:14:38 +00:00
|
|
|
"A parsed representation of the current URL.")
|
2004-04-04 01:21:46 +00:00
|
|
|
|
Prefer defvar-local in remaining libraries
* lisp/align.el (align-mode-rules-list)
(align-mode-exclude-rules-list):
* lisp/bookmark.el (bookmark-current-bookmark)
(bookmark-annotation-name)
(bookmark--annotation-from-bookmark-list):
* lisp/calc/calc-embed.el (calc-embedded-all-active)
(calc-embedded-some-active):
* lisp/comint.el (comint-password-function):
* lisp/completion.el (completion-syntax-table):
* lisp/dframe.el (dframe-track-mouse-function)
(dframe-help-echo-function, dframe-mouse-click-function)
(dframe-mouse-position-function, dframe-timer)
(dframe-attached-frame, dframe-controlled):
* lisp/ehelp.el (electric-help-orig-major-mode):
* lisp/eshell/esh-util.el (eshell-path-env):
* lisp/expand.el (expand-pos, expand-index, expand-point):
* lisp/face-remap.el (text-scale-mode-remapping)
(text-scale-mode-lighter, text-scale-mode-amount)
(text-scale-remap-header-line, buffer-face-mode-remapping):
* lisp/ffap.el (ffap-menu-alist):
* lisp/files-x.el (connection-local-variables-alist):
* lisp/foldout.el (foldout-fold-list, foldout-mode-line-string):
* lisp/follow.el (follow-start-end-invalid):
* lisp/forms.el (forms--mode-setup):
* lisp/gnus/message.el (message-cross-post-old-target)
(message-options):
* lisp/help-mode.el (help-xref-stack, help-xref-forward-stack)
(help-xref-stack-item, help-xref-stack-forward-item):
* lisp/hexl.el (hexl-mode--old-var-vals, hexl-ascii-overlay):
* lisp/hilit-chg.el (hilit-chg-string):
* lisp/ido.el (ido-eoinput):
* lisp/imenu.el (imenu-generic-expression)
(imenu-create-index-function, imenu-default-goto-function)
(imenu-prev-index-position-function)
(imenu-extract-index-name-function, imenu-name-lookup-function)
(imenu-syntax-alist, imenu-case-fold-search):
* lisp/jka-compr.el (jka-compr-really-do-compress):
* lisp/language/ethio-util.el (ethio-prefer-ascii-space):
* lisp/leim/quail/hangul.el (hangul-input-method-help-text):
* lisp/leim/quail/japanese.el (quail-japanese-package-saved):
* lisp/linum.el (linum-overlays, linum-available):
* lisp/man.el (Man-original-frame, Man-arguments, Man--sections)
(Man--refpages, Man-page-list, Man-current-page)
(Man-page-mode-string):
* lisp/pcomplete.el (pcomplete-current-completions)
(pcomplete-last-completion-length)
(pcomplete-last-completion-stub, pcomplete-last-completion-raw)
(pcomplete-last-window-config, pcomplete-window-restore-timer):
* lisp/reveal.el (reveal-open-spots, reveal-last-tick):
* lisp/ruler-mode.el (ruler-mode):
* lisp/scroll-lock.el (scroll-lock-preserve-screen-pos-save):
* lisp/server.el (server-buffer-clients, server-existing-buffer):
* lisp/tab-line.el (tab-line-exclude):
* lisp/tar-mode.el (tar-data-buffer, tar-data-swapped):
* lisp/thumbs.el (thumbs-current-tmp-filename)
(thumbs-current-image-filename, thumbs-extra-images)
(thumbs-image-num, thumbs-buffer, thumbs-marked-list):
* lisp/tutorial.el (tutorial--point-before-chkeys)
(tutorial--point-after-chkeys, tutorial--lang):
* lisp/url/url-vars.el (url-current-object)
(url-current-mime-headers, url-current-lastloc):
* lisp/view.el (view-mode, view-old-buffer-read-only)
(view-old-Helper-return-blurb, view-page-size)
(view-half-page-size, view-last-regexp, view-return-to-alist)
(view-exit-action, view-overlay):
* lisp/wid-edit.el (widget-global-map, widget-field-new)
(widget-field-list, widget-field-last, widget-field-was):
* lisp/woman.el (woman-imenu-done): Prefer defvar-local.
2021-02-02 09:55:40 +01:00
|
|
|
(defvar-local url-current-mime-headers nil
|
Typo and docstring fixes.
* url.el (url-do-setup):
* url-dired.el (url-dired-minor-mode):
* url-file.el (url-file-find-possibly-compressed-file):
* url-gw.el (url-gateway-broken-resolution):
* url-handlers.el (url-handler-regexp):
* url-imap.el (url-imap-default-port):
* url-methods.el (url-scheme-get-property): Fix typos in docstrings.
* url-auth.el (url-basic-auth-storage, url-digest-auth):
Fix typos in docstrings.
(url-digest-auth-storage, url-register-auth-scheme): Reflow docstrings.
* url-cache.el (url-cache-prepare): Doc fix.
(url-cache-create-filename-human-readable, url-cache-extract):
Fix typos in docstrings.
* url-dav.el (url-intersection, url-dav-iso8601-regexp)
(url-dav-delete-something): Fix typos in docstrings.
(url-dav-http-success-p, url-dav-file-name-all-completions)
(url-dav-directory-files, url-dav-file-name-completion): Doc fixes.
* url-http.el (url-http-idle-sentinel): Doc fix.
* url-irc.el (url-irc-default-port): Fix typo in docstring.
(url-irc-function): Doc fix.
* url-util.el (url-get-url-filename-chars, url-unhex-string):
Fix typos in docstrings.
(url-file-extension): Doc fix.
* url-vars.el (url-current-object, url-current-mime-headers)
(url-privacy-level, url-mail-command, url-mime-language-string):
Fix typos in docstrings.
(url-honor-refresh-requests): Reflow docstring.
(url-using-proxy): Doc fix.
2008-07-02 11:14:38 +00:00
|
|
|
"A parsed representation of the MIME headers for the current URL.")
|
2004-04-04 01:21:46 +00:00
|
|
|
|
Prefer defvar-local in remaining libraries
* lisp/align.el (align-mode-rules-list)
(align-mode-exclude-rules-list):
* lisp/bookmark.el (bookmark-current-bookmark)
(bookmark-annotation-name)
(bookmark--annotation-from-bookmark-list):
* lisp/calc/calc-embed.el (calc-embedded-all-active)
(calc-embedded-some-active):
* lisp/comint.el (comint-password-function):
* lisp/completion.el (completion-syntax-table):
* lisp/dframe.el (dframe-track-mouse-function)
(dframe-help-echo-function, dframe-mouse-click-function)
(dframe-mouse-position-function, dframe-timer)
(dframe-attached-frame, dframe-controlled):
* lisp/ehelp.el (electric-help-orig-major-mode):
* lisp/eshell/esh-util.el (eshell-path-env):
* lisp/expand.el (expand-pos, expand-index, expand-point):
* lisp/face-remap.el (text-scale-mode-remapping)
(text-scale-mode-lighter, text-scale-mode-amount)
(text-scale-remap-header-line, buffer-face-mode-remapping):
* lisp/ffap.el (ffap-menu-alist):
* lisp/files-x.el (connection-local-variables-alist):
* lisp/foldout.el (foldout-fold-list, foldout-mode-line-string):
* lisp/follow.el (follow-start-end-invalid):
* lisp/forms.el (forms--mode-setup):
* lisp/gnus/message.el (message-cross-post-old-target)
(message-options):
* lisp/help-mode.el (help-xref-stack, help-xref-forward-stack)
(help-xref-stack-item, help-xref-stack-forward-item):
* lisp/hexl.el (hexl-mode--old-var-vals, hexl-ascii-overlay):
* lisp/hilit-chg.el (hilit-chg-string):
* lisp/ido.el (ido-eoinput):
* lisp/imenu.el (imenu-generic-expression)
(imenu-create-index-function, imenu-default-goto-function)
(imenu-prev-index-position-function)
(imenu-extract-index-name-function, imenu-name-lookup-function)
(imenu-syntax-alist, imenu-case-fold-search):
* lisp/jka-compr.el (jka-compr-really-do-compress):
* lisp/language/ethio-util.el (ethio-prefer-ascii-space):
* lisp/leim/quail/hangul.el (hangul-input-method-help-text):
* lisp/leim/quail/japanese.el (quail-japanese-package-saved):
* lisp/linum.el (linum-overlays, linum-available):
* lisp/man.el (Man-original-frame, Man-arguments, Man--sections)
(Man--refpages, Man-page-list, Man-current-page)
(Man-page-mode-string):
* lisp/pcomplete.el (pcomplete-current-completions)
(pcomplete-last-completion-length)
(pcomplete-last-completion-stub, pcomplete-last-completion-raw)
(pcomplete-last-window-config, pcomplete-window-restore-timer):
* lisp/reveal.el (reveal-open-spots, reveal-last-tick):
* lisp/ruler-mode.el (ruler-mode):
* lisp/scroll-lock.el (scroll-lock-preserve-screen-pos-save):
* lisp/server.el (server-buffer-clients, server-existing-buffer):
* lisp/tab-line.el (tab-line-exclude):
* lisp/tar-mode.el (tar-data-buffer, tar-data-swapped):
* lisp/thumbs.el (thumbs-current-tmp-filename)
(thumbs-current-image-filename, thumbs-extra-images)
(thumbs-image-num, thumbs-buffer, thumbs-marked-list):
* lisp/tutorial.el (tutorial--point-before-chkeys)
(tutorial--point-after-chkeys, tutorial--lang):
* lisp/url/url-vars.el (url-current-object)
(url-current-mime-headers, url-current-lastloc):
* lisp/view.el (view-mode, view-old-buffer-read-only)
(view-old-Helper-return-blurb, view-page-size)
(view-half-page-size, view-last-regexp, view-return-to-alist)
(view-exit-action, view-overlay):
* lisp/wid-edit.el (widget-global-map, widget-field-new)
(widget-field-list, widget-field-last, widget-field-was):
* lisp/woman.el (woman-imenu-done): Prefer defvar-local.
2021-02-02 09:55:40 +01:00
|
|
|
(defvar-local url-current-lastloc nil
|
2018-04-13 15:08:18 +02:00
|
|
|
"A parsed representation of the URL to be considered as the last location.
|
|
|
|
Use of this value on outbound connections is subject to
|
|
|
|
`url-privacy-level' and `url-lastloc-privacy-level'. This is never set
|
|
|
|
by the url library, applications are expected to set this
|
|
|
|
variable in buffers representing a displayed location.")
|
|
|
|
|
2004-04-04 01:21:46 +00:00
|
|
|
(defcustom url-honor-refresh-requests t
|
2010-09-10 18:58:42 -07:00
|
|
|
"Whether to do automatic page reloads.
|
2004-04-04 01:21:46 +00:00
|
|
|
These are done at the request of the document author or the server via
|
|
|
|
the `Refresh' header in an HTTP response. If nil, no refresh
|
|
|
|
requests will be honored. If t, all refresh requests will be honored.
|
Typo and docstring fixes.
* url.el (url-do-setup):
* url-dired.el (url-dired-minor-mode):
* url-file.el (url-file-find-possibly-compressed-file):
* url-gw.el (url-gateway-broken-resolution):
* url-handlers.el (url-handler-regexp):
* url-imap.el (url-imap-default-port):
* url-methods.el (url-scheme-get-property): Fix typos in docstrings.
* url-auth.el (url-basic-auth-storage, url-digest-auth):
Fix typos in docstrings.
(url-digest-auth-storage, url-register-auth-scheme): Reflow docstrings.
* url-cache.el (url-cache-prepare): Doc fix.
(url-cache-create-filename-human-readable, url-cache-extract):
Fix typos in docstrings.
* url-dav.el (url-intersection, url-dav-iso8601-regexp)
(url-dav-delete-something): Fix typos in docstrings.
(url-dav-http-success-p, url-dav-file-name-all-completions)
(url-dav-directory-files, url-dav-file-name-completion): Doc fixes.
* url-http.el (url-http-idle-sentinel): Doc fix.
* url-irc.el (url-irc-default-port): Fix typo in docstring.
(url-irc-function): Doc fix.
* url-util.el (url-get-url-filename-chars, url-unhex-string):
Fix typos in docstrings.
(url-file-extension): Doc fix.
* url-vars.el (url-current-object, url-current-mime-headers)
(url-privacy-level, url-mail-command, url-mime-language-string):
Fix typos in docstrings.
(url-honor-refresh-requests): Reflow docstring.
(url-using-proxy): Doc fix.
2008-07-02 11:14:38 +00:00
|
|
|
If non-nil and not t, the user will be asked for each refresh request."
|
2004-04-04 01:21:46 +00:00
|
|
|
:type '(choice (const :tag "off" nil)
|
|
|
|
(const :tag "on" t)
|
2013-12-27 17:24:15 -08:00
|
|
|
(other :tag "ask" ask))
|
2004-04-04 01:21:46 +00:00
|
|
|
:group 'url-hairy)
|
|
|
|
|
|
|
|
(defcustom url-automatic-caching nil
|
2010-09-10 18:58:42 -07:00
|
|
|
"If non-nil, all documents will be automatically cached to the local disk."
|
2004-04-04 01:21:46 +00:00
|
|
|
:type 'boolean
|
|
|
|
:group 'url-cache)
|
|
|
|
|
2014-03-28 19:02:02 -04:00
|
|
|
(define-obsolete-variable-alias 'url-bug-address
|
|
|
|
'report-emacs-bug-address "24.5")
|
2004-04-04 01:21:46 +00:00
|
|
|
|
|
|
|
(defcustom url-personal-mail-address nil
|
2010-09-10 18:58:42 -07:00
|
|
|
"Your full email address.
|
2004-04-04 01:21:46 +00:00
|
|
|
This is what is sent to HTTP servers as the FROM field in an HTTP
|
|
|
|
request."
|
|
|
|
:type '(choice (const :tag "Unspecified" nil) string)
|
|
|
|
:group 'url)
|
2023-12-17 09:45:05 +01:00
|
|
|
(make-obsolete-variable 'url-personal-mail-address nil "30.1")
|
2004-04-04 01:21:46 +00:00
|
|
|
|
|
|
|
(defcustom url-directory-index-file "index.html"
|
2010-09-10 18:58:42 -07:00
|
|
|
"The filename to look for when indexing a directory.
|
2004-04-04 01:21:46 +00:00
|
|
|
If this file exists, and is readable, then it will be viewed instead of
|
|
|
|
using `dired' to view the directory."
|
|
|
|
:type 'string
|
|
|
|
:group 'url-file)
|
|
|
|
|
|
|
|
(defcustom url-privacy-level '(email)
|
2006-01-10 19:14:38 +00:00
|
|
|
"How private you want your requests to be.
|
2004-04-04 01:21:46 +00:00
|
|
|
HTTP has header fields for various information about the user, including
|
|
|
|
operating system information, email addresses, the last page you visited, etc.
|
|
|
|
This variable controls how much of this information is sent.
|
|
|
|
|
|
|
|
This should a symbol or a list.
|
|
|
|
Valid values if a symbol are:
|
Typo and docstring fixes.
* url.el (url-do-setup):
* url-dired.el (url-dired-minor-mode):
* url-file.el (url-file-find-possibly-compressed-file):
* url-gw.el (url-gateway-broken-resolution):
* url-handlers.el (url-handler-regexp):
* url-imap.el (url-imap-default-port):
* url-methods.el (url-scheme-get-property): Fix typos in docstrings.
* url-auth.el (url-basic-auth-storage, url-digest-auth):
Fix typos in docstrings.
(url-digest-auth-storage, url-register-auth-scheme): Reflow docstrings.
* url-cache.el (url-cache-prepare): Doc fix.
(url-cache-create-filename-human-readable, url-cache-extract):
Fix typos in docstrings.
* url-dav.el (url-intersection, url-dav-iso8601-regexp)
(url-dav-delete-something): Fix typos in docstrings.
(url-dav-http-success-p, url-dav-file-name-all-completions)
(url-dav-directory-files, url-dav-file-name-completion): Doc fixes.
* url-http.el (url-http-idle-sentinel): Doc fix.
* url-irc.el (url-irc-default-port): Fix typo in docstring.
(url-irc-function): Doc fix.
* url-util.el (url-get-url-filename-chars, url-unhex-string):
Fix typos in docstrings.
(url-file-extension): Doc fix.
* url-vars.el (url-current-object, url-current-mime-headers)
(url-privacy-level, url-mail-command, url-mime-language-string):
Fix typos in docstrings.
(url-honor-refresh-requests): Reflow docstring.
(url-using-proxy): Doc fix.
2008-07-02 11:14:38 +00:00
|
|
|
none -- send all information
|
|
|
|
low -- don't send the last location
|
|
|
|
high -- don't send the email address or last location
|
|
|
|
paranoid -- don't send anything
|
2004-04-04 01:21:46 +00:00
|
|
|
|
|
|
|
If a list, this should be a list of symbols of what NOT to send.
|
|
|
|
Valid symbols are:
|
2023-12-17 09:45:05 +01:00
|
|
|
email -- the email address (in Emacs 29 or older)
|
2004-04-04 01:21:46 +00:00
|
|
|
os -- the operating system info
|
2016-04-24 14:51:33 +02:00
|
|
|
emacs -- the version of Emacs
|
2018-04-13 15:08:18 +02:00
|
|
|
lastloc -- the last location (see also `url-lastloc-privacy-level')
|
Typo and docstring fixes.
* url.el (url-do-setup):
* url-dired.el (url-dired-minor-mode):
* url-file.el (url-file-find-possibly-compressed-file):
* url-gw.el (url-gateway-broken-resolution):
* url-handlers.el (url-handler-regexp):
* url-imap.el (url-imap-default-port):
* url-methods.el (url-scheme-get-property): Fix typos in docstrings.
* url-auth.el (url-basic-auth-storage, url-digest-auth):
Fix typos in docstrings.
(url-digest-auth-storage, url-register-auth-scheme): Reflow docstrings.
* url-cache.el (url-cache-prepare): Doc fix.
(url-cache-create-filename-human-readable, url-cache-extract):
Fix typos in docstrings.
* url-dav.el (url-intersection, url-dav-iso8601-regexp)
(url-dav-delete-something): Fix typos in docstrings.
(url-dav-http-success-p, url-dav-file-name-all-completions)
(url-dav-directory-files, url-dav-file-name-completion): Doc fixes.
* url-http.el (url-http-idle-sentinel): Doc fix.
* url-irc.el (url-irc-default-port): Fix typo in docstring.
(url-irc-function): Doc fix.
* url-util.el (url-get-url-filename-chars, url-unhex-string):
Fix typos in docstrings.
(url-file-extension): Doc fix.
* url-vars.el (url-current-object, url-current-mime-headers)
(url-privacy-level, url-mail-command, url-mime-language-string):
Fix typos in docstrings.
(url-honor-refresh-requests): Reflow docstring.
(url-using-proxy): Doc fix.
2008-07-02 11:14:38 +00:00
|
|
|
agent -- do not send the User-Agent string
|
2010-06-12 00:25:20 -07:00
|
|
|
cookies -- never accept HTTP cookies
|
2004-04-04 01:21:46 +00:00
|
|
|
|
2023-12-17 09:45:05 +01:00
|
|
|
Emacs 30 and newer never includes the email address in the
|
|
|
|
User-Agent string. If you expect to use older versions of Emacs,
|
|
|
|
it is recommended to always customize this list to include `email'.
|
|
|
|
|
2004-04-04 01:21:46 +00:00
|
|
|
Samples:
|
|
|
|
|
2015-09-03 15:31:12 -07:00
|
|
|
(setq url-privacy-level \\='high)
|
|
|
|
(setq url-privacy-level \\='(email lastloc)) ;; equivalent to \\='high
|
2023-12-17 09:45:05 +01:00
|
|
|
(setq url-privacy-level \\='(email lastloc os emacs))
|
2004-04-04 01:21:46 +00:00
|
|
|
|
|
|
|
::NOTE::
|
|
|
|
This variable controls several other variables and is _NOT_ automatically
|
|
|
|
updated. Call the function `url-setup-privacy-info' after modifying this
|
|
|
|
variable."
|
2022-03-15 10:18:07 -04:00
|
|
|
:initialize #'custom-initialize-default
|
2006-01-10 19:14:38 +00:00
|
|
|
:set (lambda (sym val) (set-default sym val) (url-setup-privacy-info))
|
2004-04-04 01:21:46 +00:00
|
|
|
:type '(radio (const :tag "None (you believe in the basic goodness of humanity)"
|
|
|
|
:value none)
|
|
|
|
(const :tag "Low (do not reveal last location)"
|
|
|
|
:value low)
|
|
|
|
(const :tag "High (no email address or last location)"
|
|
|
|
:value high)
|
|
|
|
(const :tag "Paranoid (reveal nothing!)"
|
|
|
|
:value paranoid)
|
|
|
|
(checklist :tag "Custom"
|
|
|
|
(const :tag "Email address" :value email)
|
|
|
|
(const :tag "Operating system" :value os)
|
2016-04-24 14:51:33 +02:00
|
|
|
(const :tag "Emacs version" :value emacs)
|
2004-04-04 01:21:46 +00:00
|
|
|
(const :tag "Last location" :value lastloc)
|
|
|
|
(const :tag "Browser identification" :value agent)
|
2023-10-22 21:43:46 +02:00
|
|
|
(const :tag "No cookies" :value cookies)))
|
2004-04-04 01:21:46 +00:00
|
|
|
:group 'url)
|
|
|
|
|
2018-04-13 15:08:18 +02:00
|
|
|
(defcustom url-lastloc-privacy-level 'domain-match
|
|
|
|
"Further restrictions on sending the last location.
|
|
|
|
This value is only consulted if `url-privacy-level' permits
|
|
|
|
sending last location in the first place.
|
|
|
|
|
|
|
|
Valid values are:
|
|
|
|
none -- Always send last location.
|
|
|
|
domain-match -- Send last location if the new location is within the
|
|
|
|
same domain
|
|
|
|
host-match -- Send last location if the new location is on the
|
2021-09-14 08:43:18 +02:00
|
|
|
same host"
|
2018-04-13 15:41:35 +02:00
|
|
|
:version "27.1"
|
2018-04-13 15:08:18 +02:00
|
|
|
:type '(radio (const :tag "Always send" none)
|
|
|
|
(const :tag "Domains match" domain-match)
|
|
|
|
(const :tag "Hosts match" host-match))
|
|
|
|
:group 'url)
|
|
|
|
|
2004-04-04 01:21:46 +00:00
|
|
|
(defvar url-inhibit-uncompression nil "Do not do decompression if non-nil.")
|
|
|
|
|
|
|
|
(defcustom url-uncompressor-alist '((".z" . "x-gzip")
|
|
|
|
(".gz" . "x-gzip")
|
|
|
|
(".uue" . "x-uuencoded")
|
|
|
|
(".hqx" . "x-hqx")
|
|
|
|
(".Z" . "x-compress")
|
2012-10-13 18:51:26 +08:00
|
|
|
(".bz2" . "x-bzip2")
|
|
|
|
(".xz" . "x-xz"))
|
2010-09-10 18:58:42 -07:00
|
|
|
"An alist of file extensions and appropriate content-transfer-encodings."
|
2004-04-04 01:21:46 +00:00
|
|
|
:type '(repeat (cons :format "%v"
|
|
|
|
(string :tag "Extension")
|
|
|
|
(string :tag "Encoding")))
|
|
|
|
:group 'url-mime)
|
|
|
|
|
2005-09-17 04:59:02 +00:00
|
|
|
(defcustom url-mail-command 'compose-mail
|
2010-09-10 18:58:42 -07:00
|
|
|
"This function will be called whenever URL needs to send mail.
|
2004-04-04 01:21:46 +00:00
|
|
|
It should enter a mail-mode-like buffer in the current window.
|
|
|
|
The commands `mail-to' and `mail-subject' should still work in this
|
|
|
|
buffer, and it should use `mail-header-separator' if possible."
|
|
|
|
:type 'function
|
|
|
|
:group 'url)
|
|
|
|
|
|
|
|
(defcustom url-proxy-services nil
|
2010-09-10 18:58:42 -07:00
|
|
|
"An alist of schemes and proxy servers that gateway them.
|
2004-04-04 01:21:46 +00:00
|
|
|
Looks like ((\"http\" . \"hostname:portnumber\") ...). This is set up
|
|
|
|
from the ACCESS_proxy environment variables."
|
|
|
|
:type '(repeat (cons :format "%v"
|
|
|
|
(string :tag "Protocol")
|
|
|
|
(string :tag "Proxy")))
|
|
|
|
:group 'url)
|
|
|
|
|
|
|
|
(defcustom url-standalone-mode nil
|
2010-09-10 18:58:42 -07:00
|
|
|
"Rely solely on the cache?"
|
2004-04-04 01:21:46 +00:00
|
|
|
:type 'boolean
|
|
|
|
:group 'url-cache)
|
|
|
|
|
2022-03-15 10:18:07 -04:00
|
|
|
(defvar url-mime-separator-chars (append "ABCDEFGHIJKLMNOPQRSTUVWXYZ"
|
|
|
|
"abcdefghijklmnopqrstuvwxyz"
|
2022-07-15 15:59:12 -04:00
|
|
|
"0123456789'()+_,-./=?"
|
|
|
|
nil)
|
2004-04-04 01:21:46 +00:00
|
|
|
"Characters allowable in a MIME multipart separator.")
|
|
|
|
|
|
|
|
(defcustom url-bad-port-list
|
|
|
|
'("25" "119" "19")
|
2010-09-10 18:58:42 -07:00
|
|
|
"List of ports to warn the user about connecting to.
|
2004-04-04 01:21:46 +00:00
|
|
|
Defaults to just the mail, chargen, and NNTP ports so you cannot be
|
|
|
|
tricked into sending fake mail or forging messages by a malicious HTML
|
|
|
|
document."
|
|
|
|
:type '(repeat (string :tag "Port"))
|
|
|
|
:group 'url-hairy)
|
|
|
|
|
|
|
|
(defvar url-mime-content-type-charset-regexp
|
|
|
|
";[ \t]*charset=\"?\\([^\"]+\\)\"?"
|
|
|
|
"Regexp used in parsing `Content-Type' for a charset indication.")
|
|
|
|
|
|
|
|
(defvar url-request-data nil "Any data to send with the next request.")
|
|
|
|
|
|
|
|
(defvar url-request-extra-headers nil
|
|
|
|
"A list of extra headers to send with the next request.
|
|
|
|
Should be an assoc list of headers/contents.")
|
|
|
|
|
2014-11-23 15:05:18 +01:00
|
|
|
(defvar url-request-noninteractive nil
|
|
|
|
"If non-nil, the request is done in a noninteractive context.")
|
|
|
|
|
2004-04-04 01:21:46 +00:00
|
|
|
(defvar url-request-method nil "The method to use for the next request.")
|
|
|
|
|
2013-09-13 00:01:55 -07:00
|
|
|
(defvar url-mime-encoding-string (and (fboundp 'zlib-available-p)
|
2013-08-12 19:02:31 +02:00
|
|
|
(zlib-available-p)
|
2013-08-11 22:52:50 +02:00
|
|
|
"gzip")
|
2012-04-09 21:05:48 +08:00
|
|
|
"String to send in the Accept-encoding: field in HTTP requests.")
|
2004-04-04 01:21:46 +00:00
|
|
|
|
2012-06-30 14:13:05 -07:00
|
|
|
(defvar mm-mime-mule-charset-alist)
|
|
|
|
|
2004-04-04 01:21:46 +00:00
|
|
|
;; Perhaps the first few should actually be given decreasing `q's and
|
|
|
|
;; the list should be trimmed significantly.
|
|
|
|
(defun url-mime-charset-string ()
|
|
|
|
"Generate a list of preferred MIME charsets for HTTP requests.
|
|
|
|
Generated according to current coding system priorities."
|
2012-05-10 14:27:12 +08:00
|
|
|
(require 'mm-util)
|
2019-07-09 03:34:15 +02:00
|
|
|
(let ((ordered (sort-coding-systems
|
|
|
|
(let (accum)
|
|
|
|
(dolist (elt mm-mime-mule-charset-alist)
|
|
|
|
(if (coding-system-p (car elt))
|
|
|
|
(push (car elt) accum)))
|
|
|
|
(nreverse accum)))))
|
|
|
|
(concat (format "%s;q=1, " (pop ordered))
|
2022-03-15 10:18:07 -04:00
|
|
|
(mapconcat #'symbol-name ordered ";q=0.5, ")
|
2019-07-09 03:34:15 +02:00
|
|
|
";q=0.5")))
|
2004-04-04 01:21:46 +00:00
|
|
|
|
2010-10-03 14:43:12 +02:00
|
|
|
(defvar url-mime-charset-string nil
|
2012-04-09 21:05:48 +08:00
|
|
|
"String to send in the Accept-charset: field in HTTP requests.
|
2004-04-04 01:21:46 +00:00
|
|
|
The MIME charset corresponding to the most preferred coding system is
|
|
|
|
given priority 1 and the rest are given priority 0.5.")
|
|
|
|
|
|
|
|
(defun url-set-mime-charset-string ()
|
2019-07-09 03:44:06 +02:00
|
|
|
(declare (obsolete nil "27.1"))
|
2004-04-04 01:21:46 +00:00
|
|
|
(setq url-mime-charset-string (url-mime-charset-string)))
|
|
|
|
|
|
|
|
;; Fixme: set from the locale.
|
|
|
|
(defcustom url-mime-language-string nil
|
2010-09-10 18:58:42 -07:00
|
|
|
"String to send in the Accept-language: field in HTTP requests.
|
2004-04-04 01:21:46 +00:00
|
|
|
|
|
|
|
Specifies the preferred language when servers can serve documents in
|
Typo and docstring fixes.
* url.el (url-do-setup):
* url-dired.el (url-dired-minor-mode):
* url-file.el (url-file-find-possibly-compressed-file):
* url-gw.el (url-gateway-broken-resolution):
* url-handlers.el (url-handler-regexp):
* url-imap.el (url-imap-default-port):
* url-methods.el (url-scheme-get-property): Fix typos in docstrings.
* url-auth.el (url-basic-auth-storage, url-digest-auth):
Fix typos in docstrings.
(url-digest-auth-storage, url-register-auth-scheme): Reflow docstrings.
* url-cache.el (url-cache-prepare): Doc fix.
(url-cache-create-filename-human-readable, url-cache-extract):
Fix typos in docstrings.
* url-dav.el (url-intersection, url-dav-iso8601-regexp)
(url-dav-delete-something): Fix typos in docstrings.
(url-dav-http-success-p, url-dav-file-name-all-completions)
(url-dav-directory-files, url-dav-file-name-completion): Doc fixes.
* url-http.el (url-http-idle-sentinel): Doc fix.
* url-irc.el (url-irc-default-port): Fix typo in docstring.
(url-irc-function): Doc fix.
* url-util.el (url-get-url-filename-chars, url-unhex-string):
Fix typos in docstrings.
(url-file-extension): Doc fix.
* url-vars.el (url-current-object, url-current-mime-headers)
(url-privacy-level, url-mail-command, url-mime-language-string):
Fix typos in docstrings.
(url-honor-refresh-requests): Reflow docstring.
(url-using-proxy): Doc fix.
2008-07-02 11:14:38 +00:00
|
|
|
several languages. Use RFC 1766 abbreviations, e.g.: `en' for
|
2004-04-04 01:21:46 +00:00
|
|
|
English, `de' for German. A comma-separated specifies descending
|
|
|
|
order of preference. The ordering can be made explicit using `q'
|
|
|
|
factors defined by HTTP, e.g. `de,en-gb;q=0.8,en;q=0.7'. `*' means
|
|
|
|
get the first available language (as opposed to the default)."
|
|
|
|
:type '(radio
|
|
|
|
(const :tag "None (get default language version)" :value nil)
|
|
|
|
(const :tag "Any (get first available language version)" :value "*")
|
|
|
|
(string :tag "Other"))
|
|
|
|
:group 'url-mime
|
|
|
|
:group 'i18n)
|
|
|
|
|
|
|
|
(defvar url-mime-accept-string nil
|
|
|
|
"String to send to the server in the Accept: field in HTTP requests.")
|
|
|
|
|
|
|
|
(defvar url-package-version nil
|
|
|
|
"Version number of package using URL.")
|
|
|
|
|
2006-01-10 19:14:38 +00:00
|
|
|
(defvar url-package-name nil "Name of package using URL.")
|
2004-04-04 01:21:46 +00:00
|
|
|
|
|
|
|
(defvar url-system-type nil
|
|
|
|
"What type of system we are on.")
|
|
|
|
(defvar url-os-type nil
|
|
|
|
"What OS we are on.")
|
|
|
|
|
|
|
|
(defcustom url-max-password-attempts 5
|
2010-09-10 18:58:42 -07:00
|
|
|
"Maximum number of times a password will be prompted for.
|
2004-04-04 01:21:46 +00:00
|
|
|
Applies when a protected document is denied by the server."
|
Make some defcustom types more restrictive
* lisp/abbrev.el (abbrev-suggest-hint-threshold):
* lisp/bookmark.el (bookmark-bmenu-file-column)
(bookmark-menu-length):
* lisp/buff-menu.el (Buffer-menu-size-width)
(Buffer-menu-mode-width):
* lisp/calendar/calendar.el (calendar-week-start-day)
(calendar-intermonth-spacing, calendar-column-width)
(calendar-day-digit-width):
* lisp/calc/calc.el (calc-undo-length):
* lisp/calendar/timeclock.el (timeclock-workday):
* lisp/comint.el (comint-buffer-maximum-size)
(comint-input-ring-size):
* lisp/doc-view.el (doc-view-resolution, doc-view-image-width):
* lisp/emacs-lisp/bytecomp.el (byte-compile-docstring-max-column):
* lisp/emacs-lisp/comp.el (native-comp-debug)
(native-comp-verbose, native-comp-async-jobs-number):
* lisp/emacs-lisp/package.el (package-name-column-width)
(package-version-column-width, package-status-column-width)
(package-archive-column-width):
* lisp/eshell/esh-mode.el (eshell-buffer-maximum-lines):
* lisp/frame.el (blink-cursor-blinks):
* lisp/info.el (Info-breadcrumbs-depth):
* lisp/jit-lock.el (jit-lock-chunk-size):
* lisp/kmacro.el (kmacro-ring-max):
* lisp/menu-bar.el (yank-menu-length, yank-menu-max-items):
* lisp/midnight.el (clean-buffer-list-delay-general)
(clean-buffer-list-delay-special):
* lisp/net/dictionary.el (dictionary-port)
(dictionary-proxy-port):
* lisp/net/ldap.el (ldap-default-port):
* lisp/net/pop3.el (pop3-port, pop3-stream-length):
* lisp/net/rcirc.el (rcirc-default-port):
* lisp/net/sieve-manage.el (sieve-manage-default-port):
* lisp/play/spook.el (spook-phrase-default-count):
* lisp/play/tetris.el (tetris-buffer-width)
(tetris-buffer-height, tetris-width, tetris-height)
(tetris-top-left-x, tetris-top-left-y):
* lisp/profiler.el (profiler-sampling-interval):
* lisp/progmodes/sql.el (sql-port):
* lisp/recentf.el (recentf-max-menu-items):
* lisp/strokes.el (strokes-grid-resolution):
* lisp/tab-bar.el (tab-bar-tab-name-truncated-max):
* lisp/term/xterm.el (xterm-max-cut-length):
* lisp/time.el (display-time-interval, world-clock-timer-second):
* lisp/url/url-cache.el (url-cache-expire-time):
* lisp/url/url-cookie.el (url-cookie-save-interval):
* lisp/url/url-history.el (url-history-save-interval):
* lisp/url/url-queue.el (url-queue-parallel-processes)
(url-queue-timeout):
* lisp/url/url-vars.el (url-max-password-attempts)
(url-max-redirections):
* lisp/vc/emerge.el (emerge-min-visible-lines):
* lisp/vc/vc.el (vc-log-show-limit):
* lisp/window.el (window-min-height, window-min-width):
* lisp/winner.el (winner-ring-size): Use :type natnum.
* lisp/savehist.el (savehist-file-modes): Fix setting to nil value and
use :type natnum.
2022-07-05 16:26:45 +02:00
|
|
|
:type 'natnum
|
2004-04-04 01:21:46 +00:00
|
|
|
:group 'url)
|
|
|
|
|
|
|
|
(defcustom url-show-status t
|
2010-09-10 18:58:42 -07:00
|
|
|
"Whether to show a running total of bytes transferred.
|
2004-04-04 01:21:46 +00:00
|
|
|
Can cause a large hit if using a remote X display over a slow link, or
|
|
|
|
a terminal with a slow modem."
|
|
|
|
:type 'boolean
|
|
|
|
:group 'url)
|
|
|
|
|
|
|
|
(defvar url-using-proxy nil
|
|
|
|
"Either nil or the fully qualified proxy URL in use, e.g.
|
2019-09-22 23:53:39 -07:00
|
|
|
https://www.example.com/")
|
2004-04-04 01:21:46 +00:00
|
|
|
|
|
|
|
(defcustom url-news-server nil
|
2010-09-10 18:58:42 -07:00
|
|
|
"The default news server from which to get newsgroups/articles.
|
2004-04-04 01:21:46 +00:00
|
|
|
Applies if no server is specified in the URL. Defaults to the
|
|
|
|
environment variable NNTPSERVER or \"news\" if NNTPSERVER is
|
|
|
|
undefined."
|
|
|
|
:type '(choice (const :tag "None" :value nil) string)
|
|
|
|
:group 'url)
|
|
|
|
|
2012-05-09 16:33:48 +08:00
|
|
|
;; From RFC3986: Scheme names consist of a sequence of characters
|
|
|
|
;; beginning with a letter and followed by any combination of letters,
|
|
|
|
;; digits, plus ("+"), period ("."), or hyphen ("-").
|
|
|
|
|
2004-04-04 01:21:46 +00:00
|
|
|
(defvar url-nonrelative-link
|
2012-05-09 16:33:48 +08:00
|
|
|
"\\`\\([a-zA-Z][-a-zA-Z0-9+.]*:\\)"
|
2004-04-04 01:21:46 +00:00
|
|
|
"A regular expression that will match an absolute URL.")
|
|
|
|
|
2007-04-13 14:52:03 +00:00
|
|
|
(defcustom url-max-redirections 30
|
2010-09-10 18:58:42 -07:00
|
|
|
"The maximum number of redirection requests to honor in a HTTP connection.
|
2007-04-13 14:52:03 +00:00
|
|
|
A negative number means to honor an unlimited number of redirection requests."
|
2023-09-01 22:17:48 +02:00
|
|
|
:type 'integer
|
2007-04-13 14:52:03 +00:00
|
|
|
:group 'url)
|
|
|
|
|
2004-04-04 01:21:46 +00:00
|
|
|
(defcustom url-confirmation-func 'y-or-n-p
|
2010-09-10 18:58:42 -07:00
|
|
|
"What function to use for asking yes or no functions.
|
2004-04-04 01:21:46 +00:00
|
|
|
Possible values are `yes-or-no-p' or `y-or-n-p', or any function that
|
|
|
|
takes a single argument (the prompt), and returns t only if a positive
|
|
|
|
answer is given."
|
|
|
|
:type '(choice (const :tag "Short (y or n)" :value y-or-n-p)
|
|
|
|
(const :tag "Long (yes or no)" :value yes-or-no-p)
|
|
|
|
(function :tag "Other"))
|
|
|
|
:group 'url-hairy)
|
|
|
|
|
|
|
|
(defcustom url-gateway-method 'native
|
2010-09-10 18:58:42 -07:00
|
|
|
"The type of gateway support to use.
|
2004-04-04 01:21:46 +00:00
|
|
|
Should be a symbol specifying how to get a connection from the local machine.
|
|
|
|
|
|
|
|
Currently supported methods:
|
|
|
|
`telnet': Run telnet in a subprocess to connect;
|
|
|
|
`socks': Connect through a socks server;
|
2004-10-12 09:55:08 +00:00
|
|
|
`tls': Connect with TLS;
|
|
|
|
`ssl': Connect with SSL (deprecated, use `tls' instead);
|
2011-11-17 01:09:20 -08:00
|
|
|
`native': Connect directly."
|
2004-04-04 01:21:46 +00:00
|
|
|
:type '(radio (const :tag "Telnet to gateway host" :value telnet)
|
|
|
|
(const :tag "Use SOCKS proxy" :value socks)
|
2004-10-12 09:55:08 +00:00
|
|
|
(const :tag "Use SSL/TLS for all connections" :value tls)
|
|
|
|
(const :tag "Use SSL for all connections (obsolete)" :value ssl)
|
2004-04-04 01:21:46 +00:00
|
|
|
(const :tag "Direct connection" :value native))
|
|
|
|
:group 'url-hairy)
|
|
|
|
|
2016-04-24 14:51:33 +02:00
|
|
|
(defcustom url-user-agent 'default
|
|
|
|
"User Agent used by the URL package for HTTP/HTTPS requests.
|
|
|
|
Should be one of:
|
|
|
|
* A string (not including the \"User-Agent:\" prefix)
|
|
|
|
* A function of no arguments, returning a string
|
|
|
|
* `default' (to compute a value according to `url-privacy-level')
|
|
|
|
* nil (to omit the User-Agent header entirely)"
|
|
|
|
:type
|
|
|
|
'(choice
|
|
|
|
(string :tag "A static User-Agent string")
|
|
|
|
(function :tag "Call a function to get the User-Agent string")
|
|
|
|
(const :tag "No User-Agent at all" :value nil)
|
|
|
|
(const :tag "An string auto-generated according to `url-privacy-level'"
|
|
|
|
:value default))
|
2016-11-17 00:39:43 +09:00
|
|
|
:version "26.1"
|
2015-12-26 15:31:32 +02:00
|
|
|
:group 'url)
|
|
|
|
|
2004-04-04 01:21:46 +00:00
|
|
|
(defvar url-setup-done nil "Has setup configuration been done?")
|
|
|
|
|
2004-10-16 15:02:02 +00:00
|
|
|
(defconst url-weekday-alist
|
2004-04-04 01:21:46 +00:00
|
|
|
'(("Sunday" . 0) ("Monday" . 1) ("Tuesday" . 2) ("Wednesday" . 3)
|
|
|
|
("Thursday" . 4) ("Friday" . 5) ("Saturday" . 6)
|
|
|
|
("Tues" . 2) ("Thurs" . 4)
|
|
|
|
("Sun" . 0) ("Mon" . 1) ("Tue" . 2) ("Wed" . 3)
|
|
|
|
("Thu" . 4) ("Fri" . 5) ("Sat" . 6)))
|
|
|
|
|
2004-10-16 15:02:02 +00:00
|
|
|
(defconst url-monthabbrev-alist
|
2004-04-04 01:21:46 +00:00
|
|
|
'(("Jan" . 1) ("Feb" . 2) ("Mar" . 3) ("Apr" . 4) ("May" . 5) ("Jun" . 6)
|
|
|
|
("Jul" . 7) ("Aug" . 8) ("Sep" . 9) ("Oct" . 10) ("Nov" . 11)
|
|
|
|
("Dec" . 12)))
|
|
|
|
|
|
|
|
(defvar url-lazy-message-time 0)
|
|
|
|
|
|
|
|
;; Fixme: We may not be able to run SSL.
|
2022-05-12 13:11:45 +02:00
|
|
|
(defvar url-extensions-header nil)
|
2004-04-04 01:21:46 +00:00
|
|
|
|
|
|
|
(defvar url-parse-syntax-table
|
|
|
|
(copy-syntax-table emacs-lisp-mode-syntax-table)
|
2012-04-09 21:05:48 +08:00
|
|
|
"A syntax table for parsing URLs.")
|
2004-04-04 01:21:46 +00:00
|
|
|
|
|
|
|
(modify-syntax-entry ?' "\"" url-parse-syntax-table)
|
|
|
|
(modify-syntax-entry ?` "\"" url-parse-syntax-table)
|
|
|
|
(modify-syntax-entry ?< "(>" url-parse-syntax-table)
|
|
|
|
(modify-syntax-entry ?> ")<" url-parse-syntax-table)
|
|
|
|
(modify-syntax-entry ?/ " " url-parse-syntax-table)
|
|
|
|
|
2012-06-12 13:47:14 +08:00
|
|
|
(defcustom url-load-hook nil
|
|
|
|
"Hook run after initializing the URL library."
|
|
|
|
:group 'url
|
|
|
|
:type 'hook)
|
2020-01-16 23:06:04 -08:00
|
|
|
(make-obsolete-variable 'url-load-hook
|
|
|
|
"use `with-eval-after-load' instead." "28.1")
|
2004-04-04 01:21:46 +00:00
|
|
|
|
|
|
|
(defconst url-working-buffer " *url-work")
|
|
|
|
|
|
|
|
(defvar url-gateway-unplugged nil
|
2005-06-21 13:36:40 +00:00
|
|
|
"Non-nil means don't open new network connections.
|
2004-04-04 01:21:46 +00:00
|
|
|
This should be set, e.g. by mail user agents rendering HTML to avoid
|
|
|
|
`bugs' which call home.")
|
|
|
|
|
2022-03-06 17:41:18 +01:00
|
|
|
(defun url-interactive-p ()
|
2022-03-15 10:18:07 -04:00
|
|
|
"Non-nil when the current request is from an interactive context."
|
2022-03-06 17:41:18 +01:00
|
|
|
(not (or url-request-noninteractive
|
2022-03-06 19:02:45 +01:00
|
|
|
(bound-and-true-p url-http-noninteractive))))
|
2022-03-06 17:41:18 +01:00
|
|
|
|
2021-03-31 18:17:15 +02:00
|
|
|
;; Obsolete
|
|
|
|
|
|
|
|
(defconst url-version "Emacs" "Version number of URL package.")
|
|
|
|
(make-obsolete-variable 'url-version 'emacs-version "28.1")
|
|
|
|
|
2004-04-04 01:21:46 +00:00
|
|
|
(provide 'url-vars)
|
|
|
|
;;; url-vars.el ends here
|