Skip to content

Commit 629771d

Browse files
committed
Merge fix-f-drive-parity: glob-to-regex pattern fix for G-drive parity
2 parents 00457e6 + 4b79a96 commit 629771d

File tree

2 files changed

+6
-3
lines changed

2 files changed

+6
-3
lines changed

crates/uffs-cli/src/commands/output.rs

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1020,7 +1020,8 @@ mod tests {
10201020
.map_err(Into::into)
10211021
}
10221022

1023-
/// Create a large sample DataFrame (20,000+ rows) for testing slow-scan footer.
1023+
/// Create a large sample DataFrame (20,000+ rows) for testing slow-scan
1024+
/// footer.
10241025
fn large_sample_df() -> Result<DataFrame> {
10251026
let count = 20_000;
10261027
let paths: Vec<String> = (0..count)
@@ -1434,7 +1435,8 @@ mod tests {
14341435
drop(fs::remove_file(&path));
14351436

14361437
// Should NOT contain fast-scan message (row_count >= 20,000)
1437-
// Only check footer structure - first row will be "C:\Temp\file0.txt","file0.txt"
1438+
// Only check footer structure - first row will be
1439+
// "C:\Temp\file0.txt","file0.txt"
14381440
let lines: Vec<&str> = written.lines().collect();
14391441
let footer_start = lines.len().saturating_sub(4);
14401442
assert_eq!(lines[footer_start], "");

crates/uffs-cli/src/commands/search/mod.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -224,7 +224,8 @@ pub async fn search(
224224
let t_output = std::time::Instant::now();
225225
let elapsed = start_time.elapsed();
226226
let row_count = native.results.len();
227-
let cpp_pattern = format!(">{}:{}", native.index.volume, pattern);
227+
// Convert glob pattern to regex format for C++ footer (e.g., * -> .*)
228+
let cpp_pattern = format!(">{}:{}", native.index.volume, pattern.replace('*', ".*"));
228229
let footer_ctx = crate::commands::output::CppFooterContext {
229230
output_targets: &output_targets,
230231
pattern: &cpp_pattern,

0 commit comments

Comments
 (0)