Skip to content

Instantly share code, notes, and snippets.

View ethgr0wth's full-sized avatar
💭
interchained.org

gr0wth.eth.xmr ethgr0wth

💭
interchained.org
View GitHub Profile
@ethgr0wth
ethgr0wth / itc_cli.py
Last active December 13, 2025 22:19
PSBT: Below is a minimal, production-safe version that does the following: python3 itc_cli.py <destination_address> <amount> No CSV, no shares, no batching, no previews — just: validate address create PSBT sign finalize broadcast Uses walletcreatefundedpsbt so fees come from change (exact send).
#!/usr/bin/env python3
import os
import sys
import argparse
from decimal import Decimal, ROUND_DOWN, getcontext
import requests
from requests.auth import HTTPBasicAuth
getcontext().prec = 28
sudo apt install libcap2-bin libnss3-tools wget tar git apt-transport-https curl build-essential screen
sudo apt install -y debian-keyring debian-archive-keyring
mkdir caddy
cd caddy && wget https://github.com/caddyserver/caddy/releases/download/v2.5.2/caddy_2.5.2_linux_amd64.tar.gz
tar -xvf caddy_2.5.2_linux_amd64.tar.gz
echo 'caddy run --adapter "caddyfile" --config "CaddyFile"' > startCaddy.sh
mkdir /usr/local/caddy
mv ~/caddy/caddy /usr/local/bin/caddy
export PATH=$PATH:/usr/local/caddy
cd ~
@ethgr0wth
ethgr0wth / async.md
Created August 7, 2022 18:29 — forked from chriseth/async.md
Async Solidity Contracts

Having seen @pirapira's sketch of Bamboo ( https://github.com/pirapira/bamboo/ ), which proposed to add better control about the "smart contract program flow", even across calls, I thought that this should certainly be added to Solidity, and actually, it might even be possible now to a certain degree using inline assembly.

The problem is that with many functions in a contract, it is not always clear which can be called at which stage in the contract's lifetime. Certain smart contracts would be easier to understand if written as follows: