{"id":13688416,"url":"https://github.com/replit/rippkgs","last_synced_at":"2026-04-02T18:38:07.725Z","repository":{"id":221779360,"uuid":"754721762","full_name":"replit/rippkgs","owner":"replit","description":"A CLI for indexing and searching packages in Nix expressions","archived":false,"fork":false,"pushed_at":"2025-05-17T04:12:44.000Z","size":134,"stargazers_count":163,"open_issues_count":7,"forks_count":5,"subscribers_count":20,"default_branch":"main","last_synced_at":"2026-02-02T02:58:50.599Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/replit.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":".github/CODEOWNERS","security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2024-02-08T16:38:09.000Z","updated_at":"2026-01-25T07:20:45.000Z","dependencies_parsed_at":"2024-06-05T17:12:27.385Z","dependency_job_id":"d6d395ba-84fa-4a44-92a1-e219fe075186","html_url":"https://github.com/replit/rippkgs","commit_stats":null,"previous_names":["cdmistman/rippkgs","replit/rippkgs"],"tags_count":5,"template":false,"template_full_name":null,"purl":"pkg:github/replit/rippkgs","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/replit%2Frippkgs","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/replit%2Frippkgs/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/replit%2Frippkgs/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/replit%2Frippkgs/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/replit","download_url":"https://codeload.github.com/replit/rippkgs/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/replit%2Frippkgs/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31313072,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-02T12:59:32.332Z","status":"ssl_error","status_checked_at":"2026-04-02T12:54:48.875Z","response_time":89,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: 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-08-02T15:01:13.265Z","updated_at":"2026-04-02T18:38:07.700Z","avatar_url":"https://github.com/replit.png","language":"Rust","funding_links":[],"categories":["Rust","Discovery"],"sub_categories":[],"readme":"# Rippkgs\n\nrippkgs is a search CLI utility for searching indexed nixpkgs expressions.\n\n## Usage\n\n### Installation\n\nOnce \u003chttps://github.com/NixOS/nixpkgs/pull/305125\u003e is merged, if you have the commit you can use install using your preferred way of installing nixpkgs derivations.\nFor example:\n```sh\n$ nix profile install nixpkgs#rippkgs nixpkgs#rippkgs-index\n# alternatively, via the flake directly\n$ nix profile install github:replit/rippkgs/v1.1.0\n```\n\nAlternatively, if you're using a flake to configure your system, you can add rippkgs via nixpkgs or as an input to your flake and add rippkgs to your environment packages.\nFor example, in NixOS:\n```nix\nenvironment.systemPackages = [\n  pkgs.rippkgs\n  pkgs.rippkgs-index\n  # alternatively, if via the flake input:\n  inputs.rippkgs.packages.${system}.rippkgs\n  inputs.rippkgs.packages.${system}.rippkgs-index\n];\n```\n\n### Generate an index\n\nGenerating an index may be done with the `rippkgs-index` cli:\n```sh\nrippkgs-index nixpkgs -o $XDG_DATA_HOME/rippkgs-index.sqlite\n```\n\nIf you don't have a `nixpkgs` channel set (or would prefer to index a different channel), you'll have to explicitly pass the dir to the nixpkgs distribution:\n```sh\nrippkgs-index nixpkgs -o $XDG_DATA_HOME/rippkgs-index.sqlite ~/.nix-defexpr/channels/my-very-special-nixpkgs-channel\n```\n\nAlternatively, you can generate a registry using the flake output `lib.genRegistry`, which allows you to avoid recursive-nix problems:\n```sh\n$ nix eval -L .#lib.genRegistry --apply 'f: f (import \u003cnixpkgs\u003e { })' --impure --json \u003eregistry.json\n$ rippkgs-index registry -o rippkgs-index.sqlite registry.json\n```\n\n### Searching\n\nUse the `rippkgs` cli to search for appropriate packages:\n```sh\nrippkgs rustc\n```\n\n## Comparison\n\n`nix-env -q` is historically the command that's used to achieve what rippkgs achieves, but the nix evaluation cost is high.\nWhen in an environment where reactiveness is desirable, it's better to pay the initial cost of generating the index (see results below).\n\n[`nix-index`](https://github.com/nix-community/nix-index) is similar in that it operates on a generated database,\nbut requires derivations to be built in order to generate the index, and not all package information is stored in the index.\nThis means you have to augment `nix-locate` results with `nix-env` in order to get additional information about a package, like its\nversion or the nixpkgs registry description for the package.\n\n\u003chttps://search.nixos.org\u003e is the closest approximate tool to rippkgs, but unfortunately it comes with a few shortcomings:\n1. The index only tracks up-to-date nixpkgs distributions, which means you *must* resort to `nix-env` to get results accurate to the nixpkgs release you're using.\n2. Search is only available as a web service with only HTML responses to its HTTP api, which means you have to parse the HTML response to your programmatic requests.\n3. It uses Elastic Search, which is fine for a widely-used service but doesn't work well when providing highly-localized results.\n\n## Performance\n\nUsing [nixpkgs@b550fe4b4776908ac2a861124307045f8e717c8e](https://github.com/NixOS/nixpkgs/tree/b550fe4b4776908ac2a861124307045f8e717c8e) on an aarch64-darwin with 16gb of memory:\n```sh\n$ time ./target/release/rippkgs-index nixpkgs -o nixpkgs.sqlite\nevaluated registry in 289.8638 seconds\nparsed registry in 0.0761 seconds\nwrote index in 0.1432 seconds\n./target/release/rippkgs-index nixpkgs -o nixpkgs.sqlite  108.35s user 45.50s system 53% cpu 4:50.20 total\n\n$ time ./target/release/rippkgs -i nixpkgs.sqlite rustc 1\u003e/dev/null\ngot results in 44 ms\n./target/release/rippkgs -i nixpkgs.sqlite rustc \u003e /dev/null  0.03s user 0.02s system 89% cpu 0.051 total\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Freplit%2Frippkgs","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Freplit%2Frippkgs","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Freplit%2Frippkgs/lists"}