Skip to main content
Module

x/dax/mod.ts>CommandBuilder#exportEnv

Cross platform shell tools for Deno inspired by zx.
Very Popular
Go to Latest
method CommandBuilder.prototype.exportEnv
Re-export
import { CommandBuilder } from "https://deno.land/x/dax@0.31.0/mod.ts";

Exports the environment of the command to the executing process.

So for example, changing the directory in a command or exporting an environment variable will actually change the environment of the executing process.

await $`cd src && export SOME_VALUE=5`;
console.log(Deno.env.get("SOME_VALUE")); // 5
console.log(Deno.cwd()); // will be in the src directory

Parameters

optional
value = [UNSUPPORTED]