Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

New Ethereum testnets #538

Merged
merged 3 commits into from
Feb 14, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions glyphs/stax_chain_11155111_64px.gif
1 change: 1 addition & 0 deletions glyphs/stax_chain_17000_64px.gif
Binary file removed glyphs/stax_chain_58008_64px.gif
Binary file not shown.
3 changes: 2 additions & 1 deletion src/network.c
Original file line number Diff line number Diff line change
Expand Up @@ -79,12 +79,13 @@ static const network_info_t NETWORK_MAPPING[] = {
{.chain_id = 248, .name = "Oasys", .ticker = "OAS"},
{.chain_id = 1101, .name = "Polygon zkEVM", .ticker = "ETH"},
{.chain_id = 8453, .name = "Base", .ticker = "ETH"},
{.chain_id = 58008, .name = "Sepolia", .ticker = "ETH"},
{.chain_id = 1907, .name = "Bitcichain", .ticker = "BITCI"},
{.chain_id = 1116, .name = "Core", .ticker = "CORE"},
{.chain_id = 7171, .name = "Bitrock Mainnet", .ticker = "BROCK"},
{.chain_id = 10507, .name = "Numbers Protocol", .ticker = "NUM"},
{.chain_id = 59144, .name = "Linea", .ticker = "ETH"},
{.chain_id = 11155111, .name = "Sepolia", .ticker = "ETH"},
{.chain_id = 17000, .name = "Holesky", .ticker = "ETH"},
};

static const network_info_t *get_network_from_chain_id(const uint64_t *chain_id) {
Expand Down
6 changes: 5 additions & 1 deletion tools/gen_networks.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
import sys
import re
import argparse
from pathlib import Path


class Network:
Expand Down Expand Up @@ -62,7 +63,10 @@ def gen_icons_array_src(networks: list[Network], path: str) -> bool:

for net in networks:
glyph_name = get_network_glyph_name(net)
if os.path.isfile("glyphs/%s.gif" % (glyph_name)):
glyph_file = "glyphs/%s.gif" % (glyph_name)
if os.path.isfile(glyph_file):
if os.path.islink(glyph_file):
glyph_name = Path(os.path.realpath(glyph_file)).stem
print(" "*4, end="", file=out)
print("{.chain_id = %u, .icon = &C_%s}, // %s" % (net.chain_id,
glyph_name,
Expand Down
Loading