Store a value globally by address on chain

Posted on Fri 11 November 2022 in tech • Tagged with Ethereum, Solidity, web3

This simple solidity example is super useful for testing transaction processing. It globally sets a value by address which will default to sender but may also be specified.

Solidity AddressStore - Save a value globally on chain


Order of evaluation for Solidity modifiers

Posted on Thu 13 October 2022 in tech • Tagged with solidity, programming, ethereum, web3, modifier

Solidity modifiers are evaluated from left to right. It makes sense to order modifiers in order of those that are most likely to fail to those that are least likely to fail. It is also a good idea to order them from most primitive to most expensive. And prerequisite conditions …


Continue reading

remove the ./ from find -print

Posted on Wed 28 September 2022 in tech • Tagged with linux, programming, bash

If you want to apply a script to each file in a folder recursively you may not want the full relative path. Here is how to remove it.

$ find . -type f -print | sed -e "s|^\./||g"

For example to combine it with xargs and invoke a script on each name …


Continue reading

Three steps to document Solididty in SPHINX

Posted on Tue 27 September 2022 in tech • Tagged with solidity, programming, ethereum, crypto, sphinx, tutorial

I was able to get solidity docgen working by implementing a series of three different stages all automated in our build process.

  1. Parse the solc output into actual json.
  2. Load the json file into the documentation system
  3. Use a Jinja template to convert the api document

There is shockingly poor …


Continue reading

How to Configure git editor in a codespace

Posted on Fri 23 September 2022 in tech • Tagged with programming, github, codespaces

How to configure git to use vscode as the default editor from your codespace:

git config --global core.editor "code --wait"


Collective Governance

Posted on Mon 22 August 2022 in tech • Tagged with solidity, programming, ethereum, web3

One of the really awesome aspects of developing an Ethereum Smart Contract for NFT Governance is that all the code is open source. For the first time in the history of my career I can share what I am working on.

Currently I am developing a smart contract for community …


Continue reading