added tauri updater

This commit is contained in:
Ren Amamiya 2023-04-19 10:13:34 +07:00
parent a92d6158ce
commit 5ba4a1fa3b
7 changed files with 146 additions and 32 deletions

View File

@ -33,7 +33,7 @@
"jotai": "^2.0.4",
"next": "13.3.1-canary.14",
"nostr-relaypool": "^0.5.18",
"nostr-tools": "^1.9.0",
"nostr-tools": "^1.10.0",
"react": "^18.2.0",
"react-dom": "^18.2.0",
"react-hook-form": "^7.43.9",

View File

@ -39,7 +39,7 @@ specifiers:
lint-staged: ^13.2.1
next: 13.3.1-canary.14
nostr-relaypool: ^0.5.18
nostr-tools: ^1.9.0
nostr-tools: ^1.10.0
postcss: ^8.4.22
prettier: ^2.8.7
prettier-plugin-tailwindcss: ^0.2.7
@ -77,7 +77,7 @@ dependencies:
jotai: 2.0.4_react@18.2.0
next: 13.3.1-canary.14_biqbaboplfbrettd7655fr4n2y
nostr-relaypool: 0.5.18_ws@8.13.0
nostr-tools: 1.9.0
nostr-tools: 1.10.0
react: 18.2.0
react-dom: 18.2.0_react@18.2.0
react-hook-form: 7.43.9_react@18.2.0
@ -521,16 +521,14 @@ packages:
dev: false
optional: true
/@noble/curves/1.0.0:
/@noble/hashes/1.2.0:
resolution:
{ integrity: sha512-2upgEu0iLiDVDZkNLeFV2+ht0BAVgQnEmCk6JsOch9Rp8xfkMCbvbAZlA2pBHQc73dbl+vFOXfqkf4uemdn0bw== }
dependencies:
'@noble/hashes': 1.3.0
{ integrity: sha512-FZfhjEDbT5GRswV3C6uvLPHMiVD6lQBmpoX5+eSiPaMTXte/IKqI5dykDxzZB/WBeK/CDuQRBWarPdi3FNY2zQ== }
dev: false
/@noble/hashes/1.3.0:
/@noble/secp256k1/1.7.1:
resolution:
{ integrity: sha512-ilHEACi9DwqJB0pw7kv+Apvh50jiiSyR/cQ3y4W7lOR5mhvn/50FLUfsnfJz0BDZtl/RR16kXvptiv6q1msYZg== }
{ integrity: sha512-hOUk6AyBFmqVrv7k5WAw/LpszxVbj9gGN4JRkIX52fdFAj1UA61KXmZDvqVEm+pOyec3+fIeZB02LYa/pWOArw== }
dev: false
/@nodelib/fs.scandir/2.1.5:
@ -1084,20 +1082,20 @@ packages:
{ integrity: sha512-ZxOhsSyxYwLJj3pLZCefNitxsj093tb2vq90mp2txoYeBqbcjDjqFhyM8eUjq/uFm6zJ+mUuqxlS2FkuSY1MTA== }
dev: false
/@scure/bip32/1.3.0:
/@scure/bip32/1.1.4:
resolution:
{ integrity: sha512-bcKpo1oj54hGholplGLpqPHRbIsnbixFtc06nwuNM5/dwSXOq/AAYoIBRsBmnZJSdfeNW5rnff7NTAz3ZCqR9Q== }
{ integrity: sha512-m925ACYK0wPELsF7Z/VdLGmKj1StIeHraPMYB9xiAFiq/PnvqWd/99I0TQ2OZhjjlMDsDJeZlyXMWi0beaA7NA== }
dependencies:
'@noble/curves': 1.0.0
'@noble/hashes': 1.3.0
'@noble/hashes': 1.2.0
'@noble/secp256k1': 1.7.1
'@scure/base': 1.1.1
dev: false
/@scure/bip39/1.2.0:
/@scure/bip39/1.1.1:
resolution:
{ integrity: sha512-SX/uKq52cuxm4YFXWFaVByaSHJh2w3BnokVSeUJVCv6K7WulT9u2BuNRBhuFl8vAuYnzx9bEu9WgpcNYTrYieg== }
{ integrity: sha512-t+wDck2rVkh65Hmv280fYdVdY25J9YeEUIgn2LG1WM6gxFkGzcksoDiUkWVpVp3Oex9xGC68JU2dSbUfwZ2jPg== }
dependencies:
'@noble/hashes': 1.3.0
'@noble/hashes': 1.2.0
'@scure/base': 1.1.1
dev: false
@ -1765,7 +1763,7 @@ packages:
hasBin: true
dependencies:
caniuse-lite: 1.0.30001480
electron-to-chromium: 1.4.367
electron-to-chromium: 1.4.368
node-releases: 2.0.10
update-browserslist-db: 1.0.11_browserslist@4.21.5
dev: true
@ -2118,9 +2116,9 @@ packages:
{ integrity: sha512-I88TYZWc9XiYHRQ4/3c5rjjfgkjhLyW2luGIheGERbNQ6OY7yTybanSpDXZa8y7VUP9YmDcYa+eyq4ca7iLqWA== }
dev: true
/electron-to-chromium/1.4.367:
/electron-to-chromium/1.4.368:
resolution:
{ integrity: sha512-mNuDxb+HpLhPGUKrg0hSxbTjHWw8EziwkwlJNkFUj3W60ypigLDRVz04vU+VRsJPi8Gub+FDhYUpuTm9xiEwRQ== }
{ integrity: sha512-e2aeCAixCj9M7nJxdB/wDjO6mbYX+lJJxSJCXDzlr5YPGYVofuJwGN9nKg2o6wWInjX6XmxRinn3AeJMK81ltw== }
dev: true
/emoji-mart/5.5.2:
@ -3679,21 +3677,21 @@ packages:
dependencies:
'@jest/source-map': 29.4.3
isomorphic-ws: 5.0.0_ws@8.13.0
nostr-tools: 1.9.0
nostr-tools: 1.10.0
safe-stable-stringify: 2.4.3
transitivePeerDependencies:
- ws
dev: false
/nostr-tools/1.9.0:
/nostr-tools/1.10.0:
resolution:
{ integrity: sha512-ZvFf1uiBqWLWhLBHD2nY0KsdSdNWKb3PrQUmYMWxSzfT4k48cDrDJu2qgULkOhQbFX7oty8IpaKnLvixhqefqA== }
{ integrity: sha512-Bbkucv25M69TaV+slqz1Vfce8G5O3dqSQOqqOZd/LwhooBJp62qt5V3JvlCV55OUqxaucC2brggeIER5Wliy1w== }
dependencies:
'@noble/curves': 1.0.0
'@noble/hashes': 1.3.0
'@noble/hashes': 1.2.0
'@noble/secp256k1': 1.7.1
'@scure/base': 1.1.1
'@scure/bip32': 1.3.0
'@scure/bip39': 1.2.0
'@scure/bip32': 1.1.4
'@scure/bip39': 1.1.1
dev: false
/npm-run-path/5.1.0:

