chore: rename device crate to nip4e

This commit is contained in:
2026-10-04 12:24:42 +07:00
parent 67f8f5db49
commit 045151fe5c
12 changed files with 35 additions and 36 deletions
Generated
+24 -24
View File
@@ -1073,7 +1073,6 @@ version = "1.0.2"
dependencies = [
"anyhow",
"common",
"device",
"flume 0.11.1",
"futures",
"fuzzy-matcher",
@@ -1081,6 +1080,7 @@ dependencies = [
"instant",
"itertools 0.13.0",
"log",
"nip4e",
"nostr-sdk",
"person",
"settings",
@@ -1413,7 +1413,6 @@ dependencies = [
"auto_update",
"chat",
"common",
"device",
"gpui-pre",
"gpui-pre-linux",
"gpui-pre-macos",
@@ -1422,6 +1421,7 @@ dependencies = [
"gpui-pre-windows",
"log",
"nip29",
"nip4e",
"nostr-sdk",
"person",
"settings",
@@ -1441,7 +1441,6 @@ dependencies = [
"common",
"console_error_panic_hook",
"console_log",
"device",
"getrandom 0.2.17",
"getrandom 0.3.4",
"getrandom 0.4.3",
@@ -1451,6 +1450,7 @@ dependencies = [
"instant",
"log",
"nip29",
"nip4e",
"person",
"settings",
"state",
@@ -1823,26 +1823,6 @@ dependencies = [
"unicode-xid",
]
[[package]]
name = "device"
version = "1.0.2"
dependencies = [
"anyhow",
"common",
"flume 0.11.1",
"gpui-pre",
"instant",
"log",
"nostr-sdk",
"person",
"settings",
"smallvec",
"smol",
"state",
"theme",
"ui",
]
[[package]]
name = "digest"
version = "0.10.7"
@@ -4577,6 +4557,26 @@ dependencies = [
"ui",
]
[[package]]
name = "nip4e"
version = "1.0.2"
dependencies = [
"anyhow",
"common",
"flume 0.11.1",
"gpui-pre",
"instant",
"log",
"nostr-sdk",
"person",
"settings",
"smallvec",
"smol",
"state",
"theme",
"ui",
]
[[package]]
name = "no_std_io2"
version = "0.9.4"
@@ -9438,12 +9438,12 @@ dependencies = [
"chat",
"chat_ui",
"common",
"device",
"gpui-pre",
"instant",
"log",
"nip29",
"nip29_ui",
"nip4e",
"nostr-connect",
"nostr-sdk",
"person",
+1 -1
View File
@@ -7,7 +7,7 @@ publish.workspace = true
[dependencies]
common = { path = "../common" }
state = { path = "../state" }
device = { path = "../device" }
nip4e = { path = "../nip4e" }
person = { path = "../person" }
settings = { path = "../settings" }
+1 -1
View File
@@ -3,7 +3,7 @@ use std::hash::{Hash, Hasher};
use anyhow::{Error, anyhow};
use common::EventExt;
use device::DeviceRegistry;
use nip4e::DeviceRegistry;
use gpui::{App, AppContext, Context, EventEmitter, SharedString, Task};
use instant::Duration;
use itertools::Itertools;
@@ -1,5 +1,5 @@
[package]
name = "device"
name = "nip4e"
version.workspace = true
edition.workspace = true
publish.workspace = true
+1 -1
View File
@@ -9,7 +9,7 @@ ui = { path = "../ui" }
theme = { path = "../theme" }
common = { path = "../common" }
state = { path = "../state" }
device = { path = "../device" }
nip4e = { path = "../nip4e" }
chat = { path = "../chat" }
chat_ui = { path = "../chat_ui" }
nip29 = { path = "../nip29" }
+2 -3
View File
@@ -1,12 +1,11 @@
use instant::Duration;
use anyhow::Error;
use device::DeviceRegistry;
use gpui::prelude::FluentBuilder;
use gpui::{
AppContext, Context, Entity, IntoElement, ParentElement, Render, SharedString, Styled,
Subscription, Task, Window, div,
};
use instant::Duration;
use nip4e::DeviceRegistry;
use nostr_sdk::prelude::*;
use theme::ActiveTheme;
use ui::button::{Button, ButtonVariants};
+1 -1
View File
@@ -5,7 +5,7 @@ use anyhow::Error;
use auto_update::AutoUpdater;
use chat::{ChatEvent, ChatRegistry};
use common::download_dir;
use device::{DeviceEvent, DeviceRegistry};
use nip4e::{DeviceEvent, DeviceRegistry};
use gpui::{
Action, App, AppContext, Context, Entity, InteractiveElement, IntoElement, ParentElement,
Render, SharedString, Styled, Subscription, Task, Window, div, px,
+1 -1
View File
@@ -33,7 +33,7 @@ ui = { path = "../crates/ui" }
theme = { path = "../crates/theme" }
common = { path = "../crates/common" }
state = { path = "../crates/state" }
device = { path = "../crates/device" }
nip4e = { path = "../crates/nip4e" }
chat = { path = "../crates/chat" }
nip29 = { path = "../crates/nip29" }
settings = { path = "../crates/settings" }
+1 -1
View File
@@ -73,7 +73,7 @@ fn main() {
// Initialize device signer
//
// NIP-4e: https://github.com/nostr-protocol/nips/blob/per-device-keys/4e.md
device::init(cx);
nip4e::init(cx);
// Initialize app registry
chat::init(cx);
+1 -1
View File
@@ -14,7 +14,7 @@ ui = { path = "../crates/ui" }
theme = { path = "../crates/theme" }
common = { path = "../crates/common" }
state = { path = "../crates/state" }
device = { path = "../crates/device" }
nip4e = { path = "../crates/nip4e" }
chat = { path = "../crates/chat" }
nip29 = { path = "../crates/nip29" }
settings = { path = "../crates/settings" }
+1 -1
View File
@@ -65,7 +65,7 @@ pub fn run() -> Result<(), JsValue> {
// Initialize device signer
//
// NIP-4e: https://github.com/nostr-protocol/nips/blob/per-device-keys/4e.md
device::init(cx);
nip4e::init(cx);
// Initialize app registry
chat::init(cx);