Skip to content

Commit

Permalink
updated HelmExecutionBuilder workingDirectory to use PWD instead of n…
Browse files Browse the repository at this point in the history
…ew File('.') from FileUtils

Signed-off-by: Jeromy Cannon <[email protected]>
  • Loading branch information
jeromy-cannon committed Sep 21, 2023
1 parent ebaf816 commit b70956c
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 65 deletions.

This file was deleted.

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@
package com.hedera.fullstack.helm.client.execution;

import com.hedera.fullstack.base.api.collections.KeyValuePair;
import com.hedera.fullstack.base.api.util.FileUtils;
import com.hedera.fullstack.helm.client.HelmConfigurationException;
import java.io.File;
import java.io.IOException;
import java.nio.file.Path;
import java.util.*;
Expand Down Expand Up @@ -83,10 +83,10 @@ public HelmExecutionBuilder(final Path helmExecutable) {
this.positionals = new ArrayList<>();
this.flags = new ArrayList<>();
this.environmentVariables = new HashMap<>();
this.workingDirectory = FileUtils.getWorkingPath();

// TODO: for workingDirectory use system environment pwd (if null: else helm executable path)
// System.getenv("PWD"), check for empty string or null
String workingDirectory = System.getenv("PWD");
this.workingDirectory =
workingDirectory == null ? this.helmExecutable.getParent() : new File(workingDirectory).toPath();
}

/**
Expand Down

0 comments on commit b70956c

Please sign in to comment.