From 66c1e2c7669021844079a3c4dd3da2e5de17e2fe Mon Sep 17 00:00:00 2001 From: Gilles Peskine Date: Tue, 16 Jan 2018 14:04:05 +0100 Subject: [PATCH] Generate tags for Vi, for Emacs and with Global --- .gitignore | 8 ++++++++ .globalrc | 3 +++ Makefile | 9 +++++++++ 3 files changed, 20 insertions(+) create mode 100644 .globalrc diff --git a/.gitignore b/.gitignore index f40064d5bf..a662dedcdd 100644 --- a/.gitignore +++ b/.gitignore @@ -26,3 +26,11 @@ massif-* # CMake generates *.dir/ folders for in-tree builds (used by MSVC projects), ignore all of those: *.dir/ + +# Editor navigation files: +/GPATH +/GRTAGS +/GSYMS +/GTAGS +/TAGS +/tags diff --git a/.globalrc b/.globalrc new file mode 100644 index 0000000000..01b2ea5a31 --- /dev/null +++ b/.globalrc @@ -0,0 +1,3 @@ +default:\ + :langmap=c\:.c.h.function:\ + diff --git a/Makefile b/Makefile index 87b5a0c0f1..d1817b2088 100644 --- a/Makefile +++ b/Makefile @@ -132,3 +132,12 @@ apidoc: apidoc_clean: rm -rf apidoc endif + +## Editor navigation files +C_SOURCE_FILES = $(wildcard include/*/*.h library/*.[hc] programs/*/*.[hc] tests/suites/*.function) +tags: $(C_SOURCE_FILES) + ctags -o $@ $(C_SOURCE_FILES) +TAGS: $(C_SOURCE_FILES) + etags -o $@ $(C_SOURCE_FILES) +GPATH GRTAGS GSYMS GTAGS: $(C_SOURCE_FILES) + ls $(C_SOURCE_FILES) | gtags -f - --gtagsconf .globalrc