mirror of
https://seed.radicle.dev/rad:z3gqcJUoA1n9HaHKufZs5FCSGazv5.git
synced 2026-11-28 21:50:26 +08:00
node: Implement Client
Signed-off-by: Alexis Sellier <self@cloudhead.io>
This commit is contained in:
@@ -5,7 +5,7 @@ use serde::{Deserialize, Serialize};
|
||||
|
||||
use crate::crypto;
|
||||
use crate::identity::ProjId;
|
||||
use crate::protocol::{Context, NodeId, Timestamp, NETWORK_MAGIC, PROTOCOL_VERSION};
|
||||
use crate::protocol::{Context, NodeId, Timestamp, PROTOCOL_VERSION};
|
||||
use crate::storage;
|
||||
|
||||
/// Message envelope. All messages sent over the network are wrapped in this type.
|
||||
@@ -98,15 +98,6 @@ pub enum Message {
|
||||
},
|
||||
}
|
||||
|
||||
impl From<Message> for Envelope {
|
||||
fn from(msg: Message) -> Self {
|
||||
Self {
|
||||
magic: NETWORK_MAGIC,
|
||||
msg,
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
impl Message {
|
||||
pub fn hello(id: NodeId, timestamp: Timestamp, addrs: Vec<Address>, git: Url) -> Self {
|
||||
Self::Hello {
|
||||
|
||||
Reference in New Issue
Block a user