Metadata-Version: 2.4
Name: crcutil
Version: 1.5.1
Author-email: Carlos Florez <carlos@florez.co.uk>
Maintainer-email: Carlos Florez <carlos@florez.co.uk>
License: MIT License
        
        Copyright (c) 2025 CARLOS FLOREZ
        
        Permission is hereby granted, free of charge, to any person obtaining a copy
        of this software and associated documentation files (the "Software"), to deal
        in the Software without restriction, including without limitation the rights
        to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
        copies of the Software, and to permit persons to whom the Software is
        furnished to do so, subject to the following conditions:
        
        The above copyright notice and this permission notice shall be included in all
        copies or substantial portions of the Software.
        
        THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
        IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
        FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
        AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
        LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
        OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
        SOFTWARE.
        
Project-URL: Repository, https://github.com/florez-carlos/crcutil
Classifier: Development Status :: 5 - Production/Stable
Classifier: Programming Language :: Python :: 3.12
Requires-Python: >=3.12.10
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: alive-progress==3.1.5
Requires-Dist: pyyaml==6.0.1
Requires-Dist: toml==0.10.2
Requires-Dist: pywin32==306; sys_platform == "win32"
Requires-Dist: jsonschema==4.23.0
Requires-Dist: colorlog==6.4.0
Requires-Dist: pynput==1.7.7
Requires-Dist: python-xlib==0.33
Dynamic: license-file

# CRCUtil
Recursively traverses a given location and generates a hash.json containing a CRC value for every encountered file/dir

> [!NOTE]
> Installation is supported only for the following: 
> - Windows
> - Linux

> [!NOTE]
> Development requires a fully configured [Dotfiles](https://github.com/florez-carlos/dotfiles) dev environment <br>

## Table of Contents

* [Installation](#installation)
  * [pip](#pip)
* [Usage](#usage)
  * [hash](#hash)
  * [diff](#diff)
  * [pause/resume](#pauseresume)
* [Development](#development)

## Installation
### Pip
```bash
python3 -m pip install crcutil
```

## Usage

### Hash

-l The location for which to generate the hash

```bash
crcutil hash -l C:\DESIRED\PATH
```
This will generate a hash.json file in: <br >
- Windows
```bash
C:\Users\<USERNAME>\Documents\crcutil\
```
- Linux
```bash
$HOME/crcutil
```
### Diff
If you hold 2 hashes generated from the same directory and would like to compare the differences.

-l The location of both hash files to compare

```bash
crcutil diff -l C:\HASH_FILE_1.json C:\HASH_FILE_2.json
```

This will compare both hash files and generate a diff.json in:
- Windows
```bash
C:\Users\<USERNAME>\Documents\crcutil\
```
- Linux
```bash
$HOME/crcutil
```
### Pause/Resume 
- The program can be paused/resumed at any time by pressing p, if a CRC is being calculated for a file
you have to wait for the calculation to complete before the program can pause.
- If you exit the program or it crashes unexpectedly mid operation, invoke the same command and the program will continue where it left off,
as long as the hash file is not corrupted

## Development

> [!NOTE]
> Development requires a fully configured [Dotfiles](https://github.com/florez-carlos/dotfiles) dev environment <br>

```bash
source init.sh
```


