feat(cli): implements subcommands
This commit is contained in:
parent
7382b06bdf
commit
3fefadd5b5
5 changed files with 37 additions and 50 deletions
|
|
@ -13,11 +13,6 @@ pub mod grpc_juno {
|
|||
tonic::include_proto!("juno");
|
||||
}
|
||||
|
||||
#[async_trait]
|
||||
pub trait Connection {
|
||||
async fn connect(&self) -> Result<(), Box<dyn Error>>;
|
||||
}
|
||||
|
||||
/// Return true if the addr is already in use, false otherwise
|
||||
pub fn is_socket_in_use(addr: SocketAddr) -> bool {
|
||||
match TcpListener::bind(addr) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue