diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 6e8d780..a4a6c5a 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -1,7 +1,7 @@ # Setting up a devenv 1. Install [nix](https://github.com/DeterminateSystems/nix-installer) (or install the required dependencies yourself, but for e.g. tests, there are a lot) -2. Install direnv (optional, recommended for ease of use) +2. Install [direnv](https://direnv.net/) (optional, recommended for ease of use) 3. Run `direnv allow` / `nix develop --impure` ### Tests diff --git a/devenv-test.nix b/devenv-test.nix index 0afab94..7829174 100644 --- a/devenv-test.nix +++ b/devenv-test.nix @@ -22,6 +22,7 @@ sbt go-task cargo-make + jbang #handled by `languages` above: # python3 @@ -32,5 +33,6 @@ env = { NODE_HOME = "${pkgs.nodejs}"; # JAVA_HOME = "${pkgs.adoptopenjdk-jre-bin.home}"; - seems to be handled by languages.java + JBANG_HOME = "${pkgs.jbang}/bin"; }; } diff --git a/src/polyglot/sdkman.rs b/src/polyglot/sdkman.rs index 73ec7ab..d8bf8b4 100644 --- a/src/polyglot/sdkman.rs +++ b/src/polyglot/sdkman.rs @@ -61,8 +61,8 @@ mod tests { #[test] fn test_init_env() { init_env(); - println!("JAVA_HOME: {}", env::var("JAVA_HOME").unwrap()); - println!("JBANG_HOME: {}", env::var("JBANG_HOME").unwrap()); - println!("PATH: {}", env::var("PATH").unwrap()); + println!("JAVA_HOME: {}", env::var("JAVA_HOME").expect("env: JAVA_HOME")); + println!("JBANG_HOME: {}", env::var("JBANG_HOME").expect("env: JBANG_HOME")); + println!("PATH: {}", env::var("PATH").expect("env: PATH")); } }