Skip to content

Instantly share code, notes, and snippets.

View jmcph4's full-sized avatar

Jack McPherson jmcph4

View GitHub Profile
#!/usr/bin/env bash
set -euo pipefail
if [[ "${1:-}" == "-h" || "${1:-}" == "--help" ]]; then
echo "Usage: attrib [COMMIT_HASH] [AUTHOR_NAME]"
echo
echo "Defaults:"
echo " COMMIT_HASH = git rev-parse HEAD"
echo " AUTHOR_NAME = jmcph4"
exit 0
#!/usr/bin/env python3
# Extract TOP500 listings for a given country from the provided XML.
# Source schema example: :contentReference[oaicite:0]{index=0}
import argparse
import csv
import json
import sys
import xml.etree.ElementTree as ET
from typing import Dict, List, Optional
@jmcph4
jmcph4 / hoom.rs
Last active September 28, 2025 03:14
use std::fmt::Display;
use clap::{Parser, Subcommand};
#[derive(Copy, Clone, Debug)]
pub enum Cost {
Fixed(f64),
Proportion((f64, f64)),
}
@jmcph4
jmcph4 / pelag.html
Last active September 13, 2025 05:56
<html>
<body>
<ul>
<li>[2025-09-09T18:56:12+10:00] <a href="https://doc-en.rvspace.org/JH7110/PDF/JH7110_Product_Brief.pdf">StarFive JH-7110 Product Brief (PDF)</a></li>
</ul>
<hr />
<ul>
<li>[2025-09-09T18:56:12+10:00] <a href="https://wiki.osdev.org/RISC-V">RISC-V - OSDev Wiki</a></li>
</ul>
<hr />
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
// cargo-deps: tokio={version="1", features=["full"]}
// Event-driven Tokio example that reacts to multiple kinds of events using `tokio::select!`.
//
// It concurrently handles:
// - incoming TCP connections
// - periodic timer ticks
// - messages arriving on an mpsc channel
// - Ctrl+C for graceful shutdown
//
// Run: `cargo run` then (optionally) `nc 127.0.0.1 8080` in another shell.
Law firm Example ASX IPO advised Role Date (AEST) Source
King & Wood Mallesons 29Metals Limited (ASX:29M) Issuer counsel 2021-06-29 KWM press release
Herbert Smith Freehills Guzman y Gomez Limited (ASX:GYG) Joint lead managers’ counsel 2024-06-20 HSF press release
Allens Redbubble Ltd (ASX:RBL) Issuer counsel 2016-05-23 [Allens press release](https://www.allens.com.au/insights-new
{
"url": "https://www.sec.gov/Archives/edgar/data/1690110/000188852425014170/ccr16c07_absee-202508.htm",
"assets": [
{
"assetTypeNumber": "Prospectus Loan ID",
"assetNumber": 1,
"GroupID": 1,
"reportingPeriodBeginningDate": "2025-07-08",
"reportingPeriodEndDate": "2025-08-06",
"originatorName": "JPMCB/DBNY/GSMC/Barclays/MSBNA",
use eyre::{eyre, WrapErr};
use regex::Regex;
use reqwest::{Client, Url};
use serde::Deserialize;
use std::{collections::{HashMap, HashSet}, time::Duration};
use tokio::time::Instant;
// --------------------------- Public API ---------------------------
#[derive(Clone, Debug)]