solana-cli-explorer 0.1.0

A command line explorer for the Solana Blockchain.
1
2
3
4
5
6
7
8
9
10
11
pub fn get_network(network_str: &str) -> String {
    match network_str {
        "devnet" | "dev" | "d" => "https://api.devnet.solana.com",
        "testnet" | "test" | "t" => "https://api.testnet.solana.com",
        "mainnet" | "main" | "m" | "mainnet-beta" => "https://api.mainnet-beta.solana.com",
        "localnet" | "localhost" | "l" | "local" => "http://localhost:8899",
        // custom
        _ => network_str,
    }
    .to_string()
}