diff --git a/README.md b/README.md index a9fe503..4a9b2f6 100644 --- a/README.md +++ b/README.md @@ -258,41 +258,6 @@ nix_direnv_watch_file mod1.nix mod2.nix use flake ``` -## Shell integration - -To quickly add a `default.nix`/`flake.nix` to a project you can put the following snippets in your `.bashrc`/`.zshrc`: - -```bash -nixify() { - if [ ! -e ./.envrc ]; then - echo "use nix" > .envrc - direnv allow - fi - if [[ ! -e shell.nix ]] && [[ ! -e default.nix ]]; then - cat > default.nix <<'EOF' -with import {}; -mkShell { - nativeBuildInputs = [ - bashInteractive - ]; -} -EOF - ${EDITOR:-vim} default.nix - fi -} - -flakify() { - if [ ! -e flake.nix ]; then - nix flake new -t github:nix-community/nix-direnv . - elif [ ! -e .envrc ]; then - echo "use flake" > .envrc - direnv allow - fi - ${EDITOR:-vim} flake.nix -} - -``` - ## Known Bugs At the moment `nix-direnv` depends on GNU Grep and a modern Bash version.