addToPATHIfAbsent method

  1. @Deprecated('Use appendToPATH')
void addToPATHIfAbsent(
  1. String newPath
)

Adds newPath to the PATH environment variable if it is not already present.

The newPath will be added to the end of the PATH list.

Changing the PATH has no affect on the parent process (shell) that launched this script.

Changing the PATH affects the current script and any children that it spawns.

Implementation

@Deprecated('Use appendToPATH')
void addToPATHIfAbsent(String newPath) => appendToPATH(newPath);