mirror of
https://github.com/numtide/devshell.git
synced 2024-09-19 09:27:21 +03:00
18 lines
418 B
Bash
18 lines
418 B
Bash
#!/usr/bin/env bash
|
|
# ^ added for shellcheck and file-type detection
|
|
|
|
# Watch all of these files for change
|
|
watch_dir modules
|
|
watch_dir nix
|
|
watch_file devshell.toml
|
|
|
|
# Store the shell symlink in the direnv layout directory
|
|
out_link="$(direnv_layout_dir)"/devshell
|
|
|
|
# Build the devshell environment
|
|
nix-build shell.nix --out-link "$out_link"
|
|
|
|
# Load the devshell
|
|
# shellcheck disable=SC1091
|
|
source "$out_link/env.bash"
|