Generate Nix packages from URLs
Note: It is likely that the generated package will not work without some tweaks, also remember to double check the license and description even if it does work
cargoHash
and vendorHash
The latest release of nix-init is packaged in nixpkgs and kept up to date on the unstable branches
If you want to use a more recent snapshot of nix-init, it is also available as a flake.
The following command is equivalent to running nix-init --help
:
bash
nix run github:nix-community/nix-init -- --help
or if you don't have flakes enabled:
bash
nix run --extra-experimental-features "flakes nix-command" github:nix-community/nix-init -- --help
``` Usage: nix-init [OPTIONS] [OUTPUT]
Arguments: [OUTPUT] The path or directory to output the generated file to
Options:
-u, --url
stdenv.mkDerivation
buildRustPackage
buildPythonApplication
and buildPythonPackage
buildGoModule
fetchCrate
fetchFromGitHub
fetchFromGitLab
fetchFromGitea
fetchPypi
nix-init will try to find nix-init/config.toml
under XDG configuration directories
```toml
maintainers = ["figsoda"]
--nixpkgs
nixpkgs = "
commit = true
[access-tokens] "github.com" = "ghp_blahblahblah..." "gitlab.com".command = ["secret-tool", "or", "whatever", "you", "use"] "gitlab.gnome.org".file = "/path/to/api/token" ```
See CHANGELOG.md