Skip to content

Commit

Permalink
Try to lower log output a bit
Browse files Browse the repository at this point in the history
  • Loading branch information
anthonychu committed May 25, 2020
1 parent c35d2e6 commit cbe4d19
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions denofunc.ts
Original file line number Diff line number Diff line change
Expand Up @@ -122,9 +122,13 @@ async function generateFunctions() {

async function runFunc(...args: string[]) {
let cmd = ["func", ...args];
const env = {
"logging__logLevel__Microsoft": "warning",
"logging__logLevel__Worker": "warning"
};
try {
console.info(`Running Azure Functions Core Tools: ${cmd.join(" ")}`);
const proc = Deno.run({ cmd });
const proc = Deno.run({ cmd, env });
await proc.status();
} catch (ex) {
if (Deno.build.os === "windows") {
Expand All @@ -140,7 +144,7 @@ async function runFunc(...args: string[]) {
if (funcPath) {
cmd = [funcPath, ...args];
console.info(`Running Azure Functions Core Tools: ${cmd.join(" ")}`);
const proc = Deno.run({ cmd });
const proc = Deno.run({ cmd, env });
await proc.status();
} else {
throw "Could not located func. Please ensure it is installed and in the path.";
Expand Down

0 comments on commit cbe4d19

Please sign in to comment.