Python Helper for Repetitive Tasks with File and Data Management
Project description
UtilityLib
UtilityLib is a Python package that provides a collection of ready-to-use functions for various file and directory operations, data processing tasks, and more.
Installation
- You can install UtilityLib via pip or by copying the UtilityLib directory into your project.
- Using pip:
pip install UtilityLib - Using GitHub:
pip install git+https://github.com/yourusername/UtilityLib.git
Usage/Examples
Here are some examples demonstrating the usage of UtilityLib:
Filename Extraction
# Method 1
from UtilityLib import EU
EU.filename("filepath/filename.ext1.ext2")
# Method 2
from UtilityLib import UtilityManager as UM
UM().filename("filepath/filename.ext1.ext2")
Project Configuration Management
# Method 3
import UtilityLib as UL
UL.UM.filename("filepath/filename.ext1.ext2")
UL.UtilityManager().filename("filepath/filename.ext1.ext2")
# Method 4
from UtilityLib import ProjectManager
_pm = ProjectManager(
path_bases=("/mnt/D/DataDrive", "D:/path-windows")
version=2,
subversion=202211
)
_pm.config.new_key.deeper_new_key = "new_value"
# Update Old Config
_pm.update_config()
# Save as a new version but later change key
_pm.update_config(subversion=20221103)
Compress Files to tar.gz Format
_wos_files = EU.search(f"{path_scrapped_queries}/WOS-Downloads", "*.csv")
EU.add_tgz_files(f"{path_scrapped_queries}/WOS-Downloads.tgz", _wos_files)
EU.delete_path(f"{path_scrapped_queries}/WOS-Downloads")
Updates/Revisions/Versions
2.10
- Added multi processing
- Method extension to add/update new method to the existing class object
- Method caching to speed up
2.9
2.8
- Method aliases
- Setup whl build system
2.6
20221103
- Added
ProjectManager- Dot notion to access or deep nested objected
- Can hold data by pickling and unpickling (Could there be any data loss due to protocol version change?)
- class to keep track of configuration
- persistent storage
- Storage by pickling and unpickling
20221018
- Class
DataUtilityfor quick processing of text, numbers or objects or frequently used libraries require_formmethod to include libraries from external folder
20220923
- Upgraded
FileSystemUtility.list_zipfiletoFileSystemUtility.list_zip_files
20220921
- Added cli argument parser
- ITERTOOLS product and combinations method
20220914
- Added single static
update_attributesmethod and removed__update_attrmethod from individual class
2.5.20220908
- Implemented ready to go import
from UtilityLib import EU - Param changes in EU.combination method
2.5.20220905
- Added new methods
- Major changes (check commit)
- Removed json parameter from FileSystemUtility.get_file
- Minor changes (check commit)
2.5.20220818
- Package reusability enhancement
2.4.20220129
- Initial version
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
utilitylib-2.12.tar.gz
(28.4 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
UtilityLib-2.12-py3-none-any.whl
(30.7 kB
view details)
File details
Details for the file utilitylib-2.12.tar.gz.
File metadata
- Download URL: utilitylib-2.12.tar.gz
- Upload date:
- Size: 28.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.0.0 CPython/3.10.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
a98cd0f8f4aedac52c6d5dc6723ba61ffd90a3e1b60784188a05fac60d2af7e2
|
|
| MD5 |
e12f1577b19babe7233b23c83b106dec
|
|
| BLAKE2b-256 |
459a782e6aac4d19a7443a227acdbf8c9db9c0a747d8693086d29621d947b8e0
|
File details
Details for the file UtilityLib-2.12-py3-none-any.whl.
File metadata
- Download URL: UtilityLib-2.12-py3-none-any.whl
- Upload date:
- Size: 30.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.0.0 CPython/3.10.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
0d4ff341261f37fd69de013db7802e0875efe4be6c194cc5a5328db29faadd26
|
|
| MD5 |
cd697a0abd12583cd88dc30a045f6969
|
|
| BLAKE2b-256 |
1a1cfc1b680c9f756514a53ea898c49bbce0b2158ed83d5429c48a76c95345a2
|