diff options
author | Valentin Gagarin <valentin.gagarin@tweag.io> | 2023-09-25 17:00:55 +0200 |
---|---|---|
committer | fricklerhandwerk <valentin@fricklerhandwerk.de> | 2023-09-25 17:00:55 +0200 |
commit | fba19509b1ebed5a341494d9e501cc4cf7a7fb59 (patch) | |
tree | 84ebc06f881ce46672e5860d404b83fa5c4b0209 /doc/languages-frameworks | |
parent | 370097ce864f731c6e281ab3970cef1b39dfa06f (diff) | |
download | nixlib-fba19509b1ebed5a341494d9e501cc4cf7a7fb59.tar nixlib-fba19509b1ebed5a341494d9e501cc4cf7a7fb59.tar.gz nixlib-fba19509b1ebed5a341494d9e501cc4cf7a7fb59.tar.bz2 nixlib-fba19509b1ebed5a341494d9e501cc4cf7a7fb59.tar.lz nixlib-fba19509b1ebed5a341494d9e501cc4cf7a7fb59.tar.xz nixlib-fba19509b1ebed5a341494d9e501cc4cf7a7fb59.tar.zst nixlib-fba19509b1ebed5a341494d9e501cc4cf7a7fb59.zip |
use `nix-shell -p` for `dhall-to-nixpkgs` example
Diffstat (limited to 'doc/languages-frameworks')
-rw-r--r-- | doc/languages-frameworks/dhall.section.md | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/doc/languages-frameworks/dhall.section.md b/doc/languages-frameworks/dhall.section.md index 1a209dbc0680..7322a61687dd 100644 --- a/doc/languages-frameworks/dhall.section.md +++ b/doc/languages-frameworks/dhall.section.md @@ -303,11 +303,8 @@ You can use the `dhall-to-nixpkgs` command-line utility to automate packaging Dhall code. For example: ```ShellSession -$ nix-env --install --attr haskellPackages.dhall-nixpkgs - -$ nix-env --install --attr nix-prefetch-git # Used by dhall-to-nixpkgs - -$ dhall-to-nixpkgs github https://github.com/Gabriella439/dhall-semver.git +$ nix-shell -p haskellPackages.dhall-nixpkgs nix-prefetch-git +[nix-shell]$ dhall-to-nixpkgs github https://github.com/Gabriella439/dhall-semver.git { buildDhallGitHubPackage, Prelude }: buildDhallGitHubPackage { name = "dhall-semver"; @@ -325,6 +322,10 @@ $ dhall-to-nixpkgs github https://github.com/Gabriella439/dhall-semver.git } ``` +:::{.note} +`nix-prefetch-git` has to be in `$PATH` for `dhall-to-nixpkgs` to work. +::: + The utility takes care of automatically detecting remote imports and converting them to package dependencies. You can also use the utility on local Dhall directories, too: |