{"id":21045036,"url":"https://github.com/quansight/diff-tar","last_synced_at":"2026-04-28T13:31:26.668Z","repository":{"id":98605454,"uuid":"235722873","full_name":"Quansight/diff-tar","owner":"Quansight","description":"create differential tarball of conda repository","archived":false,"fork":false,"pushed_at":"2020-02-17T05:32:09.000Z","size":6,"stargazers_count":1,"open_issues_count":0,"forks_count":1,"subscribers_count":6,"default_branch":"master","last_synced_at":"2025-03-10T15:17:08.710Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Quansight.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2020-01-23T04:31:41.000Z","updated_at":"2020-05-06T14:39:26.000Z","dependencies_parsed_at":null,"dependency_job_id":"1b6edb25-d072-4a48-8e48-2ba173cb1b9a","html_url":"https://github.com/Quansight/diff-tar","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Quansight%2Fdiff-tar","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Quansight%2Fdiff-tar/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Quansight%2Fdiff-tar/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Quansight%2Fdiff-tar/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Quansight","download_url":"https://codeload.github.com/Quansight/diff-tar/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243489835,"owners_count":20299001,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","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-19T14:19:38.882Z","updated_at":"2025-12-29T14:04:47.223Z","avatar_url":"https://github.com/Quansight.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"Create differential tarballs\n============================\n\nNote: The https://github.com/regro/conda-mirror/pull/9 adds this tool\n      to conda-mirror.\n\nThis tools allows you to create differential tarballs of a (usually\nmirrored) conda repository.  The resulting tarball can be used to update\na copy of the mirror on a remote (air-gapped) system, without having to\ncopy the entire conda repository.  The workflow is a follows:\n\n  1. we assume that the remote and local repository are in sync\n  2. create a `reference.json` file of the local repository\n  3. update the local repository using `conda-mirror` or some other tools\n  4. create the \"differential\" tarball\n  5. move the differential tarball to the remote machine, and unpack it\n  6. now that the remote repository is up-to-date, we should create a new\n     `reference.json` on the local machine.  That is, step 2\n\nNotes:\n------\n\nThe file `reference.json` is a collection of all `repodata.json`\nfiles (`linux-64`, `win-32`, `noarch`, etc.) of the local repository.\nIt is created in order to compare a future state of the repository to the\nstate of the repository when `reference.json` it was created.\n\nThe differential tarball contains files which either have been updated (such\nas `repodata.json`) or new files (new conda packages).  It is meant to be\nunpacked on top of the existing mirror on the remote machine by:\n\n    cd \u003crepository\u003e\n    tar xf update.tar\n    # or y using tar's -C option from any directory\n    tar xf update.tar -C \u003crepository\u003e\n\n\nExample:\n--------\n\nIn this example we assume that a conda mirror is located in `./repo`.\nCreate `reference.json`:\n\n    python mk_diff_tar.py --reference ./repo\n\nShow the files in respect to the latest reference point file (which would be\nincluded in the differential tarball).  Since we just created the reference\nfile, we don't expect any output:\n\n    python mk_diff_tar.py --show ./repo\n\nNow, we can update the mirror:\n\n    conda-mirror --upstream-channel conda-forge --target-directory ./repo ...\n\nCreate the actual differential tarball:\n\n    $ python mk_diff_tar.py --create ./repo\n    Wrote: update.tar\n    $ tar tf update.tar\n    noarch/repodata.json\n    noarch/repodata.json.bz2\n    noarch/ablog-0.9.2-py_0.tar.bz2\n    noarch/aws-amicleaner-0.2.2-py_0.tar.bz2\n    ...\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fquansight%2Fdiff-tar","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fquansight%2Fdiff-tar","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fquansight%2Fdiff-tar/lists"}