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

Project navigator files watch fixes #1452

Merged
merged 3 commits into from
Oct 16, 2023
Merged

Project navigator files watch fixes #1452

merged 3 commits into from
Oct 16, 2023

Conversation

avinizhanov
Copy link
Contributor

Description

I didn't find if there is a issue for this. But project navigator file watch was broken for me.
I decided to check if I can fix it. Works great for me now (see attached screen recording).

I updated DirectoryEventStream to listen for file changes instead of folders. This can be useful in other places for example when file modified, plus now it returns correct event type (previously it always returned changeInDirectory for me).

Fixed bug in files diff (CEWorkspaceFileManager.rebuildFiles): it somethings recreated CEWorkspaceFile for folders that already in flattenedFileItems

Checklist

  • I read and understood the contributing guide as well as the code of conduct
  • The issues this PR addresses are related to each other
  • My changes generate no new warnings
  • My code builds and runs on my machine
  • My changes are all related to the related issue above
  • I documented my code

Screenshots

Screen.Recording.2023-10-15.at.2.35.57.PM.mov

@austincondiff austincondiff self-requested a review October 15, 2023 20:14
Copy link
Collaborator

@austincondiff austincondiff left a comment

Choose a reason for hiding this comment

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

Great catch! Fix the SwiftLint errors and you should be good to go! Check out the SwiftLint section of our Code Style page in our wiki for real-time warnings locally.

@avinizhanov
Copy link
Contributor Author

@austincondiff SwiftLint failed in unrelated to this PR file, also Xcode doesn't show warning there for me.

@austincondiff
Copy link
Collaborator

It should show up if you have SwiftLint configured correctly but I could be wrong. We can go ahead if it is unrelated then. In the future, if the issue doesn't yet exist, feel free to create one and reference it in your PR so we can track it.

@avinizhanov
Copy link
Contributor Author

@austincondiff I have 70+ warnings for TODO, may be there is a limit. Anyway, I think I fixed this issue and enabled "trim trailing whitespace"

@austincondiff
Copy link
Collaborator

I know, it's a problem 😅

image

This is what I've done for now. Not a permanent solution.

@avinizhanov
Copy link
Contributor Author

Thanks 🙂

@austincondiff austincondiff merged commit 698b75e into CodeEditApp:main Oct 16, 2023
1 of 2 checks passed
@thecoolwinter thecoolwinter added the bug Something isn't working label Dec 23, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants