Join GitHub today
GitHub is home to over 40 million developers working together to host and review code, manage projects, and build software together.
Sign upbpo-39144 Align ctags and etags behaviours and include Python stdlib files #17721
Conversation
- make TAGS to reset tags file - make TAGS to include Modules/_ctypes
@@ -1730,13 +1730,17 @@ tags:: | |||
ctags -w $(srcdir)/Include/*.h $(srcdir)/Include/cpython/*.h $(srcdir)/Include/internal/*.h | |||
for i in $(SRCDIRS); do ctags -f tags -w -a $(srcdir)/$$i/*.[ch]; done | |||
ctags -f tags -w -a $(srcdir)/Modules/_ctypes/*.[ch] | |||
find $(srcdir)/Lib -type f -name "*.py" -not -name "test_*.py" -not -path "*/test/*" | ctags -f tags -w -a -L - |
This comment has been minimized.
This comment has been minimized.
pablogsal
Dec 27, 2019
Member
This still will pick up some stuff that is not likely wanted, for example, the contents of Lib/lib2to3/tests
. Also, some packages have the test folder inside like Lib/unittest/test/
.
This comment has been minimized.
This comment has been minimized.
LC_ALL=C sort -o tags tags | ||
|
||
# Create a tags file for GNU Emacs | ||
TAGS:: | ||
touch tags |
This comment has been minimized.
This comment has been minimized.
pablogsal
Dec 27, 2019
Member
Why do you need this line? If I invoke the makefile from another place won't this create a 'tags' file in my current working directory?
This comment has been minimized.
This comment has been minimized.
tonybaloney
Dec 27, 2019
Author
Contributor
etags -a
appends to the current tags, (regardless of whats in it), if you run make tags
and make TAGS
you'll end up with a corrupted file.
the make tags
commands will find the first pass without the -a
append, so it resets the file. I'll update this to run in a different order
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
@pablogsal please re-review |
This comment has been minimized.
This comment has been minimized.
For reference, these are the files that will be indexed by
|
This looks good to me, thanks @tonybaloney for the PR! |
ef7eaaf
into
python:master
This comment has been minimized.
This comment has been minimized.
miss-islington
commented
Dec 28, 2019
Thanks @tonybaloney for the PR, and @pablogsal for merging it |
This comment has been minimized.
This comment has been minimized.
bedevere-bot
commented
Dec 28, 2019
GH-17722 is a backport of this pull request to the 3.8 branch. |
This comment has been minimized.
This comment has been minimized.
bedevere-bot
commented
Dec 28, 2019
GH-17723 is a backport of this pull request to the 3.7 branch. |
…e Python stdlib files (pythonGH-17721) (cherry picked from commit ef7eaaf) Co-authored-by: Anthony Shaw <anthony.p.shaw@gmail.com>
tonybaloney commentedDec 27, 2019
•
edited
make tags
andmake TAGS
to both include Python standard library filesmake TAGS
to reset tags file, asmake tags
does (implicitly)make TAGS
to include Modules/_ctypes asmake tags
doeshttps://bugs.python.org/issue39144