Skip to content

Instantly share code, notes, and snippets.

View AlecSchneider's full-sized avatar
🤙
Code on!

Alec Schneider AlecSchneider

🤙
Code on!
View GitHub Profile
@AlecSchneider
AlecSchneider / get_balances.py
Last active June 24, 2021 16:35
Get your AVAX and PNG balance in YieldYak AVAX-PNG Pair
from web3 import Web3
import requests
YOUR_C_CHAIN_ADDRESS = ""
# Get the ABI from somewhere like here: https://cchain.explorer.avax.network/address/0xA544b965C2a05b97C44f3126cec916332aFb3175/contracts
YAK_ABI = ""
ERC20_ABI = ""
w3 = Web3(Web3.HTTPProvider("https://api.avax.network/ext/bc/C/rpc"))
@AlecSchneider
AlecSchneider / youtube-dl.sh
Created November 1, 2020 16:03
Shows how to install pip -> youtube-dl and download videos
apk add py3-pip
pip3 install youtube-dl
# download video
youtube-dl --no-check-certificate link
# run in background
youtube-dl --no-check-certificate -q link &
@AlecSchneider
AlecSchneider / python_on_iphone.sh
Last active May 18, 2024 10:53
How to install apk and Python on your iPhone using the iSH Shell
cd
# you can do this all in one command
wget -qO- http://dl-cdn.alpinelinux.org/alpine/v3.12/main/x86/apk-tools-static-2.10.5-r1.apk | tar -xz sbin/apk.static && ./sbin/apk.static add apk-tools && rm sbin/apk.static
apk add python3