diff options
| author | Eli Zaretskii | 2020-03-21 13:26:19 +0200 |
|---|---|---|
| committer | Eli Zaretskii | 2020-03-21 13:26:19 +0200 |
| commit | 561e9fb91bba98616f6d7ea3818727c1cdd2d853 (patch) | |
| tree | 63423d044102e79f59135c9354cb05fbe41576a1 /lisp | |
| parent | b28a9a6cc3451ea865449cf010466cd3ac8bf9a0 (diff) | |
| download | emacs-561e9fb91bba98616f6d7ea3818727c1cdd2d853.tar.gz emacs-561e9fb91bba98616f6d7ea3818727c1cdd2d853.zip | |
Improve documentation of project.el commands
* lisp/progmodes/project.el (project-find-regexp): Require 'grep'
to be able to call 'grep-read-files'.
(project-search, project-query-replace-regexp): Doc fixes.
* doc/emacs/maintaining.texi (Projects): New section.
* doc/emacs/emacs.texi (Top): Add "Projects" to the detailed menu.
Diffstat (limited to 'lisp')
| -rw-r--r-- | lisp/progmodes/project.el | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/lisp/progmodes/project.el b/lisp/progmodes/project.el index ccd8cc049d4..f4678681858 100644 --- a/lisp/progmodes/project.el +++ b/lisp/progmodes/project.el | |||
| @@ -437,6 +437,7 @@ triggers completion when entering a pattern, including it | |||
| 437 | requires quoting, e.g. `\\[quoted-insert]<space>'." | 437 | requires quoting, e.g. `\\[quoted-insert]<space>'." |
| 438 | (interactive (list (project--read-regexp))) | 438 | (interactive (list (project--read-regexp))) |
| 439 | (require 'xref) | 439 | (require 'xref) |
| 440 | (require 'grep) | ||
| 440 | (let* ((pr (project-current t)) | 441 | (let* ((pr (project-current t)) |
| 441 | (files | 442 | (files |
| 442 | (if (not current-prefix-arg) | 443 | (if (not current-prefix-arg) |
| @@ -606,7 +607,8 @@ PREDICATE, HIST, and DEFAULT have the same meaning as in | |||
| 606 | (defun project-search (regexp) | 607 | (defun project-search (regexp) |
| 607 | "Search for REGEXP in all the files of the project. | 608 | "Search for REGEXP in all the files of the project. |
| 608 | Stops when a match is found. | 609 | Stops when a match is found. |
| 609 | To continue searching for next match, use command \\[fileloop-continue]." | 610 | To continue searching for the next match, use the |
| 611 | command \\[fileloop-continue]." | ||
| 610 | (interactive "sSearch (regexp): ") | 612 | (interactive "sSearch (regexp): ") |
| 611 | (fileloop-initialize-search | 613 | (fileloop-initialize-search |
| 612 | regexp (project-files (project-current t)) 'default) | 614 | regexp (project-files (project-current t)) 'default) |
| @@ -614,9 +616,10 @@ To continue searching for next match, use command \\[fileloop-continue]." | |||
| 614 | 616 | ||
| 615 | ;;;###autoload | 617 | ;;;###autoload |
| 616 | (defun project-query-replace-regexp (from to) | 618 | (defun project-query-replace-regexp (from to) |
| 617 | "Search for REGEXP in all the files of the project. | 619 | "Query-replace REGEXP in all the files of the project. |
| 618 | Stops when a match is found. | 620 | Stops when a match is found and prompts for whether to replace it. |
| 619 | To continue searching for next match, use command \\[fileloop-continue]." | 621 | If you exit the query-replace, you can later continue the query-replace |
| 622 | loop using the command \\[fileloop-continue]." | ||
| 620 | (interactive | 623 | (interactive |
| 621 | (pcase-let ((`(,from ,to) | 624 | (pcase-let ((`(,from ,to) |
| 622 | (query-replace-read-args "Query replace (regexp)" t t))) | 625 | (query-replace-read-args "Query replace (regexp)" t t))) |