{ "info": { "author": "leoetlino", "author_email": "leo@leolam.fr", "bugtrack_url": null, "classifiers": [ "License :: OSI Approved :: GNU General Public License v2 or later (GPLv2+)", "Operating System :: OS Independent", "Programming Language :: Python :: 3 :: Only", "Topic :: Software Development :: Libraries" ], "description": "## Nintendo SARC archive reader and writer\n\n### Setup\n\nInstall Python 3.6+ (**64 bit version**) then run `pip install sarc`.\n\n### List files in an archive\n\n sarc list ARCHIVE\n\n### Extract an archive\n\n sarc extract ARCHIVE\n\n### Create an archive\n\n sarc create [--be] FILES_TO_ADD DEST_SARC\n\nYou can give it directories too, in which case the entire directory will be added to the archive\nrecursively.\n\nPass `--be` (shorthand: `-b`) if you want `sarc` to use big endian mode (for the Wii U).\n\nAn important option is `--base-path`. This option lets you remove parts of the path.\nFor example, if you pass a path like `Mods/BotW/System/Version.txt`, you will likely want to pass\n`--base-path Mods/BotW` to get rid of the leading components.\n\nIf only a single directory is passed, the base path is set for you automatically.\n\nSo typical usage example:\n\n sarc create ~/botw/Bootup/ ~/botw/ModifiedBootup.pack\n\n### Update an archive\n\n sarc update FILES_TO_ADD SARC_TO_MODIFY\n\nThis is almost identical to `create`.\n\nBy default, `sarc` will keep the endianness of the original archive. You can override this\nwith `--endian {le,be}` (le for little and be for big endian).\n\n### Delete files from an archive\n\n sarc delete FILES_TO_DELETE SARC_TO_MODIFY\n\nNothing much to say here. Just keep in mind FILES_TO_DELETE takes archive paths\n(those that are printed by `list`).\n\n### Library usage\n\n```python\nimport sarc\n\narchive = sarc.read_file_and_make_sarc(file)\n# or if you already have a buffer\narchive = sarc.SARC(archive_bytes)\nif archive:\n for file_name in archive.list_files():\n size = archive.get_file_size(file_name)\n data = archive.get_file_data(file_name)\n\n```\n\nTo modify an archive:\n\n```python\nimport sarc\n\nwriter = sarc.make_writer_from_sarc(archive)\n# or if you're reading from a file\nwriter = sarc.read_sarc_and_make_writer(file)\n# or for a blank archive\nwriter = sarc.SARCWriter(be=big_endian)\n\nwriter.add_file('test.bfevfl', b'file contents')\nwriter.add_file('another_file.txt', b'file contents')\nwriter.add_file('test.bfevfl', b'replacing a file')\n\nwriter.delete_file('another_file.txt')\n\nwriter.write(output_stream)\n```\n\nFor more information, please look at [sarc.py](sarc/sarc.py).\n\n### License\n\nThis software is licensed under the terms of the GNU General Public License, version 2 or later.\n\n\n", "description_content_type": "text/markdown", "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/leoetlino/sarc", "keywords": "", "license": "", "maintainer": "", "maintainer_email": "", "name": "sarc", "package_url": "https://pypi.org/project/sarc/", "platform": "", "project_url": "https://pypi.org/project/sarc/", "project_urls": { "Homepage": "https://github.com/leoetlino/sarc" }, "release_url": "https://pypi.org/project/sarc/2.0.2/", "requires_dist": [ "rstb (~=1.0)", "wszst-yaz0 (~=1.0)" ], "requires_python": ">=3.6", "summary": "Nintendo SARC archive reader and writer", "version": "2.0.2" }, "last_serial": 5897132, "releases": { "1.0.0.post1": [ { "comment_text": "", "digests": { "md5": "fc1878b161654414e216c4f4f9adb1b2", "sha256": "526069f9ad82f2b1b48caa22849637f1d911728adae7beda755cddab286cb4a2" }, "downloads": -1, "filename": "sarc-1.0.0.post1.tar.gz", "has_sig": false, "md5_digest": "fc1878b161654414e216c4f4f9adb1b2", "packagetype": "sdist", "python_version": "source", "requires_python": ">=3.6", "size": 9979, "upload_time": "2018-07-30T18:00:13", "url": "https://files.pythonhosted.org/packages/22/8b/7b5148a8e97e562e2ae6d01c7f9ffdfd424b90992c52f6ab73adf5b04b89/sarc-1.0.0.post1.tar.gz" } ], "1.0.1": [ { "comment_text": "", "digests": { "md5": "7bf9ae6e6e86ca8a02cfca186a1add64", "sha256": "6edaafed964077a512325d79f98cc00c1b2c5fb7ce07205965425f3a9b3d19e1" }, "downloads": -1, "filename": "sarc-1.0.1.tar.gz", "has_sig": false, "md5_digest": "7bf9ae6e6e86ca8a02cfca186a1add64", "packagetype": "sdist", "python_version": "source", "requires_python": ">=3.6", "size": 10029, "upload_time": "2018-08-06T15:46:02", "url": "https://files.pythonhosted.org/packages/29/b1/1e83593465b2fe25ba9f8de06056296d31887e2df0a573ae09d8bbb91b90/sarc-1.0.1.tar.gz" } ], "1.0.2": [ { "comment_text": "", "digests": { "md5": "b107faff468801e9ebf8f90409dcdd0f", "sha256": "9e1b4e0f9803c09a6372369a3e3bacee28293ff1c2e2a8be9eb8e90f1a148d8c" }, "downloads": -1, "filename": "sarc-1.0.2-py3-none-any.whl", "has_sig": false, "md5_digest": "b107faff468801e9ebf8f90409dcdd0f", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": ">=3.6", "size": 10441, "upload_time": "2018-08-10T12:09:27", "url": "https://files.pythonhosted.org/packages/5a/51/6bc351d0a4fe5330922c79c832498395ff023828597aa1453e1701a5d84b/sarc-1.0.2-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "42a47eac72df37e918fae3ecf339e1c3", "sha256": "2d47cb876e4d84ad5a6b8b6d12835f77a889db216728a5828fd64fa4f01bab6b" }, "downloads": -1, "filename": "sarc-1.0.2.tar.gz", "has_sig": false, "md5_digest": "42a47eac72df37e918fae3ecf339e1c3", "packagetype": "sdist", "python_version": "source", "requires_python": ">=3.6", "size": 10047, "upload_time": "2018-08-09T21:19:08", "url": "https://files.pythonhosted.org/packages/a8/6d/794cbb5b9e0d63c9b90a6d57e83b76147ed14fc544b7085be7a1b334ff98/sarc-1.0.2.tar.gz" } ], "1.0.3": [ { "comment_text": "", "digests": { "md5": "e5d4ff37de004f9e67b4e39de493ff7e", "sha256": "b535aa271b3105e32785b5b17f44e0aa1100cd0ec24372d9f9c1c051c1eaf5af" }, "downloads": -1, "filename": "sarc-1.0.3-py3-none-any.whl", "has_sig": false, "md5_digest": "e5d4ff37de004f9e67b4e39de493ff7e", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": ">=3.6", "size": 10443, "upload_time": "2018-08-10T22:55:18", "url": "https://files.pythonhosted.org/packages/87/1c/07a2bea8bec07eb316aad11396a623dbd182396f4ae97b34b54cbe08eeb7/sarc-1.0.3-py3-none-any.whl" } ], "1.0.4": [ { "comment_text": "", "digests": { "md5": "8f078f07e913c54e3fb378eb5fb957ec", "sha256": "b443b0d598f7777217ccad70edf3264ec9d0ad73a669123826098b53789838ca" }, "downloads": -1, "filename": "sarc-1.0.4-py3-none-any.whl", "has_sig": false, "md5_digest": "8f078f07e913c54e3fb378eb5fb957ec", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": ">=3.6", "size": 10463, "upload_time": "2018-08-21T19:49:59", "url": "https://files.pythonhosted.org/packages/68/f0/767b3c5046822ade3d51ce5064b13002f544d8eb26aa684a014334d099ed/sarc-1.0.4-py3-none-any.whl" } ], "1.0.5": [ { "comment_text": "", "digests": { "md5": "3e722262212a3c46a600a5f333a20f6e", "sha256": "2adf21fa89465a199555badf330455b25f51e8880943807a3129c581e5fdebb9" }, "downloads": -1, "filename": "sarc-1.0.5-py3-none-any.whl", "has_sig": false, "md5_digest": "3e722262212a3c46a600a5f333a20f6e", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": ">=3.6", "size": 10463, "upload_time": "2018-08-29T17:49:38", "url": "https://files.pythonhosted.org/packages/23/a1/6f27a47563cff2365729af23f55591ca2ea11b70d356fb1c403a11e50d97/sarc-1.0.5-py3-none-any.whl" } ], "1.0.5.post1": [ { "comment_text": "", "digests": { "md5": "7f7a55d85a797a584c6659f88955e70b", "sha256": "27ccd5179acb92e114f5da2fb37630b9b2e3a3fa06f2143b0cf1c55361204876" }, "downloads": -1, "filename": "sarc-1.0.5.post1-py3-none-any.whl", "has_sig": false, "md5_digest": "7f7a55d85a797a584c6659f88955e70b", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": ">=3.6", "size": 10893, "upload_time": "2018-08-30T14:16:42", "url": "https://files.pythonhosted.org/packages/80/e5/6defee47fa62dbb7cd822d1c7124f34609104ccfdf58b82ab81b480f55ef/sarc-1.0.5.post1-py3-none-any.whl" } ], "1.0.6": [ { "comment_text": "", "digests": { "md5": "b8abd9d6f74dd202362a2d51470f3224", "sha256": "6537a73289259c39e5dba99757ea32be34ede83b9204ec9311df89db7b44f725" }, "downloads": -1, "filename": "sarc-1.0.6-py3-none-any.whl", "has_sig": false, "md5_digest": "b8abd9d6f74dd202362a2d51470f3224", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": ">=3.6", "size": 10788, "upload_time": "2018-09-02T12:45:40", "url": "https://files.pythonhosted.org/packages/b1/97/a747d6c8b1154471c26bbe5cb30eaca7fc5011d949489b1eb8e8e3e9a59b/sarc-1.0.6-py3-none-any.whl" } ], "1.0.6.post1": [ { "comment_text": "", "digests": { "md5": "ca3eca6d321039b2016c2fb0e85a1f05", "sha256": "e7ba362e9962b0e103f27818b16f7f9d2c618a78d4f88d0ac88312243a767013" }, "downloads": -1, "filename": "sarc-1.0.6.post1-py3-none-any.whl", "has_sig": false, "md5_digest": "ca3eca6d321039b2016c2fb0e85a1f05", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": ">=3.6", "size": 11907, "upload_time": "2018-09-02T13:09:03", "url": "https://files.pythonhosted.org/packages/32/b3/340c6f04d544a70bc9f6e1f9d1d2f5c4766e6c9816879d80b82da244709f/sarc-1.0.6.post1-py3-none-any.whl" } ], "1.1.0": [ { "comment_text": "", "digests": { "md5": "c651cf3f0025827a9167e35722ac28f0", "sha256": "94f85a17d066ceb5fd1176d391aed1d6b7a63ea8028bca748923d2649f39ba38" }, "downloads": -1, "filename": "sarc-1.1.0-py3-none-any.whl", "has_sig": false, "md5_digest": "c651cf3f0025827a9167e35722ac28f0", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": ">=3.6", "size": 11927, "upload_time": "2018-09-23T13:52:59", "url": "https://files.pythonhosted.org/packages/49/74/7bdf37582e2b8e3d750195d0e79ae167eece95f87909c99fad66d7db90e9/sarc-1.1.0-py3-none-any.whl" } ], "1.1.1": [ { "comment_text": "", "digests": { "md5": "36e8642f12009e20531a9e689ad32027", "sha256": "e4a5765561e9e2d4517638fda8ab165d0c3a0fc04cb9e4780efc50d99f1d1cfd" }, "downloads": -1, "filename": "sarc-1.1.1-py3-none-any.whl", "has_sig": false, "md5_digest": "36e8642f12009e20531a9e689ad32027", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": ">=3.6", "size": 12182, "upload_time": "2018-11-20T21:44:39", "url": "https://files.pythonhosted.org/packages/21/51/be3e3d4e59a233ab470bb7981d3f77df25dc6738c95e4ef461b80043f526/sarc-1.1.1-py3-none-any.whl" } ], "1.2.0": [ { "comment_text": "", "digests": { "md5": "892833bf9b910f7f331efd203c582c65", "sha256": "f860b9d3181c52f9000eda05ef72af2a4af3d0fbd07ba698cf37f4ffb3d93d5e" }, "downloads": -1, "filename": "sarc-1.2.0-py3-none-any.whl", "has_sig": false, "md5_digest": "892833bf9b910f7f331efd203c582c65", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": ">=3.6", "size": 19299, "upload_time": "2019-02-28T18:16:12", "url": "https://files.pythonhosted.org/packages/a6/13/05eccde62a93bbdd218c67b42f42f2f359bde41e5d7107ceb2b4e2bb24fb/sarc-1.2.0-py3-none-any.whl" } ], "2.0.0": [ { "comment_text": "", "digests": { "md5": "858c54ac2f2b058f4d9fb182c8673a0f", "sha256": "cf47cd957595aa76bb2c86bc0cdff4dcade7ad09f34bb94c2d2d780a6a94e2f8" }, "downloads": -1, "filename": "sarc-2.0.0-py3-none-any.whl", "has_sig": false, "md5_digest": "858c54ac2f2b058f4d9fb182c8673a0f", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": ">=3.6", "size": 19330, "upload_time": "2019-04-22T20:43:00", "url": "https://files.pythonhosted.org/packages/9c/20/c424ded46dc13a29c5f9c54c1e8ec096e955d24302eeb7fd78b71e4b0cc9/sarc-2.0.0-py3-none-any.whl" } ], "2.0.1": [ { "comment_text": "", "digests": { "md5": "1500ae9afbc16eaa1bb910cb420c4577", "sha256": "37f3ad8495f45c3318f54bed263b4dfce2e242846c8d821753c4d63133ad5fd5" }, "downloads": -1, "filename": "sarc-2.0.1-py3-none-any.whl", "has_sig": false, "md5_digest": "1500ae9afbc16eaa1bb910cb420c4577", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": ">=3.6", "size": 19326, "upload_time": "2019-05-26T13:30:15", "url": "https://files.pythonhosted.org/packages/e5/e0/7d9fed0996f1a5741d5613993603b0521843d3cafa092fdf24c018b7c7d1/sarc-2.0.1-py3-none-any.whl" } ], "2.0.2": [ { "comment_text": "", "digests": { "md5": "4af076cf97f086ebe34d1a6a16740c64", "sha256": "3c9697d2c88a942522a74c04085d48744d0d03477d52110f79ba109997a2216a" }, "downloads": -1, "filename": "sarc-2.0.2-py3-none-any.whl", "has_sig": false, "md5_digest": "4af076cf97f086ebe34d1a6a16740c64", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": ">=3.6", "size": 19327, "upload_time": "2019-09-27T17:09:34", "url": "https://files.pythonhosted.org/packages/03/e9/a70a8feaf70a57ea38bcc1e59640cdd2681ffa3bf7217358ff9459801c9b/sarc-2.0.2-py3-none-any.whl" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "4af076cf97f086ebe34d1a6a16740c64", "sha256": "3c9697d2c88a942522a74c04085d48744d0d03477d52110f79ba109997a2216a" }, "downloads": -1, "filename": "sarc-2.0.2-py3-none-any.whl", "has_sig": false, "md5_digest": "4af076cf97f086ebe34d1a6a16740c64", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": ">=3.6", "size": 19327, "upload_time": "2019-09-27T17:09:34", "url": "https://files.pythonhosted.org/packages/03/e9/a70a8feaf70a57ea38bcc1e59640cdd2681ffa3bf7217358ff9459801c9b/sarc-2.0.2-py3-none-any.whl" } ] }