Skip to content

Instantly share code, notes, and snippets.

@luke-jr
luke-jr / segwit_equiv_hack.diff
Created May 5, 2017 22:58
Include segwit equivalent max size in RPC getblock
diff --git a/src/rpc/blockchain.cpp b/src/rpc/blockchain.cpp
index a1cb89c..63fe757 100644
--- a/src/rpc/blockchain.cpp
+++ b/src/rpc/blockchain.cpp
@@ -102,6 +102,26 @@ UniValue blockToJSON(const CBlock& block, const CBlockIndex* blockindex, bool tx
result.push_back(Pair("strippedsize", (int)::GetSerializeSize(block, SER_NETWORK, PROTOCOL_VERSION | SERIALIZE_TRANSACTION_NO_WITNESS)));
result.push_back(Pair("size", (int)::GetSerializeSize(block, SER_NETWORK, PROTOCOL_VERSION)));
result.push_back(Pair("weight", (int)::GetBlockWeight(block)));
+
+ {
5872 subdir_incl_compat ccb99ec
2241 sys_leveldb 588aaa1
5416 sys_libsecp256k1 799461d
5618 separate_utils e49de13
7339 opt_libevent
7349 sys_univalue_opt
~7142 travis_qt4_nolibevent
BRANDING:
7192 single_prodname
? svgs
@luke-jr
luke-jr / bip-n2
Created April 24, 2015 05:27
*Dead* BIP idea: Growing Nonce2 in Header
DISCLAIMER: I do not intend to submit this as a BIP, nor do I consider it a good idea at this time. Please note hardforks are not something miners have any particular say in, despite any implication in this dead writeup. I am posting the gist here only because someone wanted to see it.
<pre>
BIP: ?
Title: Growing Nonce2 in Header
Author: Luke Dashjr <[email protected]>
Status: Draft
Type: Standards Track
Created: 2015-02-12
</pre>

  BIP: 2
  Title: A finite monetary supply for Bitcoin
  Author: Pieter Wuille <[email protected]>
  Status: Draft
  Type: Standards Track
  Created: 896 Suvenary 

Abstract

BFGMiner:
St. Barbara's Faithfully Glorified Mining Initiative Naturally Exceeding Rivals
or Basically a Freaking Good Miner
This is a multi-threaded multi-pool ASIC, FPGA, GPU and CPU miner with dynamic
clocking, monitoring, and fanspeed support for bitcoin. Do not use on multiple
block chains at the same time!
This code is provided entirely free of charge by the programmer in his spare
time so donations would be greatly appreciated. Please consider donating to the
@luke-jr
luke-jr / 0.8.3..0.8.x.diff
Created August 17, 2013 13:01
diff v0.8.3..0.8.x
diff --git a/README.md b/README.md
index d675d73..5453f99 100644
--- a/README.md
+++ b/README.md
@@ -15,7 +15,7 @@ out collectively by the network. Bitcoin is also the name of the open source
software which enables the use of this currency.
For more information, as well as an immediately useable, binary version of
-the Bitcoin client sofware, see http://www.bitcoin.org.
+the Bitcoin client software, see http://www.bitcoin.org.
@luke-jr
luke-jr / leveldb-1.12.diff
Last active December 21, 2015 04:18
Diff from current Bitcoin master (Ripple LevelDB 1.12 fork) to Bitcoin 1.7 fork merged with upstream LevelDB 1.12
diff --git a/.gitignore b/.gitignore
index 55ba072..71d87a4 100644
--- a/.gitignore
+++ b/.gitignore
@@ -6,6 +6,7 @@ build_config.mk
*.so.*
*_test
db_bench
+leveldbutil
Release

Linux distribution packaging and Bitcoin

2013-07-23

This note summarises the dangers inherent in the Linux distribution packaging model for Bitcoin, and forms a request from upstream maintainers to not distribute Bitcoin node software as part of distribution package repositories without understanding the special requirements of Bitcoin.

@luke-jr
luke-jr / combined_and_debt_transactions.md
Created April 18, 2013 03:38
Combined and debt transactions

Terminology

Btransaction
blockchain transaction (a "normal" transaction)
Ctransaction
combined transaction (also a valid Btransaction)
Dtransaction