1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2025-12-11 16:40:45 -08:00
Commit graph

404 commits

Author SHA1 Message Date
Glenn Morris
3c0f86312e Merge from origin/emacs-27
8c27af3ff4 Clarify how transient indentation modes are exited in the ...
fc37dc298f Fix the previous change
2021-02-06 08:05:29 -08:00
Dmitry Gutov
fc37dc298f Fix the previous change
* lisp/progmodes/project.el (project-find-regexp):
Fix the previous change (project-root is not defined in this version).
(project-or-external-find-regexp): Same.
2021-02-05 01:17:09 +02:00
Dmitry Gutov
b99848c72c Bind default-directory to the project root
* lisp/progmodes/project.el (project-find-regexp):
Bind default-directory to the project root, to save this value
in the resulting buffer (esp. if the project selector was used,
(https://lists.gnu.org/archive/html/emacs-devel/2021-02/msg00140.html).
(project-or-external-find-regexp): Same.

(cherry picked from commit c07ebfcbe0)
2021-02-04 22:06:16 +02:00
Dmitry Gutov
c07ebfcbe0 Bind default-directory to the project root
* lisp/progmodes/project.el (project-find-regexp):
Bind default-directory to the project root, to save this value
in the resulting buffer (esp. if the project selector was used,
(https://lists.gnu.org/archive/html/emacs-devel/2021-02/msg00140.html).
(project-or-external-find-regexp): Same.
2021-02-04 03:38:42 +02:00
João Távora
2a71831eb3 Allow project/xref packages to be used in Emacs 26.1
* lisp/progmodes/project.el: Change Package-Requires to Emacs 26.1
(bug#44671).

* lisp/progmodes/xref.el: Ditto.
2021-01-28 04:18:12 +01:00
Juri Linkov
5065698c81 Move the ‘declare’ form before the interactive spec in 10 functions.
* lisp/emacs-lisp/package.el (package-menu-hide-package):
* lisp/font-lock.el (font-lock-debug-fontify):
* lisp/image.el (image-jpeg-p):
* lisp/mail/flow-fill.el (fill-flowed-test):
* lisp/mh-e/mh-speed.el (mh-speed-toggle, mh-speed-view):
* lisp/progmodes/project.el (project-async-shell-command)
(project-shell-command, project-compile):
* lisp/progmodes/sh-script.el (sh-assignment):
Fix special forms to follow in this order: docstring, declare, interactive.
2021-01-20 21:19:23 +02:00
Dmitry Gutov
8725f7690a Declare some project commands interactive-only
* lisp/progmodes/project.el (project-async-shell-command)
(project-shell-command, project-compile):
Declare interactive-only (bug#45765).
2021-01-19 21:50:11 +02:00
Kévin Le Gouguec
1513ee37a4 Change default-directory before prompting in project-compile
This causes command completion to work from the project root, letting
users complete top-level folders, make targets, etc (bug#45765).

* lisp/progmodes/project.el (project-compile): Simplify using
call-interactively, as done with project(-async)-shell-command.
2021-01-16 06:00:22 +02:00
Dmitry Gutov
665b4e7c4e Proof some searches and file listings against symlinks
* lisp/progmodes/project.el (project--files-in-directory):
Make sure the directory includes the trailing slash in case it's
a symlink, discussed in
https://lists.gnu.org/archive/html/emacs-devel/2021-01/msg00345.html.

* lisp/progmodes/xref.el (xref-matches-in-directory): Same.

* lisp/cedet/semantic/symref/grep.el (semantic-symref-perform-search):
Same.
2021-01-06 23:07:22 +02:00
Paul Eggert
ba05d005e5 Update copyright year to 2021
Run "TZ=UTC0 admin/update-copyright".
2021-01-01 01:13:56 -08:00
Paul Eggert
8c1fe1e5ef Update copyright year to 2021
Run "TZ=UTC0 admin/update-copyright $(git ls-files)".
2021-01-01 00:32:32 -08:00
Dmitry Gutov
32e781b2f1 Jamie Beardslee <beardsleejamie@gmail.com>
* lisp/progmodes/project.el (project-execute-extended-command):
New command.
(project-prefix-map): Binding for it.

Copyright-paperwork-exempt: yes
2020-12-20 00:16:48 +02:00
Mattias Engdegård
6858119bcd ; * lisp/progmodes/project.el (project-switch-use-entire-map): Typo 2020-12-14 12:33:05 +01:00
Dmitry Gutov
51698f77dd Remove the duplication from project-switch-commands's config
Based on an older patch by Philip K (https://debbugs.gnu.org/41890#127).

* lisp/progmodes/project.el: (project-switch-commands): Change to
'defcustom', alter the value format, add :type.
(project-switch-use-entire-map): New option.
(project--keymap-prompt, project-switch-project):
Update accordingly, while keeping compatibility with user-defined
values in the previous format (for some transition period).

Co-authored-by: Philip K. <philipk@posteo.net>
2020-12-13 22:50:55 +02:00
Dmitry Gutov
2d790c6c57 Bump project.el version
* lisp/progmodes/project.el: Bump the version.
2020-12-13 04:12:35 +02:00
Dmitry Gutov
5af6a87d51 Allow specifying the project to switch to programmatically
* lisp/progmodes/project.el (project-switch-project):
Allow specifying the project to switch to programmatically
(bug#45134).
2020-12-09 22:56:48 +02:00
Dmitry Gutov
5f45fc7ee2 Improve .gitignore and project-vc-ignores handling
* lisp/progmodes/project.el (project-ignores):
Convert .gitignore entries more faithfully.
(project--vc-list-files): Convert "our" ignore entries to
"proper" globs, which is what Git pathspec requires.
2020-12-02 04:28:35 +02:00
Dmitry Gutov
e19c5d4348 Use project--value-in-dir
* lisp/progmodes/project.el (project-files):
Use 'project--value-in-dir'.  To have any changes in
'project-vc-ignores' take effect immediately.
2020-12-02 01:41:40 +02:00
Dmitry Gutov
fa2c942176 Improve docstrings
* lisp/progmodes/project.el (project-find-file)
(project-or-external-find-file): More accurate docstrings (bug#44588).
2020-11-30 03:33:14 +02:00
Lars Ingebrigtsen
b5ff3e0e0c project-or-external-find-file doc string fix
* lisp/progmodes/project.el (project-or-external-find-file): Doc
string fix -- it's not "recognizing" file names (bug#44588).
2020-11-14 16:24:38 +01:00
Lars Ingebrigtsen
b21015c9c2 Clarify project-find-file doc string
* lisp/progmodes/project.el (project-find-file): Don't say
anything about recognizing file names, as that may lead the user
to think that it'll check whether the string at point is an
existing file (bug#44588).
2020-11-12 13:36:19 +01:00
Juri Linkov
74de386a8a * lisp/progmodes/project.el: Don't truncate the saved project list.
* lisp/progmodes/project.el (project--write-project-list):
Let-bind print-length and print-level to nil to not truncate the
saved project list with unreadable ellipsis.
2020-11-08 21:45:02 +02:00
Manuel Uberti
43431f7108 * lisp/progmodes/project.el (project--files-in-directory): Fix formatting
Copyright-paperwork-exempt: yes
2020-11-04 10:42:20 -05:00
Lars Ingebrigtsen
8fb761af6b Fix undefined function in project-compile
* lisp/progmodes/project.el (project-compile): Require compile.el
before using functions from the file (bug#44009).
2020-10-15 13:20:22 +02:00
Dmitry Gutov
0a5e9cf262 Mention two more functions in the commentary
* lisp/progmodes/project.el:
Mention two more functions in the commentary (bug#43595).
2020-10-08 02:41:12 +03:00
Stefan Kangas
462dbc1cb2 ; Fix typos 2020-09-21 14:26:42 +02:00
Stefan Kangas
3b79ff6179 Fix typo in project-kill-buffers
* lisp/progmodes/project.el (project-kill-buffers): Fix typo.
Reported by Manuel Uberti <manuel.uberti@inventati.org>
2020-09-18 20:32:15 +02:00
Dmitry Gutov
1283d3a5b2 Fix typo, reported by Manuel Uberti
* lisp/progmodes/project.el (project-kill-buffer-conditions):
Fix typo.
2020-09-18 12:15:46 +03:00
João Távora
5142149758 Unbreak project.el, the GNU Elpa package, for Emacs 26.3
Fixes: bug#43164

* lisp/progmodes/project.el: Bump to 0.5.2
(bound-and-true-p): Check that tab-prefix-map is bound before binding.
2020-09-03 13:42:55 +01:00
Stefan Kangas
8d3160ec08 Add commands to run shell commands in project root
* lisp/progmodes/project.el (project-async-shell-command)
(project-shell-command): New commands to run 'async-shell-command'
and 'shell-command' in project's root directory.
(project-prefix-map): Bind commands to '!' and '&'.
* doc/emacs/maintaining.texi (Project File Commands): Document the
new commands.
* etc/NEWS: Announce the new commands.
2020-08-28 19:27:47 +02:00
Dmitry Gutov
319463920c Unbreak project-find-regexp in Emacs 26.3 (bug#42765)
* lisp/progmodes/project.el: Depend on xref.  Bump the version.

* lisp/progmodes/xref.el: Remove 'project' from the list of
dependencies.  Depending on Emacs 26.3 already ensures that some
version is available.  Bump the version.
(xref--process-file-region): Move from project.el with a rename.
Update the sole caller.
(xref-backend-references): Make compatible with old project.el.
Update the docstring.
2020-08-14 17:21:55 +03:00
Philip K
cc365ca6d8 Remove usages of assoc-delete-all in project.el
assoc-delete-all is not available for users who have installed
project.el via ELPA on older Emacs versions (bug#42668).

* lisp/progmodes/project.el
(project-remember-project, project--remove-from-project-list):
Replace assoc-delete-all with equivalent alternatives.
2020-08-06 17:49:53 +03:00
Philip K
2ab66c9f9b Replace project-kill-buffers-ignores with project-kill-buffer-conditions
* lisp/progmodes/project.el (project-kill-buffer-conditions):
Replace the project-kill-buffers-ignores user option.
(project--kill-buffer-check): New function.
(project--buffers-to-kill): New function.
(project-kill-buffers): Use them.  Add the NO-CONFIRM argument.
2020-07-29 01:21:56 +03:00
Dmitry Gutov
4d195bb7d0 Fix argument reference
* lisp/progmodes/project.el
(project-display-buffer-other-frame): Fix argument reference.
2020-07-27 03:05:16 +03:00
Dmitry Gutov
33667e02e6 Move project--value-in-dir to a different section
* lisp/progmodes/project.el (project--value-in-dir):
Move closer to its uses.
2020-07-27 03:04:09 +03:00
Dmitry Gutov
7551aff22c Bind switch-to-buffer-obey-display-actions to t
* lisp/progmodes/project.el (project--other-place-command):
Bind switch-to-buffer-obey-display-actions to t, so that
project-other-window-command and friends can affect
project-switch-to-buffer.
2020-07-27 02:57:06 +03:00
Sean Whitton
b63c5a7efc Add project other place commands
* lisp/progmodes/project.el (project-other-window-map,
project-other-frame-map, project--other-place-command,
project-other-window-command, project-other-frame-command,
project-other-tab-command): Add these functions and maps.
* lisp/progmodes/project.el: Bind project-other-window-command to C-x
4 p, project-other-frame-command to C-x 5 p and
project-other-tab-command to C-x t p (bug#42210).
2020-07-27 02:56:50 +03:00
Sean Whitton
e3614fcc62 Add project-display-buffer and project-display-buffer-other-frame
* lisp/progmodes/project.el (project-display-buffer,
project-display-buffer-other-frame): Add commands.
2020-07-27 02:52:10 +03:00
Sean Whitton
7479c11b4e Factor out project--read-project-buffer from project-switch-buffer
* lisp/progmodes/project.el (project--read-project-buffer): New
function extracted from project-switch-buffer.
* lisp/progmodes/project.el (project-switch-buffer): Instead of
unconditionally reading a project buffer from the user, add
buffer-or-name argument, and populate it using
project--read-project-buffer when called interactively.  Update
docstring.
2020-07-27 02:52:10 +03:00
Dmitry Gutov
19064761ad project-remember-project: New public function
* lisp/progmodes/project.el (project-remember-project):
Rename from project--add-to-project-list-front (bug#42332).
And autoload it.
2020-07-25 03:17:47 +03:00
Dmitry Gutov
4c08c2f45b ; project.el: Talk about equality 2020-07-20 04:07:11 +03:00
Dmitry Gutov
7259377d70 project.el: Add more docs and two new key bindings
* lisp/progmodes/project.el:
Add a longer description of the package and how to use it.
(project-prefix-map): Add entries for
'project-or-external-find-file' and
'project-or-external-find-regexp'.
2020-07-20 03:58:08 +03:00
Philipp Stephani
f700fc1482 Add missing 'require'.
* lisp/progmodes/project.el: Require seq.el explicitly as
'seq-every-p' isn't autoloaded in Emacs 26.3.
2020-07-19 10:32:51 +02:00
Eli Zaretskii
0339325d53 ;* lisp/progmodes/project.el (project-current): Doc fix. 2020-07-12 21:48:39 +03:00
Dmitry Gutov
96173fbfab ; Roll back certain doc changes; clarify what "transient" is 2020-07-12 20:55:23 +03:00
Eli Zaretskii
f5bc508be5 Fix last doc changes in project.el
* lisp/progmodes/project.el (project-find-functions)
(project-current): Add back information which was recently
removed.
2020-07-12 16:57:40 +03:00
Dmitry Gutov
4a467f7591 project-kill-buffers: Update the docstring too
* lisp/progmodes/project.el (project-kill-buffers):
Copy a sentence over from project-switch-to-buffer.
2020-07-12 03:46:37 +03:00
Dmitry Gutov
ebcbd50c53 More docstring updates in project.el
* lisp/progmodes/project.el (project-find-functions)
(project-current, project-switch-to-buffer):
More docstring updates.
2020-07-12 03:39:16 +03:00
Eli Zaretskii
d8e17a4c4e Another minor improvement of project.el doc strings
* lisp/progmodes/project.el (project-find-functions)
(project-current, project-switch-to-buffer): Doc fix.
(project-current): Rename the argument DIR to DIRECTORY.
2020-07-11 15:33:51 +03:00
Dmitry Gutov
86c860f1a1 project-switch-to-buffer: Reword the docstring
* lisp/progmodes/project.el (project-switch-to-buffer):
Reword the docstring, copying the style from project-kill-buffers.
2020-07-11 04:39:58 +03:00