Skip to content

fix(ls): filter quality wrong truncation#990

Open
TropicalDog17 wants to merge 12 commits intortk-ai:developfrom
TropicalDog17:fix/issue-948
Open

fix(ls): filter quality wrong truncation#990
TropicalDog17 wants to merge 12 commits intortk-ai:developfrom
TropicalDog17:fix/issue-948

Conversation

@TropicalDog17
Copy link
Copy Markdown

@TropicalDog17 TropicalDog17 commented Apr 3, 2026

Summary

Might fixes #948

Problem: The old code split ls -la lines on whitespace and used fixed column indices (parts[4] for size, parts[8..] for filename). This broke when owner/group names contained spaces, causing the columns to shift — sizes became 0 and date/time fragments leaked into filenames.

Fix: The new parse_ls_line() function uses a regex (LS_DATE_RE) to find the date field as a stable anchor, which allow correctly parsing.

Test plan

  • cargo fmt --all && cargo clippy --all-targets && cargo test passed for old and newly added tests

Important: All PRs must target the develop branch (not master).
See CONTRIBUTING.md for details.

aeppling and others added 8 commits March 30, 2026 15:13
@CLAassistant
Copy link
Copy Markdown

CLAassistant commented Apr 3, 2026

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you all sign our Contributor License Agreement before we can accept your contribution.
2 out of 3 committers have signed the CLA.

✅ aeppling
✅ TropicalDog17
❌ github-actions[bot]
You have signed the CLA already but the status is still pending? Let us recheck it.

@TropicalDog17
Copy link
Copy Markdown
Author

Hi @aeppling can you check this out, this is my first pr to the repo, thank you for your help

@aeppling aeppling changed the title Fix/issue 948 fix(ls): filter quality wrong truncation Apr 3, 2026
@aeppling
Copy link
Copy Markdown
Contributor

aeppling commented Apr 3, 2026

hello @TropicalDog17 , valid for me, could you remove the cargo lockfile, toml version bump and .release-please-manifest.json from this please ?

This should just aim ls.rs

@aeppling aeppling added the filter-quality Filter produces incorrect/truncated signal label Apr 3, 2026
@TropicalDog17
Copy link
Copy Markdown
Author

Yeah I've adjusted, my bad @aeppling

@TropicalDog17
Copy link
Copy Markdown
Author

Is it ready to merge @aeppling?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

filter-quality Filter produces incorrect/truncated signal

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants