Metadata-Version: 2.1
Name: unarchiver
Version: 0.2.0
Summary: Unarchive an NSKeyedArchive into a python object.
Author: PandasAreBears
Author-email: emailadresspanda@gmail.com
Requires-Python: >=3.10,<4.0
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Requires-Dist: bpylist2 (>=4.1.1,<5.0.0)
Requires-Dist: click (>=8.1.7,<9.0.0)
Requires-Dist: click-pathlib (>=2020.3.13.0,<2021.0.0.0)
Requires-Dist: pydantic (>=2.7.1,<3.0.0)
Description-Content-Type: text/markdown

# Unarchiver

Unarchive an NSKeyedArchive into python.

## Installation

```sh
pip install unarchiver
```

## Command-line usage

```sh
Usage: unarchiver.py [OPTIONS] KEYED_ARCHIVE

  Unarchive an NSKeyedArchiver file.

Options:
  -o, --to-file PATH  A file to dump unarchived content into.
  --help              Show this message and exit.
```

``` sh
$ poetry run unarchive ~/Library/News/actionQueue
{
    "root": {
        "$type": "NSMutableDictionary",
        "NS.keys": [
            "FCFileCoordinatedAccountActionQueueLocalDataHintKey",
            "FCFileCoordinatedAccountActionQueueActionTypesKey"
        ],
        "NS.objects": [
            true,
            {
                "$type": "NSMutableArray",
                "NS.objects": []
            }
        ]
    }
}
```

## Library Usage

```py
from unarchiver.unarchiver import Unarchiver

unarchiver = Unarchiver(path_to_archive)

obj = unarchiver.parse()
```
