Skip to content

Instantly share code, notes, and snippets.

View DougAnderson444's full-sized avatar
🕸️
Open Web, all the way

Doug A DougAnderson444

🕸️
Open Web, all the way
View GitHub Profile
@DougAnderson444
DougAnderson444 / github-workflows-rust.yml
Last active February 5, 2024 23:20
Github Action to build & deploy Leptos Website
name: Build Rust & Deploy Leptos Page
on:
push:
branches: ["master"]
pull_request:
branches: ["master"]
# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages
permissions:
@DougAnderson444
DougAnderson444 / chadrd.lua
Created October 6, 2023 23:44
Initial ChadRC File
local M = {}
M.plugins = "custom.plugins"
-- key mapping file
M.mappings = require "custom.mappings"
-- set our custom plugins.lua file here
M.ui = {
theme = "chadracula",
@DougAnderson444
DougAnderson444 / hd-wallet.md
Created August 11, 2023 15:55
Hierarchical Deterministic Wallets - Hardened versus Non-hardened Keys

Hardened vs Non-hardened

With non-hardened keys, one can derive child public keys of a given non-hardened parent key without knowing any private key.

You cannot do this with hardened keys.

Non-Hardened Security Risks

Knowledge of a parent extended public key plus any non-hardened private key descending from it is equivalent to knowing the parent extended private key (and thus every private and public key descending from it).

@DougAnderson444
DougAnderson444 / VouchedDiscovery.md
Last active August 2, 2023 01:02
Vouched Discovery

So let's say I want to find someone in Web3 by some contact information I have about them.

  • Phone number
  • Email address
  • Physical address
  • First name

...whatever.

Let's assume there's a network where anyone can save this sort of information, like IPFS / libp2p.

// relevant issue:
https://github.com/sveltejs/kit/issues/2040
npm i typescript-transform-extensions ts-patch -D
// tsconfig.json
"plugins": [
{
"transform": "typescript-transform-extensions",
"extensions": {
@DougAnderson444
DougAnderson444 / rebase.txt
Created October 4, 2022 10:27
Rebase Brave Wallet Gist
I am attesting that this GitHub handle douganderson444 is linked to the Ethereum Address 0xF0bF4A0bd142123Fd8aD2a5b35d8dF8fcf8077b6
0x64792b7e3bcc75ef911ae9108942597ac27fe6d46b130199afa838771164383a4ad735297293581809afba367ee89a2570838feb2b53555e7f2c90d409f2a98c1b
@DougAnderson444
DougAnderson444 / anchor_declare_id.txt
Created September 14, 2021 10:02
Value for the declare_id field of the Solana Anchor program
Ref: https://discord.com/channels/739225212658122886/838515957042774038/886918683203625001
regarding the hardcoded value in the declare_id field of the rust program, the workflow look like this:
1. build only with placeholder ID
2. solana address -k <the-program-keypair-in-target-deploy-folder>
3. Update lib.rs
4. build AND deploy
@DougAnderson444
DougAnderson444 / gist:5933c8ada7a6a40dcf925d83ca4622c2
Created September 13, 2021 16:20
Solana build from source on Windows
$ ./scripts/cargo-install-all.sh .
needs... clang stuff, so add with:
$ choco install llvm
@DougAnderson444
DougAnderson444 / bash-command.txt
Created September 8, 2021 19:40
Git bash command format
sh -c "$(./scripts/cargo-install-all.sh .)"
<script>
import { onMount } from "svelte";
export let methods; // prop passed in from main.js
let answer = "Loading...";
onMount(async () => {
const ans = await methods.getAnswer(); // via RPC proxy and Deno server
answer = ans.result;