Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

@bbrodriges
Copy link
Contributor

gopls has an option to DirectoryFilters. It allows to add or remove certain directories from workspace. This option is especially useful if workspace is a root of giant monorepository project. Without this option it is impossible to open such projects due to endless indexing process.

This PR adds support for this option via standard govim config option.

@bbrodriges
Copy link
Contributor Author

Side note: I have added this feature by "copying" GoplsEnv option code. Please point if there are some places that I've missed.

I also have very little understanding of testdata scenarios mechanics. I'd be very grateful if you could help me to add proper tests for this feature.

Copy link
Member

@myitcv myitcv left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for looking into this.

One question, related to the underlying support in gopls rather than this PR.

And one small change to be made.

@myitcv myitcv force-pushed the directory_filters branch from e7afcfc to efb27b8 Compare April 9, 2021 08:24
@myitcv
Copy link
Member

myitcv commented Apr 9, 2021

@bbrodriges - thanks for kick starting this PR and doing the bulk of the work for this. I've added a quick test to verify things work as expected.

@myitcv myitcv linked an issue Apr 9, 2021 that may be closed by this pull request
@myitcv
Copy link
Member

myitcv commented Apr 9, 2021

I also have very little understanding of testdata scenarios mechanics. I'd be very grateful if you could help me to add proper tests for this feature.

I've added some more detail to https://github.com/govim/govim/wiki/govim-tests to explain the structure of our testscript tests.

@myitcv myitcv merged commit 8ac7eb7 into govim:main Apr 9, 2021
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

Successfully merging this pull request may close these issues.

cmd/govim: support gopls directoryFilters setting

2 participants