|
|
@@ -3,13 +3,23 @@
|
|
|
DLTOOL = wget -nv --show-progress -O-
|
|
|
|
|
|
LISTS = \
|
|
|
- erc20_token_list.json \
|
|
|
- solana_token_list.json
|
|
|
+ bitcoin_token_list \
|
|
|
+ erc20_token_list \
|
|
|
+ solana_token_list
|
|
|
+
|
|
|
+LISTS_JSON = $(LISTS:=.json)
|
|
|
+LISTS_MIN = $(LISTS:=.min.json)
|
|
|
|
|
|
ERC20 = https://tokens.coingecko.com/uniswap/all.json
|
|
|
-SOL = https://github.com/solana-labs/token-list/raw/main/src/tokens/solana.tokenlist.json
|
|
|
+SOL = https://github.com/solana-labs/token-list/raw/main/src/tokens/solana.tokenlist.json
|
|
|
+
|
|
|
+all: $(LISTS_MIN)
|
|
|
|
|
|
-all: $(LISTS)
|
|
|
+$(LISTS_MIN): $(LISTS_JSON)
|
|
|
+ jq -r -c < $< > $@
|
|
|
+
|
|
|
+bitcoin_token_list.json:
|
|
|
+ git checkout -- $@
|
|
|
|
|
|
erc20_token_list.json:
|
|
|
$(DLTOOL) $(ERC20) | jq -r > $@
|
|
|
@@ -20,4 +30,7 @@ solana_token_list.json:
|
|
|
-e 's@"symbol": "ETH"@"symbol": "SETH"@' \
|
|
|
| jq -r > $@
|
|
|
|
|
|
-.PHONY: all $(LISTS)
|
|
|
+clean:
|
|
|
+ rm -f $(LISTS_JSON) $(LISTS_MIN)
|
|
|
+
|
|
|
+.PHONY: all
|