{"id":17836327,"url":"https://github.com/vodik/repose","last_synced_at":"2025-03-19T19:31:28.564Z","repository":{"id":137110313,"uuid":"9877482","full_name":"vodik/repose","owner":"vodik","description":"an archlinux repo poking tool","archived":false,"fork":false,"pushed_at":"2024-03-30T00:02:50.000Z","size":551,"stargazers_count":127,"open_issues_count":19,"forks_count":15,"subscribers_count":8,"default_branch":"master","last_synced_at":"2025-02-28T22:16:44.842Z","etag":null,"topics":["archlinux","repository-utilities"],"latest_commit_sha":null,"homepage":null,"language":"C","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/vodik.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"COPYING","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":"2013-05-06T01:51:15.000Z","updated_at":"2025-01-06T17:55:27.000Z","dependencies_parsed_at":null,"dependency_job_id":"467c7286-5772-4995-858a-1f0bdf24f9a2","html_url":"https://github.com/vodik/repose","commit_stats":null,"previous_names":[],"tags_count":10,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vodik%2Frepose","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vodik%2Frepose/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vodik%2Frepose/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vodik%2Frepose/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/vodik","download_url":"https://codeload.github.com/vodik/repose/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":244039194,"owners_count":20387834,"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":["archlinux","repository-utilities"],"created_at":"2024-10-27T20:37:33.998Z","updated_at":"2025-03-19T19:31:28.559Z","avatar_url":"https://github.com/vodik.png","language":"C","funding_links":[],"categories":[],"sub_categories":[],"readme":"## repose\n\n\u003ca href=\"https://travis-ci.org/vodik/repose\"\u003e\n  \u003cimg alt=\"Travis CI Status\"\n       src=\"https://travis-ci.org/vodik/repose.png\"/\u003e\n\u003c/a\u003e\n\u003ca href=\"https://scan.coverity.com/projects/3577\"\u003e\n  \u003cimg alt=\"Coverity Scan Build Status\"\n       src=\"https://scan.coverity.com/projects/3577/badge.svg\"/\u003e\n\u003c/a\u003e\n\nOwning more than one Archlinux machine, I operate my own repository to\ndistribute customized and/or extra packages between the various\nmachines. `repo-add`, the provided tool for repository management, is\nfrustratingly limited. Updating the repository after building a series\nof packages quickly turned into a slow monstrous bash script: either I\nhad to have rather complex logic to figure out which packages are new,\nor I had to do the expensive operation of rebuilding the repository each\ntime. Surly, though, this was something that could be automated.\n\n`repose` is an Archlinux repository compiler.\n\nGenerally, it operates by building up two package caches: one that\nrepresents the contents of the database and another that represents the\nvarious packages sitting in the root directory of the database.\nUpdating, then, is simply a sync operation operation between the two.\n\nTo sync, it takes advantage of several rules of Archlinux repositories\nto automate as much logic as possible:\n\n1. Repositories typically only hold one version of a package (and we're\n   interesting in the newest version).\n2. Repositories typically only hold only one architecture.\n3. Repositories and packages are expected to be in the same directory.\n\n### Updating/Removing\n\nMost simplistically:\n\n    repose -z foo\n\n1. Parse the contents of `foo.db` if it exists.\n2. If we find a new package in the database's folder, add it to the\n   database.\n3. If we can't find a corresponding package to a database entry, remove\n   it from the database.\n4. Write out an updated database.\n\nTo explicitly remove a package:\n\n    repose -zd foo [pkgs]\n\nRemoves the specified packages from the database.\n\nTo generate a complementary `foo.files` file, add the `-f` flags\n\n    repose -zf foo\n\n### Globbing\n\nIts possible to use globbing. `repose` uses the following logic for\nfinding/filtering packages:\n\n1. Does it match the package's filename\n2. Does it match the package's name\n3. Does it glob pkgname-pkgver\n\nThis allows for operations like:\n\nAdd latest detected version `systemd` to a repo:\n\n    repose foo systemd\n\nAdd a specific version of `systemd` to a repo:\n\n    repose foo systemd-209-1\n\nDrop all git packages from the repo:\n\n    repose -zd foo '*-git-*'\n\n```\n     __\n    '. \\\n     '- \\\n      / /_         .---.\n     / | \\\\,.\\/--.//    )\n     |  \\//        )/  /\n      \\  ' ^ ^    /    )____.----..  6\n       '.____.    .___/            \\._)\n          .\\/.                      )\n           '\\                       /\n           _/ \\/    ).        )    (\n          /#  .!    |        /\\    /\n          \\  C// #  /'-----''/ #  /\n       .   'C/ |    |    |   |    |mrf  ,\n       \\), .. .'OOO-'. ..'OOO'OOO-'. ..\\(,\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvodik%2Frepose","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fvodik%2Frepose","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvodik%2Frepose/lists"}