Skip to content

Instantly share code, notes, and snippets.

View patricklodder's full-sized avatar
6️⃣
9️⃣

Old Dip Tracker patricklodder

6️⃣
9️⃣
View GitHub Profile
@patricklodder
patricklodder / gitian_build_custom_repo.sh
Last active November 8, 2021 06:30
Build a dogecoin build with custom repo/tag
sudo apt update
sudo apt install -y ruby git build-essential apt-transport-https ca-certificates \
curl gnupg-agent software-properties-common
curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add -
add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/ubuntu $(lsb_release -cs) stable"
sudo apt update
sudo apt install -y docker-ce docker-ce-cli containerd.io apt-cacher-ng
sudo apt upgrade -y
@patricklodder
patricklodder / 2021-Dogecoin-fee-policy-proposal.md
Created June 27, 2021 20:12
2021 Dogecoin Fee Policy Proposal

DOGECOIN FEE POLICY CHANGE PROPOSAL

This document proposes a new fee structure and policy for Dogecoin Core, to be gradually deployed to the network over multiple software releases.

Historical fee policy

Meaningful fees were introduced for Dogecoin in 2014 to reduce on-chain spam. With a 1 DOGE fee per kilobyte, rounded up, the Dogecoin chain provided

@patricklodder
patricklodder / Dockerfile.alpine.withtests
Created June 9, 2021 16:46
Alpine/Musl testing Dockerfile for Dogecoin
ARG ALPINE_VERSION=3.9
ARG BDB_VERSION=5.1.29.NC
ARG BDB_SHA256SUM=08238e59736d1aacdd47cfb8e68684c695516c37f4fbe1b8267dde58dc3a576c
FROM alpine:${ALPINE_VERSION} AS bdb
ARG BDB_VERSION
ARG BDB_SHA256SUM
RUN apk upgrade && apk add \
build-base autoconf automake
@patricklodder
patricklodder / add_net_status_probe.patch
Created March 23, 2021 20:24
network status probe
diff --git a/main.go b/main.go
index fd397b0..5123269 100644
--- a/main.go
+++ b/main.go
@@ -189,6 +189,21 @@ func main() {
return server.Shutdown(ctx)
})
+ ticker := time.NewTicker(5 * time.Second)
+ quit := make(chan struct{})
@patricklodder
patricklodder / gitian_build.sh
Last active November 8, 2021 17:52
Dogecoin 1.14.5 gitian build script on Ubuntu 20.04 w/ docker
sudo apt update
sudo apt install -y ruby git build-essential
sudo apt install -y apt-transport-https ca-certificates curl gnupg-agent software-properties-common
curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add -
sudo add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/ubuntu $(lsb_release -cs) stable"
sudo apt update
sudo apt install -y docker-ce docker-ce-cli containerd.io
sudo apt install -y apt-cacher-ng
sudo systemctl enable apt-cacher-ng.service
sudo systemctl start apt-cacher-ng.service
@patricklodder
patricklodder / crawl_block_fee.sh
Created February 1, 2021 14:12
Crawl block fees paid to miners
#!/bin/bash
#
# requirements: bash, up-to-date dogecoind with -txindex, jq, bc
# usage: ./crawl_block_fee.sh <number of blocks to look back>
START=`dogecoin-cli getbestblockhash`
NUM_BLOCKS=$1
CUR=$START
COUNTER=$NUM_BLOCKS
curl -s -H 'Content-Type: application/json' \
--data '{"code":"newdexpublic","table":"buyorder","scope":"..........12a","json":true,"limit":1000}' \
https://eos.greymass.com/v1/chain/get_table_rows | \
jq '.rows[] | select( (.remain_convert | match("[0-9]+").string | tonumber > 5) and (.price | tonumber > 20)) | [.owner, .remain_quantity, "@", .price] | join(" ")'
@patricklodder
patricklodder / makeit.sh
Created January 10, 2016 12:48
make dogecoind linux64 natively
CORES=8
pushd depends/
make -j${CORES} NO_QT=1 NO_UPNP=1
popd
./autogen.sh
./configure --prefix=`pwd`/depends/x86_64-unknown-linux-gnu --without-gui --without-miniupnpc --enable-hardening --enable-cxx --disable-shared --with-pic CPPFLAGS="-O2" LDFLAGS=-static-libstdc++
pushd src/
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.1:compile (default-compile) on project altcoinj: Compilation failure: Compilation failure:
[ERROR] src/main/java/org/bitcoinj/core/AltcoinBlock.java:[78,72] cannot find symbol
[ERROR] symbol: class MessageSerializer
[ERROR] location: class org.bitcoinj.core.AltcoinBlock
[ERROR] src/main/java/org/bitcoinj/core/AltcoinBlock.java:[84,25] cannot find symbol
[ERROR] symbol: class MessageSerializer
[ERROR] location: class org.bitcoinj.core.AltcoinBlock
[ERROR] src/main/java/org/bitcoinj/core/AuxPoW.java:[78,89] cannot find symbol
[ERROR] symbol: class MessageSerializer
[ERROR] location: class org.bitcoinj.core.AuxPoW
@patricklodder
patricklodder / gist:1fb71b0974b9339180c7
Last active August 29, 2015 14:23
dogecoin 1.10 test report
@3de28f1
-------
accounting_tests
-------
Running 1 test case...
*** No errors detected
-------