Open auth in browser fallback for Linux
This commit is contained in:
1 parent
58933b301d
commit
093127e131
1 file changed
+1
-1
@@ -13,7 +13,7 @@ actual fun openInBrowser(url: Url) {
|
|||||||
}
|
}
|
||||||
val desktop = Desktop.getDesktop()
|
val desktop = Desktop.getDesktop()
|
||||||
if (!desktop.isSupported(Desktop.Action.BROWSE)) {
|
if (!desktop.isSupported(Desktop.Action.BROWSE)) {
|
||||||
// TODO check if Linux -> run xdg-open $url
|
// fallback for Linux (tested only on Debian 13)
|
||||||
if (System.getProperty("os.name").lowercase(Locale.getDefault()).contains("linux")) {
|
if (System.getProperty("os.name").lowercase(Locale.getDefault()).contains("linux")) {
|
||||||
// throws at error - that's all that matters here
|
// throws at error - that's all that matters here
|
||||||
ExecutionResult(listOf("xdg-open", url.toString()))
|
ExecutionResult(listOf("xdg-open", url.toString()))
|
||||||
|
|||||||
Reference in new issue
Block a user