Skip to content
New issue

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

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

Already on GitHub? # to your account

Model script exclusion via SourceExclusions and skip files entirely instead of placing them temporarily on the source path #543

Merged
merged 5 commits into from
Jan 15, 2024

Conversation

fwcd
Copy link
Owner

@fwcd fwcd commented Jan 15, 2024

This PR moves the script extension checking logic introduced in #536 to SourceExclusions. This lets us test, in a single place, whether a URI is tracked by the source path or not. Additionally, language features (i.e. completions, hovers etc.) are now only provided for included files, previously KotlinTextDocumentService.recover forced these files onto the source path, largely subverting the exclusion logic and causing e.g. errors to show up in ignored files, if opened directly.

fwcd added 3 commits January 15, 2024 00:48
...to the source path. The rationale for this is that language features
would be provided even for excluded files, e.g. .kts scripts when
`kotlin.scripts.enabled` is disabled or source files in auto-generated
directories such as `./bin`.
@github-actions github-actions bot added the code quality Refactoring, tests etc. label Jan 15, 2024
@fwcd fwcd added this to the 1.3.9 milestone Jan 15, 2024
@fwcd fwcd merged commit 70dfeb4 into main Jan 15, 2024
8 checks passed
@fwcd fwcd deleted the improve-exclusions branch January 15, 2024 01:43
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
code quality Refactoring, tests etc.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant