Skip to content

Instantly share code, notes, and snippets.

@Xavier59
Xavier59 / app.py
Created February 3, 2021 14:48
Linkedin birhday updater
# Requirements :
# - python3
# - requests (if not preinstalled, python3 -m pip install requests)
#
# Start by :
# - Filling login and password at line 66
# - python3 app.py
from datetime import date
import requests
@Xavier59
Xavier59 / privatekeysolana.js
Created December 28, 2021 14:49
Convert Solana private key from/to base58/uint8array
// exporting from a bs58 private key to an Uint8Array
// == from phantom private key to solana cli id.json key file
// npm install bs58 @solana/web3.js
const web3 = require("@solana/web3.js");
const bs58 = require('bs58');
let secretKey = bs58.decode("[base58 private key here]");
console.log(`[${web3.Keypair.fromSecretKey(secretKey).secretKey}]`);
// exporting back from Uint8Array to bs58 private key
@Xavier59
Xavier59 / liquidity.py
Created September 12, 2022 12:14
Compare liquidity between Kraken and Binance
import requests
def list_common_pairs(kraken, binance):
common = []
for bcurr in binance["symbols"]:
# REMOVE THIS LINE IF YOU DON'T WANT ANY FILTER.
# HERE, ONLY RETAINS EUR PAIRS
if "EUR" not in bcurr["symbol"]:
continue
for kcurr in [*kraken["result"]]: