use git diff to generate file list
git diff --name-only master
add ext filter
// SPDX-License-Identifier: GPL-3.0-or-later | |
pragma solidity >=0.8.4; | |
/// @notice Modern and gas efficient ERC20 + EIP-2612 implementation. | |
/// @author Solmate (https://github.com/Rari-Capital/solmate/blob/main/src/tokens/ERC20.sol) | |
/// @author Modified from Uniswap (https://github.com/Uniswap/uniswap-v2-core/blob/master/contracts/UniswapV2ERC20.sol) | |
/// @dev Do not manually set balances without updating totalSupply, as the sum of all user balances must not exceed it. | |
abstract contract ERC20 { | |
/*/////////////////////////////////////////////////////////////// |
{ | |
"GUPPY":{ | |
"mint":"guppyrZyEX9iTPSu92pi8T71Zka7xd6PrsTJrXRW6u1" | |
}, | |
"WHALE":{ | |
"mint":"whaLeHav12EhGK19u6kKbLRwC9E1EATGnm6MWbBCcUW" | |
}, | |
"KILLER WHALE":{ | |
"mint":"kLwhLkZRt6CadPHRBsgfhRCKXX426WMBnhoGozTduvk" | |
}, |
use git diff to generate file list
git diff --name-only master
add ext filter
/* eslint-disable react/no-multi-comp, react/no-unused-state */ | |
import React from 'react' | |
import { connect } from 'react-redux' | |
import * as ReactAdmin from 'react-admin' | |
import { createSelector } from 'reselect' | |
import { Field, arrayRemove, arrayPush } from 'redux-form' | |
import { CircularProgress } from 'material-ui/Progress' | |
import Table, { | |
TableBody, | |
TableCell, |
Feel free to contact me at [email protected] or tweet at me @statisticsftw
This is a rough outline of how we utilize next.js and S3/Cloudfront. Hope it helps!
It assumes some knowledge of AWS.
const Web3 = require('web3') | |
const Tx = require('ethereumjs-tx').Transaction | |
// connect to Infura node | |
const web3 = new Web3(new Web3.providers.HttpProvider('https://mainnet.infura.io/INFURA_KEY')) | |
// the address that will send the test transaction | |
const addressFrom = '0x1889EF49cDBaad420EB4D6f04066CA4093088Bbd' | |
const privateKey = new Buffer('PRIVATE_KEY', 'hex') |
module ActiveRecordExtension | |
extend ActiveSupport::Concern | |
def self.upsert(attributes) | |
begin | |
create(attributes) | |
rescue ActiveRecord::RecordNotUnique, PG::UniqueViolation => e | |
find_by_primary_key(attributes['primary_key']). | |
update(attributes) | |
end |