Fix Source Control File Names With Spaces#1858
Merged
thecoolwinter merged 10 commits intoCodeEditApp:mainfrom Aug 31, 2024
Merged
Fix Source Control File Names With Spaces#1858thecoolwinter merged 10 commits intoCodeEditApp:mainfrom
thecoolwinter merged 10 commits intoCodeEditApp:mainfrom
Conversation
CodeEdit/Features/UtilityArea/TerminalUtility/UtilityAreaTerminalView.swift
Outdated
Show resolved
Hide resolved
tom-ludwig
requested changes
Aug 26, 2024
Member
tom-ludwig
left a comment
There was a problem hiding this comment.
Just a few small tweaks needed. Also, why was LICENSE.md renamed to LICENSE2.md?
CodeEdit/Features/Documents/WorkspaceDocument/WorkspaceDocument.swift
Outdated
Show resolved
Hide resolved
...gatorArea/SourceControlNavigator/Changes/Views/SourceControlNavigatorChangesCommitView.swift
Outdated
Show resolved
Hide resolved
...it/Features/NavigatorArea/SourceControlNavigator/Views/ChangedFile/GitChangedFileLabel.swift
Show resolved
Hide resolved
Collaborator
Author
Haha whoops, I made another PR fixing some renaming stuff and renamed that file in the demo video. |
Co-authored-by: Tom Ludwig <[email protected]>
…lwinter/CodeEdit into fix/source-control-spaces
austincondiff
approved these changes
Aug 31, 2024
Collaborator
austincondiff
left a comment
There was a problem hiding this comment.
This is some really nice work!
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Main Changes
GitChangedFiles orURLs instead ofCEWorkspaceFiles. TheCEWorkspaceFilescreated by these methods were disconnected from the workspace's file manager and it becomes messy to store things like old file names (in the case of renames) and the staged and unstaged statuses.GitChangedFileto be able to much more accurately represent a git file change. It now tracks two statuses, provides multiple helper methods and properties for use in UI.GitClient. getChangedFilesandGitClient. getStagedFileswithGitClient. getStatus. Also adds aStatusstruct to theGitClient. This new method uses the porcelain v2 version ofgit statusto fetch more information per file. It also uses the-zoption to get a easily-readable format.GitChangedFileorURLin place ofCEWorkspaceFIlewhere possible and only fetchCEWorkspaceFiles when necessary.This also sets up the required changes to view file renames correctly in source control lists.
Other Changes
GitClient. getCommitHistoryto correctly specify the branch name and file. Fixes an untracked bug where a file with the same name as a branch would cause an error (eg a file namedmainon themainbranch).GitTypetoGitStatus.GitClientand logs errors in a few key methods./caused issues when using relative URLs.GitClient.addandGitClient.resetto use quoted, relative, paths.Related Issues
Checklist
Screenshots
Before:
Screen.Recording.2024-08-24.at.5.32.02.PM.mov
After:
Screen.Recording.2024-08-24.at.5.33.06.PM.mov