I use vim, so often use ctags to generate tags, Easy to use editor code hints.
Recommend use this regex cmd
ctags -R
--langdef=nim --langmap=nim:.nim
--regex-nim="/^[^\#]*\s+(\w+)\*+\s*\{.*\}/\1/t,type/"
--regex-nim="/^[^\#]*\s+(\w+)\*+.*=/\1/t,type/"
--regex-nim="/^[^\#]*proc\s+(\w+)\*+.*=/\1/f,func/"
--regex-nim="/^[^\#]*method\s+(\w+)\*+.*=/\1/f,func/"
--regex-nim="/^[^\#]*auto\s+(\w+)\*+.*=/\1/f,func/"
--regex-nim="/^[^\#]*template\s+(\w+)\*+.*=/\1/m,macro/"
--regex-nim="/^[^\#]*macro\s+(\w+)\*+.*=/\1/m,macro/"
--regex-nim="/^[^\#]*\s+`(\w+)[=]?`\*/\1/o,operator/"
--regex-nim="/^[^\#]*iterator\s+(\w+)\*+.*=/\1/i,iterator/"
use tags can easy to write nim code, Hope u like it, You can try AcVim if u use vim :) Thank you for posting this - it seems to be most of the way there but didn't quite work for me. This works for me:
ctags -R \
--langdef=nim --langmap=nim:.nim \
--regex-nim="/^[^\#]*\s+(\w+)\*\s*\{.*\}/\1/t,type/" \
--regex-nim="/^[^\#]*\s+(\w+)\*.*=/\1/t,type/" \
--regex-nim="/^[^\#]*proc\s+(\w+)/\1/f,func/" \
--regex-nim="/^[^\#]*method\s+(\w+)/\1/f,func/" \
--regex-nim="/^[^\#]*auto\s+(\w+)/\1/f,func/" \
--regex-nim="/^[^\#]*template\s+(\w+)/\1/m,macro/" \
--regex-nim="/^[^\#]*macro\s+(\w+)/\1/m,macro/" \
--regex-nim='/^[^\#]*\s+`(\w+)[=]?`/\1/o,operator/' \
--regex-nim="/^[^\#]*iterator\s+(\w+)/\1/i,iterator/"
Besides bash quoting issues, the main thing is you only seem to generate tags for public values. I am also not sure I understand why the [^\#]* is necessary - can anything besides whitespace come before a declaration?