mirror of
https://github.com/nix-community/nix-direnv.git
synced 2025-11-08 19:46:11 +01:00
Merge pull request #565 from synalice/patch-2
Fix dollar sign usage before commands without showing output in README
This commit is contained in:
commit
f3ac1c2799
1 changed files with 14 additions and 14 deletions
28
README.md
28
README.md
|
|
@ -158,9 +158,9 @@ pkgs.mkShell {
|
||||||
|
|
||||||
Then add the line `use nix` to your envrc:
|
Then add the line `use nix` to your envrc:
|
||||||
|
|
||||||
```console
|
```shell
|
||||||
$ echo "use nix" >> .envrc
|
echo "use nix" >> .envrc
|
||||||
$ direnv allow
|
direnv allow
|
||||||
```
|
```
|
||||||
|
|
||||||
If you haven't used direnv before, make sure to
|
If you haven't used direnv before, make sure to
|
||||||
|
|
@ -171,8 +171,8 @@ If you haven't used direnv before, make sure to
|
||||||
You may use a different file name than `shell.nix` or `default.nix` by passing
|
You may use a different file name than `shell.nix` or `default.nix` by passing
|
||||||
the file name in `.envrc`, e.g.:
|
the file name in `.envrc`, e.g.:
|
||||||
|
|
||||||
```console
|
```shell
|
||||||
$ echo "use nix foo.nix" >> .envrc
|
echo "use nix foo.nix" >> .envrc
|
||||||
```
|
```
|
||||||
|
|
||||||
## Flakes support
|
## Flakes support
|
||||||
|
|
@ -192,14 +192,14 @@ which provides a basic flake with devShell integration and a basic `.envrc`.
|
||||||
|
|
||||||
To make use of this template, you may issue the following command:
|
To make use of this template, you may issue the following command:
|
||||||
|
|
||||||
```console
|
```shell
|
||||||
$ nix flake new -t github:nix-community/nix-direnv <desired output path>
|
nix flake new -t github:nix-community/nix-direnv <desired output path>
|
||||||
```
|
```
|
||||||
|
|
||||||
### Integrating with a existing flake
|
### Integrating with a existing flake
|
||||||
|
|
||||||
```console
|
```shell
|
||||||
$ echo "use flake" >> .envrc && direnv allow
|
echo "use flake" >> .envrc && direnv allow
|
||||||
```
|
```
|
||||||
|
|
||||||
The `use flake` line also takes an additional arbitrary flake parameter, so you
|
The `use flake` line also takes an additional arbitrary flake parameter, so you
|
||||||
|
|
@ -224,9 +224,9 @@ that the environment of the calling shell is passed in.
|
||||||
|
|
||||||
You can do that as follows:
|
You can do that as follows:
|
||||||
|
|
||||||
```console
|
```shell
|
||||||
$ echo "use flake . --impure" > .envrc
|
echo "use flake . --impure" > .envrc
|
||||||
$ direnv allow
|
direnv allow
|
||||||
```
|
```
|
||||||
|
|
||||||
#### use nix
|
#### use nix
|
||||||
|
|
@ -256,8 +256,8 @@ use nix # or use flake
|
||||||
|
|
||||||
To reload your nix environment, use the `nix-direnv-reload` command:
|
To reload your nix environment, use the `nix-direnv-reload` command:
|
||||||
|
|
||||||
```console
|
```shell
|
||||||
$ nix-direnv-reload
|
nix-direnv-reload
|
||||||
```
|
```
|
||||||
|
|
||||||
##### Known arguments
|
##### Known arguments
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue