Commit graph

9018 commits

Author SHA1 Message Date
Philip Kaludercic
c8e5069e6d Add new command 'package-vc-update-all'
* lisp/emacs-lisp/package-vc.el (package-vc-update-all): Add command
(package-vc-update): Add an assertion to verify this.
2022-11-17 20:55:04 +01:00
Philip Kaludercic
aa56e50fe2 Raise 'wrong-type-argument' when installing package nil
* lisp/emacs-lisp/package-vc.el (package-vc-install): Check if the
package is nil.
2022-11-17 20:37:28 +01:00
Philip Kaludercic
496c578d9c Have 'package-vc-selected-packages' consider all installed packages
* lisp/emacs-lisp/package-vc.el
(package-vc-install-selected-packages): Consider more than just one
value in `package-alist', in case there are multiple installations.
2022-11-17 20:37:28 +01:00
Philip Kaludercic
2ed115fc3c Fix indefinite loading of asynchronous downloads
* lisp/emacs-lisp/package.el (package--download-one-archive): Only add
the archive that is actually being downloaded to
'package--downloads-in-progress'.
2022-11-17 20:37:28 +01:00
Philip Kaludercic
ccd7ab84c5 Fix edebug spec for 'package--with-response-buffer'
* lisp/emacs-lisp/package.el (package--with-response-buffer): Add a
spec that makes the macro debuggable.
2022-11-17 20:37:28 +01:00
Philip Kaludercic
7c3d3fa44e Improve robustness of documentation generation
* lisp/emacs-lisp/package-vc.el (package-vc--build-documentation): Log
output and display error messages if anything goes wrong.
2022-11-17 20:37:28 +01:00
Philip Kaludercic
a6cd44734d Remove unused variable in 'package-vc--unpack'
* lisp/emacs-lisp/package-vc.el (package-vc--unpack): Remove 'url'.
2022-11-17 20:37:28 +01:00
Philip Kaludercic
348f7d263c Move package spec documentation to 'package-vc-selected-packages'
* lisp/emacs-lisp/package-vc.el (package-vc-selected-packages): Add
documentation.
(package-vc--archive-spec-alist): Remove documentation.
2022-11-17 20:37:28 +01:00
Philip Kaludercic
2b93d0e6f1 Fix type error in package-vc prompt function
* lisp/emacs-lisp/package-vc.el (package-vc--read-package-name):  Pass
(not allow-url) as REQUIRE-MATCH, not as INITIAL-INPUT.
2022-11-17 20:37:28 +01:00
Philip Kaludercic
c53c5f3884 Rename 'package-vc-refresh' to 'package-vc-rebuild'
* doc/emacs/package.texi (Fetching Package Sources): Update documentation.
* lisp/emacs-lisp/package-vc.el (package-vc-refresh): Rename from.
(package-vc-rebuild): Rename to.

This intends to clarify the intention and avoid confusion with
'package-refresh-contents'.  Thanks to Rudolf Adamkovič for the
suggestion.
2022-11-17 20:37:28 +01:00
Philip Kaludercic
2ec02024ab Track 'default-directory' while updating source packages
* lisp/emacs-lisp/package-vc.el (package-vc-update): Add the source
directory to the identifier list, in case the remaining
'vc-do-command' arguments are all read-time constants.
2022-11-17 20:37:28 +01:00
Philip Kaludercic
d67b66f8ab Respect :lisp-dir in package specs by loading a sub-directory
* lisp/emacs-lisp/package-vc.el (package-vc-repository-store): Remove
obsolete variable.
(package-vc--unpack-1): Respect :lisp-dir.
(package-vc--unpack): Add :lisp-dir to the package description if
necessary.
* lisp/emacs-lisp/package.el (package--delete-directory): Check if a
directory is a symbolic link.
2022-11-17 20:37:28 +01:00
Philip Kaludercic
9f4a433b27 Fix generation of documentation for source packages
* lisp/emacs-lisp/package-vc.el (package-vc--build-documentation):
Call "makeinfo" before "install-info"
2022-11-17 20:37:28 +01:00
Philip Kaludercic
13d051b443 Remove references to internal symbols from public docstrings
* lisp/emacs-lisp/package-vc.el (package-vc-repository-store):
Unmention 'package-vc--unpack'.
(package-vc-install): Unmention 'package-vc--guess-backend' in favour
of 'package-vc-heuristic-alist'.
2022-11-17 20:37:28 +01:00
Philip Kaludercic
b0200a37e4 Expand 'package-vc--unpack-1' documentation
* lisp/emacs-lisp/package-vc.el (package-vc--unpack-1): Explain what
the function does.
2022-11-17 20:37:28 +01:00
Philip Kaludercic
f939859fe4 Clarify 'package-vc--build-documentation' docstring
* lisp/emacs-lisp/package-vc.el (package-vc--build-documentation):
Rewrite the first line.

As suggested by Eli Zaretskii.
2022-11-17 20:37:28 +01:00
Philip Kaludercic
32758c6da0 Fix the docstring for 'package-vc--version'
* lisp/emacs-lisp/package-vc.el (package-vc--version): Replace
docstring.

It seems like this was just copied over from 'package-vc-commit', for
no good reason.
2022-11-17 20:37:28 +01:00
Philip Kaludercic
83ff0de4ce Fix 'package-vc-selected-packages' documentation
* lisp/emacs-lisp/package-vc.el (package-vc-selected-packages): Remove
reference to non-existent function and add an explanation that the
value won't override an existing source package installation.
2022-11-17 20:37:28 +01:00
Philip Kaludercic
3ff8310cc3 Mark 'package-vc-update' as interactive
* lisp/emacs-lisp/package-vc.el (package-vc--sourced-packages-list):
Remove function in favour of 'package-vc--read-package-name'.
(package-vc--read-package-name):
Extract out common functionality.
(package-vc--read-package-desc): Add auxiliary function based on
'package-vc--read-package-name'.
(package-vc-update): Add interactive spec using
'package-vc--read-package-desc'.
(package-vc-install): Use 'package-vc--read-package-desc'.
(package-vc-checkout): Use 'package-vc--read-package-desc'.
(package-vc--read-pkg): Remove in favour of 'package-vc--read-package-desc'.
(package-vc-refresh): Use 'package-vc--read-package-desc'.
(package-vc-prepare-patch): Use 'package-vc--read-package-desc'.
2022-11-17 20:37:28 +01:00
Philip Kaludercic
aadf07f5b8 Autoload 'package-vc-install-selected-packages'
* lisp/emacs-lisp/package-vc.el (package-vc-ensure-packages): Add an
autoload cookie.
(package-vc-selected-packages): Set
:initialize to 'custom-initialize-default'.
2022-11-17 20:37:28 +01:00
Philip Kaludercic
e1ce202ad1 Mark 'package-vc-install-selected-packages' as interactive
* lisp/emacs-lisp/package-vc.el (package-vc-ensure-packages): Add an
interactive spec.
2022-11-17 20:37:28 +01:00
Philip Kaludercic
9d3c6205ae Rename '-ensure-packages' to -install-selected-packages'
* doc/emacs/package.texi (Fetching Package Sources): Rename instances.
* lisp/emacs-lisp/package-vc.el (package-vc-ensure-packages): Rename
to 'package-vc-install-selected-packages'.
(package-vc-selected-packages): Call renamed function.
2022-11-17 20:37:28 +01:00
Philip Kaludercic
a4e4ceb47a Handle strings as keys in 'package-vc-ensure-packages'
* lisp/emacs-lisp/package-vc.el (package-vc-ensure-packages): Inter
sting keys while processing 'package-vc-selected-packages'.

As requested by Rudolf Adamkovič.
2022-11-17 20:37:28 +01:00
Philip Kaludercic
e55be31d55 ; Fix interactive spec for 'package-vc-refresh'
* lisp/emacs-lisp/package-vc.el (package-vc-refresh):

Thanks to Rudolf Adamkovič for noticing the mistake.
2022-11-17 20:37:28 +01:00
Juanma Barranquero
61b9f2c317 * lisp/emacs-lisp/shortdoc.el (sequence): Don't use cl-lib (bug#59319) 2022-11-17 09:55:45 +01:00
Stefan Kangas
93036209fa ; Fix typos (duplicate words) 2022-11-17 09:34:24 +01:00
Eli Zaretskii
43cca14a9e ; * lisp/emacs-lisp/seq.el (seq-filter): Fix typo in doc string. 2022-11-17 08:48:14 +02:00
Eli Zaretskii
3b137bcbe8 ; Improve doc strings in seq.el
* lisp/emacs-lisp/seq.el (seq-doseq, seq-setq, seq-elt)
(seq-length, seq-rest, seq-do, seq-mapn, seq-drop, seq-take)
(seq-drop-while, seq-take-while, seq-sort, seq-sort-by)
(seq-concatenate, seq-into, seq-filter, seq-remove)
(seq-remove-at-position, seq-every-p, seq-some, seq-find)
(seq-count, seq-contains, seq-contains-p, seq-set-equal-p)
(seq-position, seq-positions, seq-uniq, seq-mapcat)
(seq-partition, seq-union, seq-intersection, seq-difference)
(seq--count-successive, seq--elt-safe, seq-random-elt)
(seq-split, seq-keep): Doc fixes.
2022-11-15 19:36:49 +02:00
Stefan Kangas
6f48b46b03 ; Fix typos 2022-11-11 15:52:37 +01:00
Gerd Möllmann
6d9065b748 Fix &key parameters called without arguments (bug#58714)
* lisp/emacs-lisp/cl-macs.el (cl--do-arglist): Check for missing
argument.
* test/lisp/emacs-lisp/cl-macs-tests.el (cl-&key-arguments): New test.
2022-11-11 14:13:46 +01:00
Yuan Fu
4489450f37
In end-of-defun, terminate early if no further defun exists
Before this change, end-of-defun calls end-of-defun-function even if
point is not necessarily at the beginning of a defun (contrary to what
end-of-defun-function's docstring claims).  Now it terminates early
and doesn't call end-of-defun-function.

* lisp/emacs-lisp/lisp.el (beginning-of-defun-raw): Update docstring
clarifying the return value.
(end-of-defun): Terminate early if beginning-of-defun-raw returns nil.
2022-11-10 15:00:29 -08:00
Nicholas Vollmer
a01024c859 bytecomp.el (byte-recompile-directory): Fix negated ignore logic
Previous logic would only compile files which matched the
byte-compile-ignore-files regular expression.  (Bug#59115)
2022-11-09 09:50:38 +01:00
Mattias Engdegård
e46f680489 ; * lisp/emacs-lisp/package.el (package-load-all-descriptors): Use \` 2022-11-06 16:01:13 +01:00
Philip Kaludercic
270020a4b4 Rephrase 'package-vc-ensure-packages' docstring
* lisp/emacs-lisp/package-vc.el (package-vc-ensure-packages): Make it
easier to read.
2022-11-05 17:44:57 +01:00
Philip Kaludercic
1557bb9d8f ; Rename 'package-vc-link-directory' to '-install-from-checkout'
* doc/emacs/package.texi (Fetching Package Sources): Rename instances
* etc/NEWS: Rename instances.
* lisp/emacs-lisp/package-vc.el (package-vc-link-directory): Rename to
'package-vc-install-from-checkout'.
2022-11-05 17:44:54 +01:00
Eli Zaretskii
22fb5397de ; Fix documentation of package-vc.el
* lisp/emacs-lisp/package-vc.el (package-vc-default-backend)
(package-vc-selected-packages, package-vc--archive-spec-alist)
(package-vc--archive-data-alist, package-vc--query-spec)
(package-vc--read-archive-data, package-vc-commit)
(package-vc--main-file, package-vc--generate-description-file)
(package-vc--build-documentation, package-vc--unpack-1)
(package-vc--guess-backend, package-vc--clone)
(package-vc--unpack, package-vc-update, package-vc--release-rev)
(package-vc-install, package-vc-checkout)
(package-vc-link-directory, package-vc-refresh)
(package-vc-prepare-patch, package-vc--archives-initialize): Doc fixes.
2022-11-05 13:11:28 +02:00
Stefan Kangas
5f0af7caec ; package-vc: Pacify byte-compiler
* lisp/emacs-lisp/package-vc.el (package-vc-selected-packages):
Declare.
2022-11-04 20:16:04 +01:00
Philip Kaludercic
5fa2f11679 Merge branch 'feature/package+vc' 2022-11-04 18:57:45 +01:00
Philip Kaludercic
f762c5bb2c * lisp/emacs-lisp/package-vc.el: Expand commentary 2022-11-04 18:54:17 +01:00
Philip Kaludercic
184f0c3e60 ; * lisp/emacs-lisp/package-vc.el (package-vc): Add missing :prefix 2022-11-04 18:19:01 +01:00
Philip Kaludercic
f17fadd01a Link to Manual from the package-vc group
* lisp/emacs-lisp/package-vc.el (package-vc): Add 'custom-manual'
link.
2022-11-04 18:17:45 +01:00
Philip Kaludercic
b5850ba3ae Document 'package-vc-selected-packages'
* doc/emacs/package.texi: Expand documentation and give example.
* etc/NEWS: Mention 'package-vc-selected-packages'.
* lisp/emacs-lisp/package-vc.el (package-vc--select-packages): Remove
function.
(package-vc-ensure-packages): Add function based on
'package-vc--select-packages'.
(package-vc-selected-packages): Call 'package-vc-ensure-packages' from
custom setter.
2022-11-04 18:05:41 +01:00
Juanma Barranquero
4fa8f57cc6 ; * lisp/emacs-lisp/oclosure.el: Fix typos. 2022-11-04 08:41:43 +01:00
Philip Kaludercic
0efc611697 Autoload all entry functions 2022-11-03 23:15:18 +01:00
Philip Kaludercic
38efed50dc ; Mention that 'package-vc-checkout' open a directory
* lisp/emacs-lisp/package-vc.el (package-vc-checkout): Mention it in
the docstring.
2022-11-03 19:41:46 +01:00
Philip Kaludercic
f5fb7069f3 ; Explicitly mark internal functions as such 2022-11-03 19:38:34 +01:00
Philip Kaludercic
0e75099da8 * lisp/emacs-lisp/package-vc.el (package-vc-version): Use main file 2022-11-03 19:28:47 +01:00
Philip Kaludercic
ec01d9a209 Add command 'package-vc-checkout'
* doc/emacs/package.texi: Document feature.
* etc/NEWS: Mention feature.
* lisp/emacs-lisp/package-vc.el (package-vc-clone): Extract
functionality out of 'package-vc-unpack'.
(package-vc-unpack): Extract functionality out to 'package-vc-clone'.
(package-vc-checkout): Add command.
2022-11-03 19:26:21 +01:00
Eli Zaretskii
dffc34a2d4 Fix 'text-property-search-backward' with 1-char long properties
* lisp/emacs-lisp/text-property-search.el
(text-property--find-end-backward): Don't miss the end of
text-property value at point.  This fixes searches backward when
the property is on a single character position.  (Bug#58937)
2022-11-03 11:25:50 +02:00
Philip Kaludercic
7705b66ed3 ; Update TODO section 2022-11-02 17:16:39 +01:00