Skip to content

Repository files navigation

python-utils-19

A collection of lightweight utility functions designed to simplify common tasks in Python development. This project aims to provide developers with time-saving functions that enhance productivity and promote cleaner code.

Features

  • File Management: Simplified functions for file and directory operations, such as copying, moving, and deleting files.
  • Data Serialization: Easy functions to serialize and deserialize Python objects to and from JSON and YAML formats.
  • String Manipulation: A set of functions to efficiently handle string formatting, searching, and modification.
  • API Request Handling: Helper functions to streamline HTTP requests with built-in error handling and response parsing.

Installation

To install python-utils-19, you can use pip. Run the following command:

pip install python-utils-19

Alternatively, you can clone the repository and install it manually:

git clone https://github.com/Developer/python-utils-19.git
cd python-utils-19
pip install .

Basic Usage

Here’s a quick example demonstrating how to use some of the utilities provided in the python-utils-19 package:

from python_utils import file_utils, json_utils

# Copy a file
file_utils.copy_file('source.txt', 'destination.txt')

# Serialize a Python dictionary to JSON
data = {'name': 'Alice', 'age': 30}
json_string = json_utils.serialize_to_json(data)

# Print the JSON string
print(json_string)

# Deserialize back to a dictionary
loaded_data = json_utils.deserialize_from_json(json_string)
print(loaded_data)

License

MIT License

This project is licensed under the MIT License. See the LICENSE file for details.

About

Performance and utility tools for general

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages