Skip to content

Instantly share code, notes, and snippets.

$ find -type f -executable -exec file -i '{}' \; | rg 'executable; charset=binary'
./target/testnet/deps/xcm_procedural-582d17661bee7dff: application/x-pie-executable; charset=binary
./target/testnet/deps/tracing_gum_proc_macro-a6165aaba6c482e5: application/x-pie-executable; charset=binary
./target/testnet/deps/polkadot_core_primitives-df9e4b6a9f75feff: application/x-pie-executable; charset=binary
./target/testnet/deps/slot_range_helper-ba29a553a2e8477f: application/x-pie-executable; charset=binary
./target/testnet/deps/xcm-647ffaad380ee560: application/x-pie-executable; charset=binary
./target/testnet/deps/polkadot_rpc-3cfeca1fe2216f97: application/x-pie-executable; charset=binary
./target/testnet/deps/zombienet_backchannel-ca022598c0f8c919: application/x-pie-executable; charset=binary
./target/testnet/deps/polkadot_node_subsystem_types-4a072c859988def4: application/x-pie-executable; charset=binary
0.0.0.0 us.rdx2.lgtvsdp.com
0.0.0.0 us.info.lgsmartad.com
0.0.0.0 us.ibs.lgappstv.com
0.0.0.0 CA.ibs.lgappstv.com
0.0.0.0 us.lgtvsdp.com
0.0.0.0 ad.lgappstv.com
0.0.0.0 smartshare.lgtvsdp.com
0.0.0.0 ibis.lgappstv.com
# added after fork
@TriplEight
TriplEight / github_repos_by_latest_commit.py
Last active April 12, 2022 18:57
List organization's repos, last master commit date and author
# Script to fetch all repos under a git organization
# Returns last committer to master, date of commit
# and if the repo is archived.
#
# Results sorted by commit date
# Replace ORG_NAME, USERNAME, and PASSWORD variables
# import urllib2
from urllib.request import urlopen
import requests
@TriplEight
TriplEight / .bashrc
Last active April 13, 2021 12:23
Function for bash/fish to run cargo as a virtual environment in the current dir
# "Cargo as a virtual environment in the current dir"
function cargoenvhere {
dirname="$(basename $(pwd))"
user=$(whoami)
echo "Cargo as a virtual environment in" "$dirname" "dir"
mkdir -p /home/"$user"/cache/"$dirname"
podman run --rm -it -w /shellhere/"$dirname" -v "$(pwd)":/shellhere/"$dirname" -v /home/"$user"/cache/"$dirname"/:/cache/ -e CARGO_HOME=/cache/cargo/ -e SCCACHE_DIR=/cache/sccache/ -e CARGO_TARGET_DIR=/cache/target/ "$@"
}
# example use

Keybase proof

I hereby claim:

  • I am TriplEight on github.
  • I am tripleight (https://keybase.io/tripleight) on keybase.
  • I have a public key whose fingerprint is EAE4 67DA 6A8E 8E43 BA2C DF06 3906 9184 3612 02D8

To claim this, I am signing this object:

Accounts

Different accounts are used to manage funds. The underlying cryptography of their account keys is the same:

Stash

  • Primary account
  • Holds funds. Usually a cold wallet (on piece of paper in a safe, or protected by layers of hardware security)
  • Bonds (locks) a portion of its funds with a Controller for participation (since the stake key is kept offline)
  • Unbonding requires waiting ~600 blocks before unlocked funds accessible again
@TriplEight
TriplEight / dietpi.md
Created February 1, 2019 08:58
dietpi logs

root@DietPi:~# systemctl status dietpi-postboot ● dietpi-postboot.service - DietPi-PostBoot Loaded: loaded (/etc/systemd/system/dietpi-postboot.service; enabled; vendor preset: enabled) Active: active (exited) since Fri 2019-02-01 08:54:41 GMT; 44s ago Process: 863 ExecStart=/DietPi/dietpi/postboot (code=exited, status=0/SUCCESS) Main PID: 863 (code=exited, status=0/SUCCESS)

Feb 01 08:54:41 DietPi systemd[1]: Started DietPi-PostBoot.

root@DietPi:~# systemctl status dietpi-boot

@TriplEight
TriplEight / gist:f25f8e04cb456505930f5589a513e720
Last active December 19, 2018 09:24
compilation failure
error: failed to run custom build command for `libusb-sys v0.2.4 (https://github.com/paritytech/libusb-sys#14bdb698)`
process didn't exit successfully: `/build/parity-ethereum/target/release/build/libusb-sys-0791beef101dd27b/build-script-build` (exit code: 101)
--- stdout
TARGET = Some("x86_64-pc-windows-gnu")
OPT_LEVEL = Some("3")
HOST = Some("x86_64-unknown-linux-gnu")
CC_x86_64-pc-windows-gnu = None
CC_x86_64_pc_windows_gnu = Some("x86_64-w64-mingw32-gcc-posix")
CFLAGS_x86_64-pc-windows-gnu = None
CFLAGS_x86_64_pc_windows_gnu = None
from selenium.webdriver.support import expected_conditions as EC
class AbstractPage(BasePage):
def find_element_in_table(self, search_by, table_x, column_header_x, is_clickable=False):
"""
Возвращает элемент таблицы :param table_x, найденный по пересечению ряда и столбца.
:param is_clickable:
:param search_by: уникальное значение (id, name) в таблице, нужно для определения ряда
:param table_x: XPATH таблицы
# -*- coding: utf-8 -*-
from selenium import webdriver
from selenium.webdriver.common.by import By
from selenium.webdriver.support.ui import WebDriverWait
from selenium.webdriver.support import expected_conditions as EC
SEARCH_XPATH = '//*[@name="q"]'
# WIKI_XPATH = '//h3//*[@href="https://ru.wikipedia.org/wiki/QA"]'
WIKI_XPATH = '//h3//*[@href="https://en.wikipedia.org/wiki/Quality_assurance"]'
WIKI_LOGO_XPATH = '//*[@class="mw-wiki-logo"]'