Skip to content

Instantly share code, notes, and snippets.

@aaroncox
aaroncox / cosign_noop.js
Created Dec 11, 2019
The first action to include in a transaction to use Greymass Fuel
View cosign_noop.js
const cosign_noop = {
account: 'greymassnoop',
name: 'noop',
authorization: [
{
actor: 'greymassfuel',
permission: 'cosign',
}
],
data: {}
@aaroncox
aaroncox / authorityprovider.js
Last active Jun 3, 2020
Using a custom authority provider within eosjs for Greymass Fuel
View authorityprovider.js
// A custom cosigner AuthorityProvider for EOSJS v2
// This provider overrides the checks on all keys,
// allowing a partially signed transaction to be
// broadcast to the API node.
class CosignAuthorityProvider {
async getRequiredKeys(args) {
const { transaction } = args;
// Iterate over the actions and authorizations
transaction.actions.forEach((action, ti) => {
action.authorization.forEach((auth, ai) => {
@aaroncox
aaroncox / Dockerfile
Created Jul 4, 2019
Ubuntu 16.04 eos-voter build
View Dockerfile
FROM ubuntu:16.04
RUN rm /bin/sh && ln -s /bin/bash /bin/sh
RUN apt-get update \
&& apt-get install -y build-essential g++ gcc git curl python make libusb-dev libudev-dev libusb-1.0-0-dev \
&& apt-get -y autoclean
ENV NVM_DIR /usr/local/nvm
ENV NODE_VERSION 8.16.0
@aaroncox
aaroncox / unsigned.json
Created Aug 13, 2018
unsigned transaction format
View unsigned.json
{
"contract": {
"account": "ridlridlcoin",
"abi": {
"version": "eosio::abi/1.0",
"types": [
{
"new_type_name": "account_name",
"type": "name"
}
@aaroncox
aaroncox / nginx.conf
Last active Aug 25, 2018
nodeosd / nginx configuration
View nginx.conf
user www-data;
worker_processes auto;
worker_rlimit_nofile 65535;
pid /run/nginx.pid;
# include /etc/nginx/modules-enabled/*.conf;
events {
worker_connections 10000;
View keybase.md

Keybase proof

I hereby claim:

  • I am aaroncox on github.
  • I am jesta (https://keybase.io/jesta) on keybase.
  • I have a public key ASDn2T8U_KLuUmUq_NIq8yLEUpS3hovLg903aqpzhnOqWgo

To claim this, I am signing this object:

View gist:b426b4c407b1ea3884c4
Verifying myself: My Bitcoin username is +aaroncox. https://onename.io/aaroncox
View setup.sh
# Install HomeBrew
ruby -e "$(curl -fsSL https://raw.github.com/Homebrew/homebrew/go/install)"
# Install Git
brew install git
# Install wget
brew install wget
# Install NodeJS
@aaroncox
aaroncox / index.html
Last active Dec 18, 2015
Synchronous Build Requests
View index.html
<html>
<head></head>
<body>
<!-- ... (The rest of the page page) ... -->
<script type="text/javascript" charset="utf-8">
$(function() {
d3up.getBuild(1);
d3up.getBuild(2);
console.log(d3up.builds);
});
@aaroncox
aaroncox / d3up-v2-output.json
Last active Dec 18, 2015
D3Up Calc V2 Stats Output
View d3up-v2-output.json
{
"stats": {
"armor": 5320,
"life": 31076,
"attack-speed": 9,
"critical-hit": 49.5,
"critical-hit-damage": 190,
"strength": 1959,
"intelligence": 307,
"dexterity": 127,
You can’t perform that action at this time.