Add your description here
Project description
diff-parse
Description
diff-parse is a Python project that provides a utility to parse git diff strings into a structured JSON format. This
can be useful for analyzing changes in code, generating reports, or integrating with other tools that require diff
information.
Installation
To install the dependencies for this project, you can use the following command:
pip install -r requirements.txt
Usage
You can use the diff-parse script to parse a git diff string. The script is defined in the pyproject.toml file and
can be executed as follows:
diff-parse "your_git_diff_string_here"
Alternatively, you can run the script directly using Python:
python src/gitdiffparser/cli.py "your_git_diff_string_here"
Example
Here is an example of how to use the diff-parse script:
diff-parse "diff --git a/file.txt b/file.txt\nindex 83db48f..f735c2d 100644\n--- a/file.txt\n+++ b/file.txt\n@@ -1,3 +1,3 @@\n-Hello World\n+Hello Python\n This is a test file."
Project Structure
src/diff_parse/cli.py: Entry point for the command-line interface.src/diff_parse/app.py: Contains the main logic for parsing git diff strings.pyproject.toml: Project configuration file.
Dependencies
fire>=0.7.0pydantic>=2.10.6
License
This project is licensed under the MIT License.
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
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
File details
Details for the file gitdiffparser-0.1.0.tar.gz.
File metadata
- Download URL: gitdiffparser-0.1.0.tar.gz
- Upload date:
- Size: 3.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/2.0.0 CPython/3.12.8 Darwin/24.2.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
e17cbcd7fd61827f1bbad8d459ad61b2c09031d2bcbaf7611011d79a3b240f5f
|
|
| MD5 |
2c21bb8c12e8dbee8476555042d13e3e
|
|
| BLAKE2b-256 |
b582885ed0a01c40ae6a5d8d27cf98b9ed4c9387f063315221989f92174c241c
|
File details
Details for the file gitdiffparser-0.1.0-py3-none-any.whl.
File metadata
- Download URL: gitdiffparser-0.1.0-py3-none-any.whl
- Upload date:
- Size: 5.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/2.0.0 CPython/3.12.8 Darwin/24.2.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
f9433cd041503714c6364824cf9ed4c9d5e219a534098172971e525823bdd2a2
|
|
| MD5 |
f494f0b1139877cd335d08f4a530862f
|
|
| BLAKE2b-256 |
054515e8a55c325a826fb906628a254d452a8ab5879c446fca25e7cacb728aaa
|