Skip to content

Instantly share code, notes, and snippets.

@hi-ogawa
hi-ogawa / README-1-go-ethereum.md
Last active September 25, 2023 16:24
Ethereum ecosystem

go-ethereum

Summary

  • debugger setup
  • main entrypoint
  • rpc handler
  • p2p/eth66 handler
  • new block execution
  • evm
@hi-ogawa
hi-ogawa / url-json.ts
Created January 23, 2022 01:43
url-json.ts
/*
URL safe json
cf.
- https://www.json.org/json-en.html
- https://github.com/Sage/jsurl
- https://url.spec.whatwg.org/#application-x-www-form-urlencoded-percent-encode-set
- ASCII alphanumeric, U+002A (*), U+002D (-), U+002E (.), and U+005F (_)
@hi-ogawa
hi-ogawa / README.md
Last active February 21, 2022 04:26
Reading PostgreSQL
@hi-ogawa
hi-ogawa / README.md
Last active August 29, 2023 07:49
Reading React

todo / summary

  • dev setup (debugger, testing, ...)
  • build system and package organization
    • patching ReactFiberHostConfig and ReactSharedLibrary (cf. scripts/shared/inlinedHostConfigs.js)
    • rollup, babel, jest configurations
  • hook and rendering lifecycle
    • mount
    • update
    • unmount
@hi-ogawa
hi-ogawa / README.md
Last active July 2, 2022 03:45
vscode gist auto save

vscode gist auto save

  • .vscode/settings.json
{
  "emeraldwalk.runonsave": {
    "commands": [
      {
 "match": "gists/[^/]+/*",
@hi-ogawa
hi-ogawa / README.md
Last active November 8, 2024 08:26
Reading V8

reading v8

todo / summary

  • editor setup
    • compilation database
    • vscode debugger
      • debug cctest
      • debug mjsunit
  • testing
@hi-ogawa
hi-ogawa / README.md
Last active March 30, 2022 23:43
init-monorepo.sh

init-monorepo

TODO

  • we can keep the history under the subdirectory via --to-subdirectory-filter
git filter-repo --source "$tmp_dir/$package" --target "$tmp_dir/$package" --to-subdirectory-filter "packages/$package" --commit-callback "commit.message += b'\n\nPreMonorepoCommit: https://github.com/$repository/commit/' + commit.original_id + b'\n'"
@hi-ogawa
hi-ogawa / README.md
Last active April 7, 2022 01:03
mysql
@hi-ogawa
hi-ogawa / squash-and-merge.sh
Last active April 13, 2022 01:40
squash-and-merge.sh
#!/bin/bash
set -eux -o pipefail
# Usage
# repository=<...> branch=<...> message=<...> bash squash-and-merge.sh
# validate arguments
[ -z "${repository:-}" ] && { echo "required 'repository'"; exit 1; }
[ -z "${branch:-}" ] && { echo "required 'branch'"; exit 1; }
[ -z "${message:-}" ] && { echo "required 'message'"; exit 1; }