Skip to content

Instantly share code, notes, and snippets.

View santteegt's full-sized avatar
💭
BuiDLing

Santiago Gonzalez Toral santteegt

💭
BuiDLing
View GitHub Profile

hlxwrjf7em

import { NomadContext, NomadMessage } from "@nomad-xyz/sdk";
async function main() {
const network = "rinkeby";
const RPC_URI = ""; // i.e. Infura
const core = new NomadContext("development");
core.registerRpcProvider(network, RPC_URI);
const txHash = "0x14931ab91c03181ae46a5c90d3b52ac8dd9128e8877bb12058607fc3a2c7330e";
@santteegt
santteegt / attestation.txt
Created September 11, 2021 22:08
Attestation
I contributed to the clr.fund Trusted Setup Multi-Party Ceremony.
The following are my contribution signatures:
Circuit: qvt32
Contributor # 2318
Hash: 9ca9a924 578ac646 2de574a4 34927e1b
26f331b6 d069be06 6adb22a8 c5a1a32d
d618bae4 fec8676e ee7ca229 7e7e9f45
2fe8054f 28fba590 9d7ae8dd af0760e9
@santteegt
santteegt / MinionSafeService.jsx
Created September 11, 2021 02:26
Some methods I Implemented to make a Moloch minion interact with a Gnosis Safe. Deprecated but keeping this for posterity
// import EthersSafe, {
// SafeTransactionDataPartial,
// } from '@gnosis.pm/safe-core-sdk';
// import { OperationType } from '@gnosis.pm/safe-core-sdk-types';
import { ethers } from 'ethers';
import Web3 from 'web3';
// import { ecrecover, toBuffer } from 'ethereumjs-util';
import minionSafeModuleEnablerAbi from '../contracts/minionSafeModuleEnabler.json';
// import safeCreateAndAddModulesAbi from '../contracts/safeCreateAndAddModule.json';
@santteegt
santteegt / script.js
Last active August 31, 2022 21:49
Calculate ProxyAddress from a Given CREATE2 call - Example using GnosisSafe
// This script assume using the GnosisSafe & GnosisSafeProxyFactory from here
// https://github.com/gnosis/safe-contracts/blob/v1.2.0/contracts/proxies/GnosisSafeProxyFactory.sol
// safe -> https://github.com/gnosis/safe-contracts/blob/v1.2.0/contracts/GnosisSafe.sol
import { ethers } from 'ethers';
import Web3 from 'web3';
import * as ethUtil from 'ethereumjs-util';
import abi from 'ethereumjs-abi';
const rpcUrl = ''; // Fill your RPC URI
@santteegt
santteegt / Quiz.ipynb
Last active January 31, 2021 01:54
TECLab weekend pop quiz. Inspired form https://github.com/gitcoinco/gitcoin_cadcad_model
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

did:3:bafyreicvls4l7wheywfw5nqwkq7kp5lyghi6wf656ijftc5fn7pou56gzy

@santteegt
santteegt / index.js
Last active September 8, 2020 02:30
Example code on how to upload files to an S3 bucket using AWS SDK
#!/usr/bin/env node
// HOW to setup a Nodejs project and configure access credentials:
// https://docs.aws.amazon.com/sdk-for-javascript/v2/developer-guide/getting-started-nodejs.html
require('dotenv').config();
const program = require('commander')
const mime = require('mime-types')
const AWS = require('aws-sdk')
const fs = require('fs')
@santteegt
santteegt / robot-marbles-part-6.ipynb
Created July 17, 2020 00:46
robot-marbles-part-6.ipynb
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
import nbformat
import nbconvert
import logging
import sys
import time
# import wget
logger = logging.getLogger(__name__)
ep = nbconvert.preprocessors.ExecutePreprocessor(timeout=5000)