Fix wine support
This commit is contained in:
1 file changed
+15
-1
@@ -38,7 +38,12 @@ export const handler = async (context: Context) => {
|
|||||||
} else if (platform == 'linux') {
|
} else if (platform == 'linux') {
|
||||||
if (arch == 'x86') platformsToShow = ['linux-x64']
|
if (arch == 'x86') platformsToShow = ['linux-x64']
|
||||||
else if (arch == 'x86_64' || arch == 'x64')
|
else if (arch == 'x86_64' || arch == 'x64')
|
||||||
platformsToShow = ['linux-x86', 'linux-x64']
|
platformsToShow = [
|
||||||
|
'linux-x86',
|
||||||
|
'linux-x64',
|
||||||
|
'windows-x86',
|
||||||
|
'windows-x64'
|
||||||
|
]
|
||||||
else if (arch == 'aarch64' || arch == 'arm64')
|
else if (arch == 'aarch64' || arch == 'arm64')
|
||||||
platformsToShow = ['linux-arm64']
|
platformsToShow = ['linux-arm64']
|
||||||
else {
|
else {
|
||||||
@@ -123,10 +128,13 @@ export const handler = async (context: Context) => {
|
|||||||
download = key
|
download = key
|
||||||
const idx = downloadKeys.indexOf(key)
|
const idx = downloadKeys.indexOf(key)
|
||||||
executable = executables[idx] ?? null
|
executable = executables[idx] ?? null
|
||||||
|
break
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
const isWine = download?.startsWith('windows') ?? false
|
||||||
|
|
||||||
const { versionName, ...rest } = v
|
const { versionName, ...rest } = v
|
||||||
return {
|
return {
|
||||||
...rest,
|
...rest,
|
||||||
@@ -137,6 +145,12 @@ export const handler = async (context: Context) => {
|
|||||||
? download
|
? download
|
||||||
? downloads[download]
|
? downloads[download]
|
||||||
: undefined
|
: undefined
|
||||||
|
: undefined,
|
||||||
|
wine:
|
||||||
|
platformsToShow &&
|
||||||
|
platform == 'linux' &&
|
||||||
|
download?.startsWith('windows')
|
||||||
|
? true
|
||||||
: undefined
|
: undefined
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|||||||
Reference in new issue
Block a user