Skip to content

Instantly share code, notes, and snippets.

@UdjinM6
UdjinM6 / bitcoin_debugging.md
Created February 13, 2022 22:39 — forked from fjahr/bitcoin_debugging.md
Debugging Bitcoin Core

Moved to https://github.com/fjahr/debugging_bitcoin to allow for better collaboration.

This document is currently optimized for MacOS. If you would like to help me add Linux equivalent commands, please let me know.

Debugging Bitcoin Core

This guide is designed to give beginners of C++ development and/or people new to the bitcoin core code base an overview of the tools available for debugging issues as well as giving hints where issues may trip you up.

@UdjinM6
UdjinM6 / export_grafana_dashboards.sh
Last active January 13, 2021 01:10
Export all public Graphana dashboards
#!/bin/bash
full_url="http://your_graphana_host_here"
name="dashboards"
create_slug () {
echo "$1" | iconv -t ascii//TRANSLIT | sed -r s/[^a-zA-Z0-9]+/-/g | sed -r s/^-+\|-+$//g | tr A-Z a-z
}
process_db_json() {
@UdjinM6
UdjinM6 / systemMetricsDaemon.py
Last active January 13, 2021 00:58
System Metrics daemon for stasd
#!/usr/bin/env python3
# The daemon reads system metrics and outputs them to StatsD.
#
# It requires django, the python statsd library, and PSUtil: https://github.com/giampaolo/psutil i.e.
# pip3 install django psutil statsd
#
# Usage: python3 systemMetricsDaemon.py &
import os
@UdjinM6
UdjinM6 / electrumx.sh
Last active April 16, 2021 19:42
ElectrumX setup for Dash
#!/bin/sh
# ElectrumX setup for Dash
# NOTE: with this setup ElectrumX will be running under root (to simplify things),
# modify it accordingly if you want to run it under some specific user
# NOTE: this script itself is not enough, you'll have to edit a couple of files manually,
# pls read comments below
# python3.7 is requried for ElectrumX,
#!/bin/sh
# Compile Dash Core on FreeBSD
#
# Tested with Dash Core v0.17.0.0-rc2 on FreeBSD 12.2
# --- Options ---
WORKDIR=`pwd`
GITREPO="https://github.com/dashpay/dash"
GITDIR="dash"
@UdjinM6
UdjinM6 / bitcoin_spv_wallet_overview.md
Created February 21, 2016 16:59 — forked from TOMOAKI12345/bitcoin_spv_wallet_overview.md
Bitcoin SPV Wallet Flow Overview

@UdjinM6
UdjinM6 / index.html
Last active August 29, 2015 14:26 — forked from anonymous/index.html
Dash ticker // source http://jsbin.com/werasikolo
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>Dash ticker</title>
<style id="jsbin-css">
div {
width: 200px;
}
</style>
@UdjinM6
UdjinM6 / MN3.py
Last active April 15, 2016 11:35
Fixed: dashninja.pl API usage; Changed: switched to explorer.dash.org to fetch balances
from Tkinter import *
import urllib2
from datetime import datetime
import smtplib
import time
import os
import ConfigParser as con
from appdirs import AppDirs
import json

Keybase proof

I hereby claim:

  • I am UdjinM6 on github.
  • I am udjinm6 (https://keybase.io/udjinm6) on keybase.
  • I have a public key whose fingerprint is 3F5D 48C9 F002 93CD 365A 3A98 8359 2BD1 400D 58D9

To claim this, I am signing this object:

@UdjinM6
UdjinM6 / node-x11-hash-algo.js
Created March 22, 2015 18:49
node-x11-hash-algo example
var x11 = require('node-x11-hash-algo');
String.prototype.hexEncode = function(){
var hex, i;
var result = "";
for (i=0; i<this.length; i++) {
hex = this.charCodeAt(i).toString(16);
result += ("000"+hex).slice(-4);
}