{"id":18746687,"url":"https://github.com/matrixeditor/nibarchive","last_synced_at":"2026-03-13T19:33:49.389Z","repository":{"id":214917259,"uuid":"729851252","full_name":"MatrixEditor/nibarchive","owner":"MatrixEditor","description":"Parser implementation of NeXTSTEP Interface Builder (NIB) files in Python3.","archived":false,"fork":false,"pushed_at":"2023-12-11T15:59:50.000Z","size":2734,"stargazers_count":9,"open_issues_count":0,"forks_count":2,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-09-05T11:45:47.999Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"https://matrixeditor.github.io/nibarchive/","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/MatrixEditor.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null}},"created_at":"2023-12-10T14:56:18.000Z","updated_at":"2025-08-09T22:32:58.000Z","dependencies_parsed_at":"2024-01-01T04:04:24.525Z","dependency_job_id":"af4d6643-9b41-4356-b495-63ac6ac63375","html_url":"https://github.com/MatrixEditor/nibarchive","commit_stats":null,"previous_names":["matrixeditor/nibarchive"],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/MatrixEditor/nibarchive","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MatrixEditor%2Fnibarchive","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MatrixEditor%2Fnibarchive/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MatrixEditor%2Fnibarchive/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MatrixEditor%2Fnibarchive/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/MatrixEditor","download_url":"https://codeload.github.com/MatrixEditor/nibarchive/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MatrixEditor%2Fnibarchive/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":30473340,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-13T17:15:31.527Z","status":"ssl_error","status_checked_at":"2026-03-13T17:15:22.394Z","response_time":60,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-07T16:26:31.343Z","updated_at":"2026-03-13T19:33:49.359Z","avatar_url":"https://github.com/MatrixEditor.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# NIBArchive-Parser\n\n[![python](https://img.shields.io/badge/python-3.9+-blue.svg?logo=python\u0026labelColor=grey)](https://www.python.org/downloads/)\n![Codestyle](https://img.shields.io:/static/v1?label=Codestyle\u0026message=black\u0026color=black)\n![License](https://img.shields.io:/static/v1?label=License\u0026message=GNU+GPLv3\u0026color=blue)\n[![PyPI](https://img.shields.io/pypi/v/nibarchive)](https://pypi.org/project/nibarchive/)\n[![Build and Deploy Sphinx Documentation](https://github.com/MatrixEditor/nibarchive/actions/workflows/sphinx.yml/badge.svg)](https://github.com/MatrixEditor/nibarchive/actions/workflows/sphinx.yml)\n\n\nParser implementation of NeXTSTEP Interface Builder (NIB) files in Python3.\n\n## NIBArchive\n\nThe `.nib` file is primarily associated with Interface Builder, a graphical user interface (GUI) design tool used to\ncreate the visual layout of user interfaces for applications. The purpose of a NIB file is to store the information\nabout the user interface elements, their properties, and their relationships with each other.\n\nThe file format has been described in detail in the [nibsqueeze](https://github.com/matsmattsson/nibsqueeze) repository.\n\n## Installation\n\nJust use pip:\n```console\n$ pip install nibarchive\n```\n\nand to build the docs you need `make` to be installed:\n```console\n$ pip install -r docs/requirements.txt\n$ cd docs \u0026\u0026 make html\n```\n\n## Usage\n\nThe python package provided with this repository supports parsing NIB archives into an object model. More detailed information about the implementation and fields of each class, please refer to the documentation available on [Github-Pages](https://matrixeditor.github.io/nibarchive/).\n\n### Parsing NIB files\n\nAs the `NIBArchiveParser` only accepts `IOBase` objects, we can either parse opened files directly or use `io.BytesIO` for a reader on existing byte structures.\n\n```python\nfrom nibarchive import NIBArchiveParser\n\n# Create the parser instance\nparser = NIBArchiveParser(verify=True)\n\n# Parse an input file from scratch\nwith open(\"path/to/file.nib\", \"rb\") as fp:\n    archive: NIBArchive = parser.parse(fp)\n```\n\nOr with `BytesIO`:\n\n```python\nfrom io import BytesIO\n\n# assue the file content is stored here\nbuffer = bytes(...)\nparser = NIBArchiveParser()\n\n# parse using BytesIO wrapper class\narchive = parser.parse(BytesIO(buffer))\n```\n\n### Working with NIBArchive objects\n\nAt this point we can use the returned object to inspect the files content. *But*, the parser does **not** organize the returned archive, so we have to do it afterwards:\n\n```python\n# Get an object\nobj: NIBObject = archive.objects[0]\n\n# Get the object's class name\nclass_name: ClassName = archive.get_class_name(obj)\n\n# Retrieve the object's values\nvalues: list[NIBValue] = archive.get_object_values(obj)\nfor value in values:\n    # Each value is mapped to a NIBKey\n    key: NIBKey = archive.get_value_key(value)\n```\n\nThere is a convienient method named `get_object_items` which automatically maps all values of an object to their corresponding keys. The return value is of type `dict[NIBKey, NIBValue]`\n\n## License\n\nDistributed under the GNU GPLv3. See `LICENSE` for more information.\n\n[^1]: https://github.com/matsmattsson/nibsqueeze/blob/master/NibArchive.md\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmatrixeditor%2Fnibarchive","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmatrixeditor%2Fnibarchive","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmatrixeditor%2Fnibarchive/lists"}