Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

manual only reindex ? #1371

Closed
mckellyln opened this issue Feb 13, 2020 · 4 comments
Closed

manual only reindex ? #1371

mckellyln opened this issue Feb 13, 2020 · 4 comments

Comments

@mckellyln
Copy link

mckellyln commented Feb 13, 2020

Hi,

Thank you for rtags. I use it every day and it is awesome.
I was wondering if I could do something like:
1). disable auto-reindexing based on file mods
2). later on somehow mark index db as up-to-date

What I am getting at is I may index a branch and then git stash and change branches just to check something out (not build) and then when I switch back to my work branch I want to tell rtags the index db is up to date / valid and not have it re-index everything again unneccessarily.

Does anyone else have this use case or suggestion ?

I was also looking into ccache for compiling and wondering if something like that would also be interesting here.

thx,
-m

@fperies
Copy link

fperies commented Feb 13, 2020

Hello,

Have you tried to play with the 2 following commands ?:
Suspend indexation:
rc -X all
Resume indexation:
rc -X clear

The suspend should allow you to switch branch and resume when you come back.

@mckellyln
Copy link
Author

Thank you, I will try these things now.
But lets say the source code changed because I switched branches, but then some time later changed branches back to be what it was originally when I first indexed everything. Does a
rc -X clear
Then accept the db is up to date or does it see that 1000s of files have a new date (even tho they are really unchanged) and then re-index it all ?
I am excited to try.
take care,

@mckellyln
Copy link
Author

I see --suspend (-X) in the rc man page, but do not see the additional all/clear arg, I'll go look at the src.

@mckellyln
Copy link
Author

I maintain a version of vim-rtags. I will add rc -X support to it :-)
Thanks so much for this large productivity gain.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants