mirror of
https://github.com/nix-community/comma.git
synced 2024-10-26 05:58:05 +03:00
Comma runs software without installing it. [maintainers=@Artturin,@burke,@DavHau]
646e6ed37b
When using a non-standard database location for nix-index (e.g. via the NixOS modules in the github:Mic92/nix-index-database flake), comma warns that the database is non-existent even though it does exist and nix-locate works fine. This changes the logic so that it only checks if the database exists when the `nix-locate` command fails. |
||
---|---|---|
.github | ||
src | ||
.envrc | ||
.gitignore | ||
Cargo.lock | ||
Cargo.toml | ||
default.nix | ||
flake.lock | ||
flake.nix | ||
README.md | ||
release.sh | ||
shell.nix |
comma
Comma runs software without installing it.
Basically it just wraps together nix shell -c
and nix-index
. You stick a ,
in front of a command to
run it from whatever location it happens to occupy in nixpkgs
without really thinking about it.
Installation
-
Nix with Flakes:
$ nix profile install github:nix-community/comma
-
No flakes:
$ nix-env -i -f "https://github.com/nix-community/comma/archive/master.tar.gz"
NixOS installation
-
No flakes:
replace "v1.2.0" with the latest version
environment.systemPackages = let comma = (import (pkgs.fetchFromGitHub { owner = "nix-community"; repo = "comma"; rev = "v1.2.0"; sha256 = "0000000000000000000000000000000000000000000000000000"; })).default; in [ comma ];
Usage
, cowsay neato