Skip to content

Instantly share code, notes, and snippets.

View andrewxhill's full-sized avatar

Andrew W. Hill andrewxhill

View GitHub Profile
@andrewxhill
andrewxhill / README.md
Last active December 14, 2023 18:52
A list of frameworks for decision making and where they are most helpful.
Framework (starter video) Internal & External Factors Analysis Competitive Environment Analysis Product/Market Growth Strategy Performance Measurement Decision Path Analysis Financial Evaluation Risk Identification & Management Organizational Alignment
SWOT Analysis
PESTLE Analysis
@andrewxhill
andrewxhill / Chain Of Trust (but verify).ipynb
Last active November 8, 2023 06:14
Chain of Trust - but verify...
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@andrewxhill
andrewxhill / TransferLogs.sol
Created May 4, 2023 18:53
Generate queryable ownership records and transfer logs in any ERC721. This example is extending OpenZepplin functions. You can see the contract here https://mumbai.polygonscan.com/address/0xB837771546756D58d2EB79CDb0281Bc5F84bC704 and the owner logs here https://testnets.opensea.io/assets/mumbai/0x4b48841d4b32c4650e4abc117a03fe8b51f38f68/5969 an…
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.12;
import "@openzeppelin/contracts@4.8.3/token/ERC721/ERC721.sol";
import "@openzeppelin/contracts@4.8.3/token/ERC721/extensions/ERC721Burnable.sol";
import "@openzeppelin/contracts@4.8.3/token/ERC721/utils/ERC721Holder.sol";
import "@openzeppelin/contracts@4.8.3/access/Ownable.sol";
import "@openzeppelin/contracts@4.8.3/utils/Counters.sol";
import "@tableland/evm/contracts/ITablelandTables.sol";
import "@tableland/evm/contracts/utils/TablelandDeployments.sol";
@andrewxhill
andrewxhill / ReadTablelandValue.sol
Last active November 29, 2022 00:24
Uses midpointapi.com to return a single cell value from any table or sql request on Tableland
// SPDX-License-Identifier: UNLICENSED
pragma solidity ^0.8.17;
import "@openzeppelin/contracts/utils/Strings.sol";
import "@openzeppelin/contracts/utils/structs/EnumerableMap.sol";
interface IMidpoint {
function callMidpoint(uint64 midpointId, bytes calldata _data) external returns(uint256 requestId);
}
// trigger bridge deposit for a user with their wallet
const onSubmit = () => {
api
.addDeposit()
.then(() => setDeposit(true))
.catch((err: Error) => alert(err.message));
};
@andrewxhill
andrewxhill / go.mod
Created March 16, 2021 21:36
hello-remote-threads.go
module github.com/textileio/hello-go-threads
go 1.15
require (
github.com/textileio/go-datastore v0.4.5-0.20200819232101-baa577bf9422 // indirect
github.com/textileio/textile v1.0.14 // indirect
github.com/textileio/textile/v2 v2.6.5 // indirect
github.com/wangjia184/sortedset v0.0.0-20160527075905-f5d03557ba30 // indirect
)
@andrewxhill
andrewxhill / index.md
Last active June 5, 2022 13:42
Powergate Workshop

Introduction to Filecoin app building

This document: https://tinyurl.com/hackfs-pow

Slides from intro presentation: https://speakerdeck.com/andrewxhill/intro-to-filecoin-building-apps-with-powergate

In this workshop, we are going to introduce you to Filecoin through the use of the Powergate. While you can develop using Lotus or other Filecoin implementations directly, the Powergate is designed to provide the necessary abstractions to build Filecoin storage into your application. Some features of the Powergate include fast data retrieval with IPFS serving as a caching layer, deal management, multi-tenant wallet APIs, and more. The system comes set up to run locally in Docker or deploy to your servers.

We'll cover the Powergate CLI and the Powergate JavaScript Client in the two parts of the workshop. To prepare, we encourage you to install a few things before we get started.

<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0, shrink-to-fit=no">
<meta name="description" content="Template cloned from https://github.com/erengy/under-construction.">
<title>textile.io</title>
<style type="text/css">
html, body {
height: 100%;

On chatting to people

Chat is not the same as conversation. When you tag someone using the "@" or if you send them a direct message, you may be directly forcing them to change their focus to your problem. While this is good for you, it can be bad for a healthy and productive community. Here are a couple of rules to abide.

  • Only "@" tag people's names in the following cases.
    • Your comment is urgent/time-sensitive and you need the help of the "@" target. What is urgent? You are running a production application with 100s of users facing a broken API, it's urgent. You are experimenting or taking part in a competition and want an answer quickly, it's not urgent.
    • Your comment has grown stale and you still need an answer that the "@" target can provide. What is stale? In most cases, more than 2 days seems reasonable or if it's a weekend, 3 or more.
    • You comment is in a channel or thread where the "@" target is not present but you need them aware.
  • Abide by the "no hello" rule at all times. Provide