oxy log shows the working copy as last recorded, and takes milliseconds (refs #41) 33472ccc08cc
Log spent all its time (163 ms on the Linux tree, 0.4 ms for the entries)
checking the files on disk to label the working-copy row clean. It now
describes the working copy as last recorded: its change's edits, and the
manifest's conflict flag (Repo::recorded_conflicted), as Git's log never
looks at the working tree; oxy status checks the disk. log -n 100: Linux
tree 0.03 s (from 0.17 s), oxygen 0.03 s and 22 MB (from 0.06 s, 79 MB),
a 10 000-commit vscode slice 0.02 s.
- **`oxy log` in milliseconds (#41).** Log no longer checks the files on disk: its working-copy row shows the working copy as last recorded, "(working copy)" or "(working copy, uncommitted changes)", as Git's log never looks at the working tree; `oxy status` checks the disk. `log -n 100` is 0.03 s on the Linux tree (from 0.17 s) and 0.02 s on a 10 000-commit history.
6
+
5
7
- **Status twice as fast as Git on the Linux tree (#41).** With uncommitted work, `oxy status` answers from a status cache while every file is as the last snapshot left it, and the manifest keeps every directory's time, so the tree is listed only when a directory's entries changed. One edited file is 0.10 to 0.12 s (from 0.44 s; Git 0.22 s) and a clean status 0.09 to 0.12 s (Git 0.20 to 0.26 s), in 80 MB. `oxy diff` renders the working copy from the cache too (0.20 s, from 0.41 s; Git 0.08 s). A commit after a status takes that status's snapshot instead of walking the tree again (0.37 s, from 0.68 s; Git 0.15 s). A file written within the racy window is now hashed by the prompt's check too, as it was by status.
6
8
7
9
- **Quieter notes (#55).** Notes start with a dimmed `›` instead of `ℹ`, which many terminal fonts draw as a boxed or emoji-style "i". A spinner's final line no longer shows two ticks or runs into the next line.
…
54 unchanged lines
modifiedcrates/oxy-core/src/repo/prompt.rs+6−0
…
469 unchanged lines
470
470
471
471
/// The manifest, with whether it records a conflict and uncommitted
472
472
/// work; parsed once while the file stays the same one.
473
+
/// Whether the working copy was conflicted when last recorded (the
474
+
/// manifest's flag), without looking at the files.