Skip to content

Instantly share code, notes, and snippets.

View martinhbramwell's full-sized avatar
🏠
Creating a serverless, offline-first, single page progressive web app with VueJS

Martin H. Bramwell martinhbramwell

🏠
Creating a serverless, offline-first, single page progressive web app with VueJS
View GitHub Profile
@martinhbramwell
martinhbramwell / mix-ide.log
Last active May 2, 2016 17:50
Messy startup log file of Ethereum Mix IDE. Mix 1.0.3. Solidity 0.3.2. Qt 5.5.1
you@xubxenmix:~$ ls -l /etc/apt/sources.list.d
total 12
-rw-r--r-- 1 root root 144 May 2 13:27 ethereum-ubuntu-ethereum-qt-xenial.list
-rw-r--r-- 1 root root 138 May 2 13:27 ethereum-ubuntu-ethereum-xenial.list
you@xubxenmix:~$ cat /etc/apt/sources.list.d/ethereum-ubuntu-ethereum-qt-xenial.list
deb http://ppa.launchpad.net/ethereum/ethereum-qt/ubuntu xenial main
you@xubxenmix:~$ cat /etc/apt/sources.list.d/ethereum-ubuntu-ethereum-xenial.list
deb http://ppa.launchpad.net/ethereum/ethereum/ubuntu xenial main
@martinhbramwell
martinhbramwell / collectInitializationPackage.sh
Last active April 24, 2016 17:57
Bundle the initialization files of an Ethereum root node
#!/bin/bash
#
source .userVars.sh
declare WORK_DIR=${HOME}/${PROJECT_DIR};
declare GETH_PATH=${WORK_DIR}/geth;
declare IPC_ENDPOINT=${GETH_PATH}/geth.ipc;
declare INITIAL_FILES_ARCHIVE="/tmp/initialFiles.tar.gz";
@martinhbramwell
martinhbramwell / initialTrivialMiningScript.js
Last active September 29, 2017 11:38
Trivial mining script for a private block chain to create some initial pseudo-ether for testing purposes.
primary = eth.accounts[0];
balance = web3.fromWei(eth.getBalance(primary), "ether");
miner.setEtherbase(primary)
console.log(" -Starting mining.");
miner.start(8); admin.sleepBlocks(3); miner.stop() ;
console.log(" - Mined 3 blocks ");
balance = web3.fromWei(eth.getBalance(primary), "ether");
@martinhbramwell
martinhbramwell / initializeEthereumTestNode.sh
Last active September 29, 2017 11:36
Initialize Ethereum test network node
#!/bin/bash
# ############################################################################
#
# This bash script will set up a private Ethereum test network.
#
# It can do either a "root node" or a "client node". It will prompt for
# initial parameters and then do all the rest of the work for you.
#
# Executed in a "client node" it will use SSH and SCP to get
@martinhbramwell
martinhbramwell / Genesis.json
Created April 22, 2016 18:23
A private network genesis block for Ethereum devlopment
{
"nonce": "0x0000000000000042",
"timestamp": "0x0",
"parentHash": "0x0000000000000000000000000000000000000000000000000000000000000000",
"extraData": "0x0",
"gasLimit": "0x8000000",
"difficulty": "0x400",
"mixhash": "0x0000000000000000000000000000000000000000000000000000000000000000",
"coinbase": "0x3333333333333333333333333333333333333333",
"alloc": {}
@martinhbramwell
martinhbramwell / host.sh
Last active April 20, 2016 18:35
Prepare Ethereuem private network
#!/bin/bash
#
export ACCOUNT_PASSWORD="plokplok";
export NETWORK_ID="7028";
export DROP_DAGS="no";
export DROP_BLOCKCHAIN="no";
export DROP_CLIENTfILES="no";
if [[ 0 -eq 0 ]]; then
# These are my notes on how I prepared to do Ether mining with this machine :
# * Ubuntu Trusty 64bit
# * Radeon R9 380
#
# This is my first try. I doubt if I will succeed.
#
## Prepare for building in Ubuntu
##################################
@martinhbramwell
martinhbramwell / FirstPage.md
Last active February 20, 2022 23:26
A liittle toolkit for testing AWK scripts

.left-column[

Left Title




No manual input required here.

.footnote[.red.bold[] Table of Contents]

]

.right-column[ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ - o 0 o - ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~

Friendly Title

#!/bin/bash
#
# Install prerequisites
echo "Did you remember to prefix with sudo?"
read _
# -- Get PPAs for Oracle Java 7 and Sublime Text editor --
sudo add-apt-repository -y ppa:webupd8team/java
sudo add-apt-repository -y ppa:webupd8team/sublime-text-3
#! /usr/bin/env node
var DEBUG = false;
if ( process.env.DEBUG ) {
DEBUG = true;
}