jsctags
jsctags copied to clipboard
unable to get proper tags file for vim
Hi,
I tried on bunch of files as well as single file and generate tags file but seems vim will not find the tag.
https://github.com/Countly/countly-server/blob/master/api/api.js
jsctags api.js -f >> tags
Then in vim tried to CTRL + ] with cursor under "validateUserForWriteAPI" on line 248. It says tag not found. E426: tag not found: validateUserForWriteAPI
I hope I am attempting the use of this module correctly.
Also to create a tags file for entire dir tree should I do:
find . -name "*.js" | xargs -n 1 -I {} jsctags {} -f >> tags
I tried above and it said tags file not sorted. cannot find tag.
Regards
Miten.
find . -name "*.js" | xargs -n 1 -I {} jsctags {} -f > tags
Seems to work for generating the tags, but still generate them with empty spaces in between rows and unsorted, which causes vim to complain
If you input this command you should get the output correct of the ctgas
find . "*.js" -exec jsctags {} -f \; | sed '/^$/d' | sort > tags
@mitermayer does this still work? If so do you think it would be a good addition to the README?
find . -type f -iregex .*\.js$ -exec jsctags {} -f \; | sed '/^$/d' | sort > tags
might be a better option.
@ianks is this worth adding to the README?
Yes it would IMO. What would be even better was if the CLI had a better interface, though.
PR!