View File

@ -1 +0,0 @@
DATABASE_URL="/Users/phong/Library/Application Support/com.uselume.xyz"

View File

@ -1 +0,0 @@
DATABASE_ENV=<database url>

112
src-tauri/Cargo.lock generated
View File

@ -2104,6 +2104,12 @@ version = "0.2.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "68354c5c6bd36d73ff3feceb05efa59b6acb7626617f4962be322a825e61f79a"
[[package]]
name = "minisign-verify"
version = "0.2.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "933dca44d65cdd53b355d0b73d380a2ff5da71f87f036053188bf1eab6a19881"
[[package]]
name = "miniz_oxide"
version = "0.6.2"
@ -2320,6 +2326,17 @@ dependencies = [
"objc_exception",
]
[[package]]
name = "objc-foundation"
version = "0.1.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "1add1b659e36c9607c7aab864a76c7a4c2760cd0cd2e120f3fb8b952c7e22bf9"
dependencies = [
"block",
"objc",
"objc_id",
]
[[package]]
name = "objc_exception"
version = "0.1.2"
@ -2982,6 +2999,30 @@ dependencies = [
"winapi",
]
[[package]]
name = "rfd"
version = "0.10.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "0149778bd99b6959285b0933288206090c50e2327f47a9c463bfdbf45c8823ea"
dependencies = [
"block",
"dispatch",
"glib-sys",
"gobject-sys",
"gtk-sys",
"js-sys",
"lazy_static",
"log",
"objc",
"objc-foundation",
"objc_id",
"raw-window-handle",
"wasm-bindgen",
"wasm-bindgen-futures",
"web-sys",
"windows 0.37.0",
]
[[package]]
name = "ring"
version = "0.16.20"
@ -3722,6 +3763,7 @@ checksum = "fe7e0f1d535e7cbbbab43c82be4fc992b84f9156c16c160955617e0260ebc449"
dependencies = [
"anyhow",
"attohttpc",
"base64 0.13.1",
"cocoa",
"dirs-next",
"embed_plist",
@ -3734,6 +3776,7 @@ dependencies = [
"heck 0.4.1",
"http",
"ignore",
"minisign-verify",
"objc",
"once_cell",
"open",
@ -3742,6 +3785,7 @@ dependencies = [
"rand 0.8.5",
"raw-window-handle",
"regex",
"rfd",
"semver",
"serde",
"serde_json",
@ -3755,12 +3799,14 @@ dependencies = [
"tauri-utils",
"tempfile",
"thiserror",
"time",
"tokio",
"url",
"uuid 1.3.1",
"webkit2gtk",
"webview2-com",
"windows 0.39.0",
"zip",
]
[[package]]
@ -4381,6 +4427,18 @@ dependencies = [
"wasm-bindgen-shared",
]
[[package]]
name = "wasm-bindgen-futures"
version = "0.4.29"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "2eb6ec270a31b1d3c7e266b999739109abce8b6c87e4b31fcfcd788b65267395"
dependencies = [
"cfg-if",
"js-sys",
"wasm-bindgen",
"web-sys",
]
[[package]]
name = "wasm-bindgen-macro"
version = "0.2.79"
@ -4555,6 +4613,19 @@ version = "0.4.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "712e227841d057c1ee1cd2fb22fa7e5a5461ae8e48fa2ca79ec42cfc1931183f"
[[package]]
name = "windows"
version = "0.37.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "57b543186b344cc61c85b5aab0d2e3adf4e0f99bc076eff9aa5927bcc0b8a647"
dependencies = [
"windows_aarch64_msvc 0.37.0",
"windows_i686_gnu 0.37.0",
"windows_i686_msvc 0.37.0",
"windows_x86_64_gnu 0.37.0",
"windows_x86_64_msvc 0.37.0",
]
[[package]]
name = "windows"
version = "0.39.0"
@ -4694,6 +4765,12 @@ version = "0.48.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "91ae572e1b79dba883e0d315474df7305d12f569b400fcf90581b06062f7e1bc"
[[package]]
name = "windows_aarch64_msvc"
version = "0.37.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "2623277cb2d1c216ba3b578c0f3cf9cdebeddb6e66b1b218bb33596ea7769c3a"
[[package]]
name = "windows_aarch64_msvc"
version = "0.39.0"
@ -4712,6 +4789,12 @@ version = "0.48.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "b2ef27e0d7bdfcfc7b868b317c1d32c641a6fe4629c171b8928c7b08d98d7cf3"
[[package]]
name = "windows_i686_gnu"
version = "0.37.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "d3925fd0b0b804730d44d4b6278c50f9699703ec49bcd628020f46f4ba07d9e1"
[[package]]
name = "windows_i686_gnu"
version = "0.39.0"
@ -4730,6 +4813,12 @@ version = "0.48.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "622a1962a7db830d6fd0a69683c80a18fda201879f0f447f065a3b7467daa241"
[[package]]
name = "windows_i686_msvc"
version = "0.37.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "ce907ac74fe331b524c1298683efbf598bb031bc84d5e274db2083696d07c57c"
[[package]]
name = "windows_i686_msvc"
version = "0.39.0"
@ -4748,6 +4837,12 @@ version = "0.48.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "4542c6e364ce21bf45d69fdd2a8e455fa38d316158cfd43b3ac1c5b1b19f8e00"
[[package]]
name = "windows_x86_64_gnu"
version = "0.37.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "2babfba0828f2e6b32457d5341427dcbb577ceef556273229959ac23a10af33d"
[[package]]
name = "windows_x86_64_gnu"
version = "0.39.0"
@ -4778,6 +4873,12 @@ version = "0.48.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "7896dbc1f41e08872e9d5e8f8baa8fdd2677f29468c4e156210174edc7f7b953"
[[package]]
name = "windows_x86_64_msvc"
version = "0.37.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "f4dd6dc7df2d84cf7b33822ed5b86318fb1781948e9663bacd047fc9dd52259d"
[[package]]
name = "windows_x86_64_msvc"
version = "0.39.0"
@ -4946,6 +5047,17 @@ dependencies = [
"zvariant",
]
[[package]]
name = "zip"
version = "0.6.4"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "0445d0fbc924bb93539b4316c11afb121ea39296f99a3c4c9edad09e3658cdef"
dependencies = [
"byteorder",
"crc32fast",
"crossbeam-utils",
]
[[package]]
name = "zvariant"
version = "3.12.0"

View File

@ -16,7 +16,7 @@ tauri-build = { version = "1.2", features = [] }
[dependencies]
serde_json = "1.0"
serde = { version = "1.0", features = ["derive"] }
tauri = { version = "1.2", features = ["clipboard-read-text", "clipboard-write-text", "http-request", "os-all", "shell-open", "system-tray", "window-close", "window-start-dragging"] }
tauri = { version = "1.2", features = ["clipboard-read-text", "clipboard-write-text", "http-request", "os-all", "shell-open", "system-tray", "updater", "window-close", "window-start-dragging"] }
tauri-plugin-single-instance = { git = "https://github.com/tauri-apps/plugins-workspace", branch = "dev" }
sqlx-cli = {version = "0.6.3", default-features = false, features = ["sqlite"] }

View File

@ -22,7 +22,7 @@
"http": {
"all": false,
"request": true,
"scope": ["https://rbr.bio/*", "https://metadata.uselume.xyz/*"]
"scope": ["https://rbr.bio/*", "https://metadata.lume.nu/*"]
},
"shell": {
"all": false,
@ -53,7 +53,7 @@
},
"externalBin": [],
"icon": ["icons/32x32.png", "icons/128x128.png", "icons/128x128@2x.png", "icons/icon.icns", "icons/icon.ico"],
"identifier": "com.uselume.xyz",
"identifier": "com.lume.nu",
"longDescription": "",
"macOS": {
"entitlements": null,
@ -75,7 +75,13 @@
"csp": null
},
"updater": {
"active": false
"active": true,
"endpoints": ["https://releases.lume.nu/{{target}}/{{arch}}/{{current_version}}"],
"dialog": true,
"pubkey": "dW50cnVzdGVkIGNvbW1lbnQ6IG1pbmlzaWduIHB1YmxpYyBrZXk6IDQ2N0U5RjEzRkY3QUVBMTEKUldRUjZuci9FNTkrUnFaYWZhS3ZkMDFpOXhBNHpyT2ZrWUg4SHdFZ3FzY2tCNStibmw0T29TcXQK%",
"windows": {
"installMode": "passive"
}
},
"systemTray": {
"iconPath": "icons/icon.png",