Wed, 02 Aug 2023 10:16:33 -0400 rust-matchers: add PatternMatcher
Spencer Baugh <sbaugh@janestreet.com> [Wed, 02 Aug 2023 10:16:33 -0400] rev 50889
rust-matchers: add PatternMatcher This should match the behavior of the Python patternmatcher. We need this for status [FILES] support.
Wed, 02 Aug 2023 10:33:11 -0400 rust-status: only visit parts of the tree requested by the matcher
Spencer Baugh <sbaugh@janestreet.com> [Wed, 02 Aug 2023 10:33:11 -0400] rev 50888
rust-status: only visit parts of the tree requested by the matcher This is an optimization that the matcher is designed to support, but we weren't doing it until now. This is primarily relevant for supporting "hg status [FILES]", where this optimization is crucial for getting good performance (without this optimization, that command will still scan the entire tree, and just filter it down after the fact). When this optimization fires we have to return false from traverse_fs_directory_and_dirstate, representing that that part of the tree *might* have new files which we didn't see because we skipped parts of it. This only affects the cached result of the status, and is necessary to make future status operations (which might use a different matcher) work properly.
Wed, 02 Aug 2023 10:21:18 -0400 rust-status: error on non-existent files in file_set
Spencer Baugh <sbaugh@janestreet.com> [Wed, 02 Aug 2023 10:21:18 -0400] rev 50887
rust-status: error on non-existent files in file_set file_set here consists of the files that were explicitly specified on the command line. Erroring on them matches the behavior of Python status.
Wed, 02 Aug 2023 10:07:00 -0400 rust-status: explicitly track bad file types
Spencer Baugh <sbaugh@janestreet.com> [Wed, 02 Aug 2023 10:07:00 -0400] rev 50886
rust-status: explicitly track bad file types Before this, we silently skipped bad file types. Now, we check to see if a path is an exact_match in our matcher, and if so, print an error for it, and only then do we skip it. A path will be an exact match when it's specified as an explicit command line argument, and this error-printing behavior is necessary for compatibility with Python status.
Mon, 14 Aug 2023 09:25:36 -0400 rust: de-hardcode glob_suffix
Spencer Baugh <sbaugh@janestreet.com> [Mon, 14 Aug 2023 09:25:36 -0400] rev 50885
rust: de-hardcode glob_suffix We're adding patternmatcher in a subsequent commit, and this needs needs to be different for includematcher and patternmatcher.
Tue, 08 Aug 2023 11:50:26 -0400 rust: improve the type on DirsMultiset::from_manifest
Spencer Baugh <sbaugh@janestreet.com> [Tue, 08 Aug 2023 11:50:26 -0400] rev 50884
rust: improve the type on DirsMultiset::from_manifest It could only return an HgPathError, but we didn't express this in the type, so we needed some unreachable!()s. Now that is expressed in the type.
Wed, 02 Aug 2023 09:59:49 -0400 rust: don't escape spaces in regex
Spencer Baugh <sbaugh@janestreet.com> [Wed, 02 Aug 2023 09:59:49 -0400] rev 50883
rust: don't escape spaces in regex Spaces are not in fact a regex special character, and escaping them is not correct.
Wed, 02 Aug 2023 10:09:23 -0400 rust-filepatterns: also normalize RelPath
Spencer Baugh <sbaugh@janestreet.com> [Wed, 02 Aug 2023 10:09:23 -0400] rev 50882
rust-filepatterns: also normalize RelPath These patterns should be normalized too; this at least does no harm, and is necessary for proper status support.
Wed, 09 Aug 2023 18:08:28 -0400 rust: simplify pattern file parsing
Spencer Baugh <sbaugh@janestreet.com> [Wed, 09 Aug 2023 18:08:28 -0400] rev 50881
rust: simplify pattern file parsing Previously we kept the pattern syntax as a &[u8] until the last possible moment, which meant we had to handle potential errors when parsing that &[u8]. But such errors could never actually occur, given the structure of the code. Now we parse it eagerly (in two places) and pass it around as a PatternSyntax, so we can delete some error handling code. parse_one_pattern is in particular useful for parsing patterns passed on the command line, as we'll support later in this series.
Wed, 02 Aug 2023 09:57:29 -0400 rust-matchers: better support file_set in IntersectionMatcher
Spencer Baugh <sbaugh@janestreet.com> [Wed, 02 Aug 2023 09:57:29 -0400] rev 50880
rust-matchers: better support file_set in IntersectionMatcher Previously, if both of the input matchers had non-exact file sets, IntersectionMatcher would simply have an empty fileset. Now, we duplicate Python behavior: we *union* the filesets of the matchers in that case. This makes some sense, because without exact input file sets, we can't do an exact intersection and must over-approximate. Concretely, this is necessary because the file_set is the list of files that were explicitly listed by the user, and we want to provide explicit errors for all such files, from both matchers.
(0) -30000 -10000 -3000 -1000 -300 -100 -10 +10 +100 +300 tip