Import AITURK IDE 1.0.0-beta.1 from Hermes 63279301; preserve MIT license
This commit is contained in:
@@ -0,0 +1,27 @@
|
||||
import path from 'node:path'
|
||||
|
||||
export const AITURK_PRODUCT = Object.freeze({
|
||||
name: 'AITURK IDE',
|
||||
appId: 'online.turkservis.aiturk.hermes',
|
||||
protocol: 'aiturk-ide',
|
||||
website: 'https://turkservis.online',
|
||||
downloads: 'https://turkservis.online/ide',
|
||||
repository: 'https://gitea.twinpay.one/yilsem/aiturk-hermes-ide',
|
||||
apiBaseUrl: 'https://ai.turkservis.online/v1'
|
||||
})
|
||||
|
||||
/** Never inherit another product's HERMES_HOME or migrate its state implicitly. */
|
||||
export function resolveAiturkHome({ env, platform, home, userDataOverride }: {
|
||||
env: Record<string, string | undefined>
|
||||
platform: string
|
||||
home: string
|
||||
userDataOverride?: string
|
||||
}): string {
|
||||
const paths = platform === 'win32' ? path.win32 : path.posix
|
||||
if (env.AITURK_IDE_HOME) return paths.resolve(env.AITURK_IDE_HOME)
|
||||
if (userDataOverride) return paths.join(paths.resolve(userDataOverride), 'agent-home')
|
||||
if (platform === 'win32' && env.LOCALAPPDATA) {
|
||||
return paths.join(env.LOCALAPPDATA, 'TurkServis', 'AITURK-IDE', 'agent')
|
||||
}
|
||||
return paths.join(home, '.aiturk-ide', 'agent')
|
||||
}
|
||||
Reference in New Issue
Block a user