Comments (5)
This would be really easy to do, where we say:
let walker = WalkDir::new(&self.path)
.into_iter()
....
.enumerate();
We just have to add a line saying:
let walker = WalkDir::new(&self.path)
.into_iter()
.filter_entry(|e| excludes.is_match(e.path()))
....
.enumerate();
The only downside is that the number and size of excluded files will be inaccurate.
from compactor.
I'd probably keep scanning excluded files in order to minimise the inaccuracy. Not much point skipping them - it doesn't make the directory scan much cheaper, just saves checking the compressed size.
It's notable that currently compressed files do not get checked against the excludes list - they go into the compressed pile, so you can still decompress them.
from compactor.
I'd probably keep scanning excluded files in order to minimise the inaccuracy. Not much point skipping them - it doesn't make the directory scan much cheaper, just saves checking the compressed size.
If you are excluding the Windows folder for example it has many many subfolders with many files in each of those. Seems like a total waste of time to be crawling that when it's on the excluded list. There are many other cases where you might have a directory tree with tons of sub files that you don't want to waste time processing also.
from compactor.
To be clear, if you've excluded a folder, it and all its contents are skipped entirely. If you've excluded a pattern of files inside a folder, like, say C:\bla\*.log
, matching files will still have their compressed file size checked like any other file so it'll still give you an accurate assessment of the size of the folder.
I really should publish a new release with this in, shouldn't I :)
from compactor.
Excluded subdirectories now pruned entirely in v0.8.0.
from compactor.
Related Issues (20)
- Skipping too many files that can be compressed HOT 2
- Wont open anymore - software exception HOT 4
- Question/Suggestion: Use WimBootCompress.ini as default exclusion list. Allows safe compression of C:\
- Windows crashes with a BSoD upon attempting to decompress HOT 1
- Winget repo
- Compressing Discord app folder would reset the session HOT 3
- Windows Search index could be broken after compression
- Windows Defender history is broken after compression HOT 3
- Decludes so many files that it only compressess 5%
- Compactor Seems to copy files to AppData\Local\VirtualStore\ when compressing files on C drive. HOT 2
- how much slower is lzx for 3600x when playing games HOT 2
- Recompress option, and dry run without analyze. Detect and block Windows 7 or fallback to a compatible algorithm. HOT 1
- Question regarding variable placeholder
- Compactor ignoring excluded folder HOT 2
- Suggestion: sizeof (by the maker of ImDisk) Shows compressed or sparse size rather than virtual size for files or directories HOT 2
- Confusing interaction with LZNT1-compressed files HOT 4
- Add default exclusion to .iso, .bin, & .cue HOT 1
- Does this work with Windows 11 HOT 2
- What would happen if I uncompress after adding extra files that exceeds the actual disk size? HOT 2
- Updates? HOT 8
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from compactor.