(userPath: string)
| 18 | * A simple function for resolving the path the user entered |
| 19 | */ |
| 20 | export function resolveEnvFilePath(userPath: string): string { |
| 21 | // Make sure a home directory exist |
| 22 | const home = homedir() as string | undefined |
| 23 | if (home != null) { |
| 24 | userPath = userPath.replace(/^~($|\/|\\)/, `${home}$1`) |
| 25 | } |
| 26 | return resolve(cwd(), userPath) |
| 27 | } |
| 28 | /** |
| 29 | * A simple function that parses a comma separated string into an array of strings |
| 30 | */ |
no outgoing calls
no test coverage detected