Skip to content

Conversation

skprabhanjan
Copy link
Contributor

@roblourens , Here is the implementation of case preservation in search to fix #78397 .

ideally copying it into a shared file so that find and search will use the same preserve case logic.

I could not achieve this as both use a different replacePattern files.

Please review this and let me know :)
I have tested it and this works perfectly fine :)

Copy link
Member

@roblourens roblourens left a comment

Choose a reason for hiding this comment

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

Thank you, this is almost perfect! One change, please create a file in src/vs/base/common called search.ts, and create a function there that does the work to check and apply the casing patterns. Basically it should just be the lines starting with matches[0].toUpperCase() === matches[0]. We should be able to share that code between the search side and the find side. Please copy the ReplacePattern unit tests for it too. Thanks!

@skprabhanjan
Copy link
Contributor Author

@roblourens, thanks for the review .
I will do that change and commit it post this weekend :)

@skprabhanjan
Copy link
Contributor Author

Hi @roblourens , All changes done as per your review :)
Please let me know if anything needs to be changed, Thanks !

@roblourens
Copy link
Member

This is great, thanks!

@roblourens roblourens merged commit 8b15ad7 into microsoft:master Aug 19, 2019
@roblourens roblourens added this to the August 2019 milestone Aug 19, 2019
@github-actions github-actions bot locked and limited conversation to collaborators Mar 27, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Implement case preservation in search as well
2 participants