This file format modification was previously left incomplete because of
planned upcoming changes. Not all of these changes have been made yet,
but documenting what exists today will help talking more widely about it.
Details
- Reviewers
mharbison72 - Group Reviewers
hg-reviewers - Commits
- rHG77fc340acad7: dirstate-v2: Document flags/mode/size/mtime fields of tree nodes
Diff Detail
- Repository
- rHG Mercurial
- Branch
- default
- Lint
No Linters Available - Unit
No Unit Test Coverage
Event Timeline
This seems fine, but I couldn't import it without the previous commit, and I'd like someone who knows Rust to handle that.
mercurial/helptext/internals/dirstate-v2.txt | ||
---|---|---|
405 | s/called/call/ | |
424 | Are the other bits being masked out? There's a dirstate propose on the wiki to track the u+x bit on filesystems that don't support that, but it required setting and checking a bit for a FIFO or something exotic that Mercurial wouldn't handle anyway. If we're starting fresh, it would be nice to avoid the hack. |
mercurial/helptext/internals/dirstate-v2.txt | ||
---|---|---|
424 | At the moment all 32 bits are whatever we got from stat_result.st_mode, same as in dirstate-v1. But the status algorithm only looks at the exec bit. By the way maybe status should also look at the file type, in case a normal file became a symlink or vice versa. But last I tried I didn’t manage to craft a test case that does this without changing the mtime, since touch -d follows symlinks. I’m considering removing this mode field in dirstate-v2 and replacing it with a single HAS_EXEC_PERMISSION bit (plus maybe an IS_SYMLINK bit), but that’s not for this patch which document the current format. |
I couldn't import it without the previous commit, and I'd like someone who knows Rust to handle that.
To avoid this review dependency I’ve inverted the order of these two commits. This one now documents the previous format, and the commit that changes the format then also updates the documentation.
LGTM, but I still get an import error for this. Since there are a bunch of accepted things not pushed yet, maybe this has a dependency on one of those things.
$ hg phabimport D11625 applying patch from D11625 patching file rust/hg-core/src/dirstate_tree/on_disk.rs Hunk #2 FAILED at 93 abort: patch failed to apply
mercurial/helptext/internals/dirstate-v2.txt | ||
---|---|---|
424 | +1 for doing that before freezing the format. (I think the wiki page also had bits to indicate if each was emulated, but I don't have time to find it now.) | |
456 | /dependening/depending/ |
Is it on top of hg-committed / 38deb65d4441 that this does not apply cleanly? If so this is because because D11623 hasn’t been pushed to hg-commited yet. If you can fix that that should solve this import.
s/called/call/