add csv agent

This commit is contained in:
Henry
2023-07-22 01:16:23 +01:00
parent c8223d5273
commit 49c7ae718f
5 changed files with 192 additions and 0 deletions
+14
View File
@@ -377,3 +377,17 @@ export const availableDependencies = [
'typeorm',
'weaviate-ts-client'
]
export const getUserHome = (): string => {
let variableName = 'HOME'
if (process.platform === 'win32') {
variableName = 'USERPROFILE'
}
if (process.env[variableName] === undefined) {
// If for some reason the variable does not exist
// fall back to current folder
return process.cwd()
}
return process.env[variableName] as string
}