A package to find small and large files in a directory
Project description
myfilesize
myfilesize
is a Python package designed to help you easily find small and large files within a directory structure.
Installation
You can install the package using pip:
pip install myfilesize
Usage
Finding Small Files
from myfilesize import find_small_files
directory_to_search = "/path/to/directory"
small_file_max_size_in_bytes = 1024 # Files smaller than 1KB
small_files = find_small_files(directory_to_search, small_file_max_size_in_bytes)
print("Small files:")
for file in small_files:
print(file)
Finding Large Files
from myfilesize import find_large_files
directory_to_search = "/path/to/directory"
large_file_min_size_in_bytes = 10485760 # Files larger than 10MB
large_files = find_large_files(directory_to_search, large_file_min_size_in_bytes)
print("Large files:")
for file in large_files:
print(file)
Benefits
- Simplicity: Easily find files based on size criteria with straightforward functions.
- Efficiency: Quickly navigate through directories to locate files that meet your size requirements.
- Integration: Seamless integration into your Python projects for file management tasks.
Contributing
Contributions are welcome! For major changes, please open an issue first to discuss what you would like to change.
License
This project is licensed under the MIT License.
Thank you for using myfilesize
! If you find this package helpful, consider starring the repository on GitHub. Your support is greatly appreciated!
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
myfilesize-1.0.0.tar.gz
(3.0 kB
view details)
Built Distribution
File details
Details for the file myfilesize-1.0.0.tar.gz
.
File metadata
- Download URL: myfilesize-1.0.0.tar.gz
- Upload date:
- Size: 3.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.0.0 CPython/3.11.2
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | ece0fdf0f187f165a982db8a022b55da8035b92e2dc30432f0e699704f853788 |
|
MD5 | 3a47fb6d97e2c791ff8ab58ba1b2441a |
|
BLAKE2b-256 | 0650df7c9e0d5057c9be1a040d95b9868e447ac354dc0f15214f8ffa4e1d2cb9 |
File details
Details for the file myfilesize-1.0.0-py3-none-any.whl
.
File metadata
- Download URL: myfilesize-1.0.0-py3-none-any.whl
- Upload date:
- Size: 3.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.0.0 CPython/3.11.2
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 786130d230dbc84dfa86f28e25f8806c72f064ff8e7a63e2404cb791471b0d1d |
|
MD5 | 9afca48046f97a494996be8e00485c33 |
|
BLAKE2b-256 | ebeabc735a23d005d8c0db99a79663d293d816c763d432b516b093113be81524 |