| Crates.io | trailing-whitespaces |
| lib.rs | trailing-whitespaces |
| version | 0.5.0 |
| created_at | 2025-05-21 10:42:22.257605+00 |
| updated_at | 2025-09-17 06:58:07.547602+00 |
| description | Removes trailing whitespaces and trailing empty lines from text files |
| homepage | https://gitlab.com/hsn10/trailing-whitespaces |
| repository | https://gitlab.com/hsn10/trailing-whitespaces.git |
| max_upload_size | |
| id | 1683230 |
| size | 13,812 |
Removes trailing whitespaces and trailing empty lines from text files.
Inspired by JavaScript npx tool https://github.com/o175/trailing-whitespaces#readme for removing trailing whitespace from lines in text files.
trailing-whitespaces [-v] glob ...
-v lists changed files
JavaScript version of trailing-whitespaces do not remove trailing empty lines like we do.
Rust glob crate patterns are described here.
They are slighly different from JavaScript fast-glob patterns
which original JavaScript trailing-whitespaces tool uses.
Instead of
npx trailing-whitespaces ./src/**/.js
You need to run
trailing-whitespaces ./src/**/*.js
This is free and unencumbered software released into the public domain.
This code can be used under terms of CC0-1.0 or the Unlicense.
![]()