A theme might want to mark git tracked folders (and files) in the sidebar with a dedicated label color or icon to distinguish from normal untracked folders.
The currently available states "added", "deleted", "modified", "ignored", "untracked", "missing", and "unmerged" are sufficient for files contained by a tracked folder. A file within a tracked folder with none of those attributes can be considdered "committed". A file within an untracked folder however isn't marked "untracked" and thus looks committed.
Folder containing committed files only ("clean worktree") can't be distinguished from a normal untracked folder as well. A folder is marked "untracked" only if it contains at least one untracked file.
Therefore some attribute values for the file_system_entry would be nice to have in order to explicitly mark tracked files & folders.
Preferred solution
The root of a repositorie's worktree might have a "worktree" attribute to be able to assign a unique folder icon to it with a git overlay icon or something like that. Just to see what folders in the sidebar are repositories and which not.
Each tracked file & folder (worktree root or sub directory) might have a "committed" state, if it isn't marked added/deleted/modified/missing/unmerged. A tracked folder might be marked "committed" alongside with untracked/ignored.
This would enable a theme to explicitly address clean folders and committed files to add a green check mark for instance.
Note: Not sure how to handle sub directories of a worktree, which contain only untracked files and folders. Should they be marked !tracked or just the same as before?
A mechanism to distinguish between folders containing some untracked/ignored files and those which contain only untracked/ignored files/folders would be nice to have. Theme - DAneo uses the "untracked" attribute to highlight collapsed folder labels, which looks like the whole folder is ignored/untracked even though some of the contained files are only.
Alternatives
A git repository could propably also be addressed by a special icon type
Problem description
A theme might want to mark git tracked folders (and files) in the sidebar with a dedicated label color or icon to distinguish from normal untracked folders.
The currently available states "added", "deleted", "modified", "ignored", "untracked", "missing", and "unmerged" are sufficient for files contained by a tracked folder. A file within a tracked folder with none of those attributes can be considdered "committed". A file within an untracked folder however isn't marked "untracked" and thus looks committed.
Folder containing committed files only ("clean worktree") can't be distinguished from a normal untracked folder as well. A folder is marked "untracked" only if it contains at least one untracked file.
Therefore some attribute values for the
file_system_entry
would be nice to have in order to explicitly mark tracked files & folders.Preferred solution
The root of a repositorie's worktree might have a
"worktree"
attribute to be able to assign a unique folder icon to it with a git overlay icon or something like that. Just to see what folders in the sidebar are repositories and which not.Each tracked file & folder (worktree root or sub directory) might have a
"committed"
state, if it isn't marked added/deleted/modified/missing/unmerged. A tracked folder might be marked"committed"
alongside with untracked/ignored.This would enable a theme to explicitly address clean folders and committed files to add a green check mark for instance.
A
"tracked"
state could propably be used to easily address all tracked files and folders no matter which state they have.Note: Tracked folders containing untracked files would have the
tracked
anduntracked
attribute then, which might be a bit confusing.Note: Not sure how to handle sub directories of a worktree, which contain only untracked files and folders. Should they be marked
!tracked
or just the same as before?A mechanism to distinguish between folders containing some untracked/ignored files and those which contain only untracked/ignored files/folders would be nice to have. Theme - DAneo uses the "untracked" attribute to highlight collapsed folder labels, which looks like the whole folder is ignored/untracked even though some of the contained files are only.
Alternatives
A git repository could propably also be addressed by a special icon type
Additional Information (optional)
Maybe not the most beautiful example, but what I have in mind is something like the TortoiseGit Explorer Integration
https://tortoisegit.org/docs/tortoisegit/tgit-dug.html#tgit-dug-general-dia-icons