All Projects → bennofs → Nix Index

bennofs / Nix Index

Licence: other
Quickly locate nix packages with specific files

Programming Languages

rust
11053 projects

Projects that are alternatives of or similar to Nix Index

easy-hls-nix
Easy Haskell Language Server tooling with Nix!
Stars: ✭ 56 (-71.57%)
Mutual labels:  nix, tooling
Naersk
Build rust crates in Nix. No configuration, no code generation, no IFD. Sandbox friendly.
Stars: ✭ 193 (-2.03%)
Mutual labels:  nix
Search Server
⭐️ Our core search API repository
Stars: ✭ 181 (-8.12%)
Mutual labels:  search
Nix Docker
Docker images for the Nix package manager
Stars: ✭ 189 (-4.06%)
Mutual labels:  nix
Comma
Stars: ✭ 186 (-5.58%)
Mutual labels:  nix
Rummage ecto
Search, Sort and Pagination for ecto queries
Stars: ✭ 190 (-3.55%)
Mutual labels:  search
Search Query Parser
A simple parser for advanced search query syntax
Stars: ✭ 180 (-8.63%)
Mutual labels:  search
Vectorai
Vector AI — A platform for building vector based applications. Encode, query and analyse data using vectors.
Stars: ✭ 195 (-1.02%)
Mutual labels:  search
Textrank
🌀 ⚡️ 🌍 TextRank (automatic text summarization) for PHP8
Stars: ✭ 193 (-2.03%)
Mutual labels:  search
Fuse
🔍 Fuzzy search for PHP based on the Bitap algorithm
Stars: ✭ 189 (-4.06%)
Mutual labels:  search
Voice Overlay Android
🗣 An overlay that gets your user’s voice permission and input as text in a customizable UI
Stars: ✭ 189 (-4.06%)
Mutual labels:  search
Atom Todo Show
Atom package that shows a list of todos from your project.
Stars: ✭ 186 (-5.58%)
Mutual labels:  search
Lolcate Rs
Lolcate -- A comically fast way of indexing and querying your filesystem. Replaces locate / mlocate / updatedb. Written in Rust.
Stars: ✭ 191 (-3.05%)
Mutual labels:  search
Phpgrep
Syntax-aware grep for PHP code.
Stars: ✭ 185 (-6.09%)
Mutual labels:  search
Emacs Overlay
Bleeding edge emacs overlay [[email protected]]
Stars: ✭ 194 (-1.52%)
Mutual labels:  nix
Tooling
🧰 Up-to-date list of JavaScript and TypeScript tooling resources
Stars: ✭ 181 (-8.12%)
Mutual labels:  tooling
Laravel Cross Eloquent Search
Laravel package to search through multiple Eloquent models. Supports sorting, pagination, scoped queries, eager load relationships and searching through single or multiple columns.
Stars: ✭ 189 (-4.06%)
Mutual labels:  search
Nixbox
NixOS Vagrant boxes [[email protected]]
Stars: ✭ 189 (-4.06%)
Mutual labels:  nix
Getting Started Nix Template
Based on nix.dev tutorials, repository template to get you started with Nix.
Stars: ✭ 196 (-0.51%)
Mutual labels:  nix
Vue Cool Select
Select with autocomplete, slots, bootstrap and material design themes.
Stars: ✭ 195 (-1.02%)
Mutual labels:  search

nix-index Build Status

A files database for nixpkgs

nix-index is a tool to quickly locate the package providing a certain file in nixpkgs. It indexes built derivations found in binary caches.

Demo
$ nix-locate 'bin/hello'
hello.out                                        29,488 x /nix/store/bdjyhh70npndlq3rzmggh4f2dzdsj4xy-hello-2.10/bin/hello
linuxPackages_4_4.dpdk.examples               2,022,224 x /nix/store/jlnk3d38zsk0bp02rp9skpqk4vjfijnn-dpdk-16.07.2-4.4.52-examples/bin/helloworld
linuxPackages.dpdk.examples                   2,022,224 x /nix/store/rzx4k0pb58gd1dr9kzwam3vk9r8bfyv1-dpdk-16.07.2-4.9.13-examples/bin/helloworld
linuxPackages_4_10.dpdk.examples              2,022,224 x /nix/store/wya1b0910qidfc9v3i6r9rnbnc9ykkwq-dpdk-16.07.2-4.10.1-examples/bin/helloworld
linuxPackages_grsec_nixos.dpdk.examples       2,022,224 x /nix/store/2wqv94290pa38aclld7sc548a7hnz35k-dpdk-16.07.2-4.9.13-examples/bin/helloworld
camlistore.out                                7,938,952 x /nix/store/xn5ivjdyslxldhm5cb4x0lfz48zf21rl-camlistore-0.9/bin/hello

Installation

Latest Git version

To install the latest development version of nix-index, simply clone the repo and run nix-env -if.:

$ git clone https://github.com/bennofs/nix-index
$ cd nix-index
$ nix-env -if.

Stable

For the stable version, you can either checkout the latest tag (see the list here) or use Nixpkgs' repositories' and install it with:

$ nix-env -iA nixos.nix-index

Usage

First, you need to generate an index by running nix-index (it takes around 5 minutes) . Then, you can use nix-locate pattern. For more information, see nix-locate --help and nix-index --help.

Usage as a command-not-found replacement

Nix-index provides a "command-not-found" script that can print for you the attribute path of unfound commands in your shell. You can either source ${pkgs.nix-index}/etc/command-not-found.sh in your own shell init files (works for ZSH and Bash for as far as we know) or you can use the following in home-manager / /etc/nixos/configuration.nix:

    programs.command-not-found.enable = false;
    programs.bash.interactiveShellInit = ''
      source ${pkgs.nix-index}/etc/profile.d/command-not-found.sh
    '';

Replace bash with zsh if you use zsh.

Example output:

$ blender
The program 'blender' is currently not installed. You can install it
by typing:
  nix-env -iA nixpkgs.blender.out

Contributing

If you find any missing features that you would like to implement, I'm very happy about any PRs! You can also create an issue first if the feature is more complex so we can discuss possible implementations.

Here is a quick description of all relevant files:

  • bin/{nix-index, nix-locate}.rs: Implementation of the nix-index / nix-locate command line tools
  • src/database.rs: High-level functions for working with the database format
  • src/files.rs: The data types for working with file listings
  • src/frcode.rs: Low-level implementation of an encoder to efficiently store many file paths (see comments in the file for more details). Used by database.rs.
  • src/hydra.rs: Deals with everything that has to do with downloading from the binary cache (fetching file listings and references)
  • src/nixpkgs.rs: Implements the gathering of the packages (store paths and attributes) using nix-env
  • src/package.rs: High-level data types for representing store paths (sometimes also refered to as a package)
  • src/workset.rs: A queue used by nix-index to implement the recursive fetching (fetching references of everything)
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].