fix: build on linux
This commit is contained in:
8
.github/workflows/main.yml
vendored
8
.github/workflows/main.yml
vendored
@@ -18,10 +18,10 @@ jobs:
|
||||
args: "--target x86_64-apple-darwin"
|
||||
- platform: "macos-latest" # for Intel based macs.
|
||||
args: "--target universal-apple-darwin"
|
||||
#- platform: 'ubuntu-22.04'
|
||||
# args: ''
|
||||
#- platform: 'windows-latest'
|
||||
# args: '--target x86_64-pc-windows-msvc'
|
||||
- platform: 'ubuntu-22.04'
|
||||
args: ''
|
||||
- platform: 'windows-latest'
|
||||
args: '--target x86_64-pc-windows-msvc'
|
||||
runs-on: ${{ matrix.platform }}
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
|
||||
@@ -198,7 +198,7 @@ pub fn open_window(window: Window, app_handle: tauri::AppHandle) -> Result<(), S
|
||||
&window.label,
|
||||
WebviewUrl::App(PathBuf::from(window.url)),
|
||||
)
|
||||
.title(title)
|
||||
.title(&window.title)
|
||||
.min_inner_size(window.width, window.height)
|
||||
.inner_size(window.width, window.height)
|
||||
.minimizable(window.minimizable)
|
||||
@@ -218,7 +218,7 @@ pub fn open_window(window: Window, app_handle: tauri::AppHandle) -> Result<(), S
|
||||
&window.label,
|
||||
WebviewUrl::App(PathBuf::from(window.url)),
|
||||
)
|
||||
.title(title)
|
||||
.title(&window.title)
|
||||
.min_inner_size(window.width, window.height)
|
||||
.inner_size(window.width, window.height)
|
||||
.minimizable(window.minimizable)
|
||||
@@ -227,6 +227,7 @@ pub fn open_window(window: Window, app_handle: tauri::AppHandle) -> Result<(), S
|
||||
.unwrap();
|
||||
|
||||
// Set decoration
|
||||
#[cfg(not(target_os = "linux"))]
|
||||
window.create_overlay_titlebar().unwrap();
|
||||
|
||||
// Restore native border
|
||||
|
||||
@@ -140,7 +140,13 @@ fn main() {
|
||||
builder.build().unwrap()
|
||||
};
|
||||
|
||||
tauri::Builder::default()
|
||||
#[cfg(target_os = "macos")]
|
||||
let builder = tauri::Builder::default().plugin(tauri_nspanel::init());
|
||||
|
||||
#[cfg(not(target_os = "macos"))]
|
||||
let builder = tauri::Builder::default();
|
||||
|
||||
builder
|
||||
.setup(|app| {
|
||||
#[cfg(target_os = "macos")]
|
||||
app.handle().plugin(tauri_nspanel::init()).unwrap();
|
||||
@@ -239,8 +245,6 @@ fn main() {
|
||||
|
||||
Ok(())
|
||||
})
|
||||
.enable_macos_default_menu(false)
|
||||
.plugin(tauri_nspanel::init())
|
||||
.plugin(tauri_plugin_theme::init(ctx.config_mut()))
|
||||
.plugin(tauri_plugin_decorum::init())
|
||||
.plugin(tauri_plugin_clipboard_manager::init())
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
#[cfg(target_os = "macos")]
|
||||
use crate::commands::tray::create_tray_panel;
|
||||
use crate::nostr::event::RichEvent;
|
||||
use crate::nostr::internal::{get_user_settings, init_nip65};
|
||||
|
||||
@@ -1,131 +1,116 @@
|
||||
{
|
||||
"$schema": "../node_modules/@tauri-apps/cli/schema.json",
|
||||
"productName": "Lume",
|
||||
"version": "4.0.14",
|
||||
"identifier": "nu.lume.Lume",
|
||||
"build": {
|
||||
"beforeBuildCommand": "pnpm desktop:build",
|
||||
"beforeDevCommand": "pnpm desktop:dev",
|
||||
"devUrl": "http://localhost:3000",
|
||||
"frontendDist": "../dist"
|
||||
},
|
||||
"app": {
|
||||
"macOSPrivateApi": true,
|
||||
"withGlobalTauri": true,
|
||||
"security": {
|
||||
"assetProtocol": {
|
||||
"enable": true,
|
||||
"scope": [
|
||||
"$APPDATA/*",
|
||||
"$DATA/*",
|
||||
"$LOCALDATA/*",
|
||||
"$DESKTOP/*",
|
||||
"$DOCUMENT/*",
|
||||
"$DOWNLOAD/*",
|
||||
"$HOME/*",
|
||||
"$PICTURE/*",
|
||||
"$PUBLIC/*",
|
||||
"$VIDEO/*",
|
||||
"$APPCONFIG/*",
|
||||
"$RESOURCE/*"
|
||||
]
|
||||
}
|
||||
}
|
||||
},
|
||||
"bundle": {
|
||||
"licenseFile": "../LICENSE",
|
||||
"homepage": "https://lume.nu",
|
||||
"longDescription": "nostr client for desktop",
|
||||
"shortDescription": "nostr client",
|
||||
"targets": "all",
|
||||
"active": true,
|
||||
"category": "SocialNetworking",
|
||||
"resources": [
|
||||
"resources/*",
|
||||
"locales/*"
|
||||
],
|
||||
"icon": [
|
||||
"icons/32x32.png",
|
||||
"icons/128x128.png",
|
||||
"icons/128x128@2x.png",
|
||||
"icons/icon.icns",
|
||||
"icons/icon.ico"
|
||||
],
|
||||
"linux": {
|
||||
"appimage": {
|
||||
"bundleMediaFramework": true,
|
||||
"files": {}
|
||||
},
|
||||
"deb": {
|
||||
"files": {}
|
||||
},
|
||||
"rpm": {
|
||||
"epoch": 0,
|
||||
"files": {},
|
||||
"release": "1"
|
||||
}
|
||||
},
|
||||
"macOS": {
|
||||
"dmg": {
|
||||
"appPosition": {
|
||||
"x": 180,
|
||||
"y": 170
|
||||
},
|
||||
"applicationFolderPosition": {
|
||||
"x": 480,
|
||||
"y": 170
|
||||
},
|
||||
"windowSize": {
|
||||
"height": 400,
|
||||
"width": 660
|
||||
}
|
||||
},
|
||||
"files": {},
|
||||
"minimumSystemVersion": "10.15"
|
||||
},
|
||||
"windows": {
|
||||
"allowDowngrades": true,
|
||||
"certificateThumbprint": null,
|
||||
"digestAlgorithm": "sha256",
|
||||
"nsis": null,
|
||||
"timestampUrl": null,
|
||||
"tsp": false,
|
||||
"webviewFixedRuntimePath": null,
|
||||
"webviewInstallMode": {
|
||||
"silent": true,
|
||||
"type": "downloadBootstrapper"
|
||||
},
|
||||
"wix": null
|
||||
},
|
||||
"fileAssociations": [
|
||||
{
|
||||
"name": "bech32",
|
||||
"description": "Nostr BECH32",
|
||||
"ext": [
|
||||
"npub",
|
||||
"nsec",
|
||||
"nprofile",
|
||||
"nevent",
|
||||
"naddr",
|
||||
"nrelay"
|
||||
],
|
||||
"role": "Viewer"
|
||||
}
|
||||
],
|
||||
"createUpdaterArtifacts": true
|
||||
},
|
||||
"plugins": {
|
||||
"updater": {
|
||||
"active": true,
|
||||
"pubkey": "dW50cnVzdGVkIGNvbW1lbnQ6IG1pbmlzaWduIHB1YmxpYyBrZXk6IEU3OTdCMkM3RjU5QzE2NzkKUldSNUZwejF4N0tYNTVHYjMrU0JkL090SlEyNUVLYU5TM2hTU3RXSWtEWngrZWJ4a0pydUhXZHEK",
|
||||
"windows": {
|
||||
"installMode": "quiet"
|
||||
},
|
||||
"endpoints": [
|
||||
"https://lus.reya3772.workers.dev/v1/{{target}}/{{arch}}/{{current_version}}",
|
||||
"https://lus.reya3772.workers.dev/{{target}}/{{current_version}}",
|
||||
"https://github.com/lumehq/lume/releases/latest/download/latest.json"
|
||||
]
|
||||
}
|
||||
}
|
||||
"$schema": "../node_modules/@tauri-apps/cli/schema.json",
|
||||
"productName": "Lume",
|
||||
"version": "4.0.14",
|
||||
"identifier": "nu.lume.Lume",
|
||||
"build": {
|
||||
"beforeBuildCommand": "pnpm desktop:build",
|
||||
"beforeDevCommand": "pnpm desktop:dev",
|
||||
"devUrl": "http://localhost:3000",
|
||||
"frontendDist": "../dist"
|
||||
},
|
||||
"app": {
|
||||
"macOSPrivateApi": true,
|
||||
"withGlobalTauri": true,
|
||||
"security": {
|
||||
"assetProtocol": {
|
||||
"enable": true,
|
||||
"scope": [
|
||||
"$APPDATA/*",
|
||||
"$DATA/*",
|
||||
"$LOCALDATA/*",
|
||||
"$DESKTOP/*",
|
||||
"$DOCUMENT/*",
|
||||
"$DOWNLOAD/*",
|
||||
"$HOME/*",
|
||||
"$PICTURE/*",
|
||||
"$PUBLIC/*",
|
||||
"$VIDEO/*",
|
||||
"$APPCONFIG/*",
|
||||
"$RESOURCE/*"
|
||||
]
|
||||
}
|
||||
}
|
||||
},
|
||||
"bundle": {
|
||||
"licenseFile": "../LICENSE",
|
||||
"homepage": "https://lume.nu",
|
||||
"longDescription": "nostr client for desktop",
|
||||
"shortDescription": "nostr client",
|
||||
"targets": "all",
|
||||
"active": true,
|
||||
"category": "SocialNetworking",
|
||||
"resources": [
|
||||
"resources/*",
|
||||
"locales/*"
|
||||
],
|
||||
"icon": [
|
||||
"icons/32x32.png",
|
||||
"icons/128x128.png",
|
||||
"icons/128x128@2x.png",
|
||||
"icons/icon.icns",
|
||||
"icons/icon.ico"
|
||||
],
|
||||
"linux": {
|
||||
"appimage": {
|
||||
"bundleMediaFramework": true,
|
||||
"files": {}
|
||||
},
|
||||
"deb": {
|
||||
"files": {}
|
||||
},
|
||||
"rpm": {
|
||||
"epoch": 0,
|
||||
"files": {},
|
||||
"release": "1"
|
||||
}
|
||||
},
|
||||
"macOS": {
|
||||
"minimumSystemVersion": "10.15"
|
||||
},
|
||||
"windows": {
|
||||
"allowDowngrades": true,
|
||||
"certificateThumbprint": null,
|
||||
"digestAlgorithm": "sha256",
|
||||
"nsis": null,
|
||||
"timestampUrl": null,
|
||||
"tsp": false,
|
||||
"webviewFixedRuntimePath": null,
|
||||
"webviewInstallMode": {
|
||||
"silent": true,
|
||||
"type": "downloadBootstrapper"
|
||||
},
|
||||
"wix": null
|
||||
},
|
||||
"fileAssociations": [
|
||||
{
|
||||
"name": "bech32",
|
||||
"description": "Nostr BECH32",
|
||||
"ext": [
|
||||
"npub",
|
||||
"nsec",
|
||||
"nprofile",
|
||||
"nevent",
|
||||
"naddr",
|
||||
"nrelay"
|
||||
],
|
||||
"role": "Viewer"
|
||||
}
|
||||
],
|
||||
"createUpdaterArtifacts": true
|
||||
},
|
||||
"plugins": {
|
||||
"updater": {
|
||||
"active": true,
|
||||
"pubkey": "dW50cnVzdGVkIGNvbW1lbnQ6IG1pbmlzaWduIHB1YmxpYyBrZXk6IEU3OTdCMkM3RjU5QzE2NzkKUldSNUZwejF4N0tYNTVHYjMrU0JkL090SlEyNUVLYU5TM2hTU3RXSWtEWngrZWJ4a0pydUhXZHEK",
|
||||
"windows": {
|
||||
"installMode": "quiet"
|
||||
},
|
||||
"endpoints": [
|
||||
"https://lus.reya3772.workers.dev/v1/{{target}}/{{arch}}/{{current_version}}",
|
||||
"https://lus.reya3772.workers.dev/{{target}}/{{current_version}}",
|
||||
"https://github.com/lumehq/lume/releases/latest/download/latest.json"
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user