Skip to content

Instantly share code, notes, and snippets.

View feoh's full-sized avatar
💭
Excitedly diving in to my new position at MIT!

Chris Patti feoh

💭
Excitedly diving in to my new position at MIT!
View GitHub Profile
@feoh
feoh / hello_world.c
Created March 10, 2026 15:26
Claude Code attempting a large text TUI hello world in C
/*
* hello_world.c — DOS/ANSI-style big block-letter "HELLO WORLD"
*
* Build: gcc -Wall -O2 -o hello_world hello_world.c -lncurses
* (requires: sudo apt install libncurses-dev)
*/
#include <ncurses.h>
#include <string.h>
@feoh
feoh / mcp-config.json
Created December 18, 2025 22:54
A Sentry MCP configuration that works with Copilot CLI
{
"mcpServers": {
"sentry": {
"type": "local",
"command": "npx",
"args": ["@sentry/mcp-server@latest", "--host=$SENTRY_HOST"],
"tools": ["*"],
"env": {
"SENTRY_HOST": "contoso.sentry.io",
"SENTRY_ACCESS_TOKEN": "<YO DAWG ENTER YOUR SENTRY API TOKEN HERE>"
@feoh
feoh / hashmaps3.rs
Created December 2, 2024 03:43
The Solution
// hashmaps3.rs
//
// A list of scores (one per line) of a soccer match is given. Each line is of
// the form : "<team_1_name>,<team_2_name>,<team_1_goals>,<team_2_goals>"
// Example: England,France,4,2 (England scored 4 goals, France 2).
//
// You have to build a scores table containing the name of the team, goals the
// team scored, and goals the team conceded. One approach to build the scores
// table is to use a Hashmap. The solution is partially written to use a
// Hashmap, complete it to pass the test.
@feoh
feoh / hashmaps3.rs
Created December 1, 2024 23:14
Getting smacked down by the borrow checker
// hashmaps3.rs
//
// A list of scores (one per line) of a soccer match is given. Each line is of
// the form : "<team_1_name>,<team_2_name>,<team_1_goals>,<team_2_goals>"
// Example: England,France,4,2 (England scored 4 goals, France 2).
//
// You have to build a scores table containing the name of the team, goals the
// team scored, and goals the team conceded. One approach to build the scores
// table is to use a Hashmap. The solution is partially written to use a
// Hashmap, complete it to pass the test.
@feoh
feoh / hashmaps3.rs
Created December 1, 2024 20:16
Rustlings hashmaps exercise 3 fail :)
// hashmaps3.rs
//
// A list of scores (one per line) of a soccer match is given. Each line is of
// the form : "<team_1_name>,<team_2_name>,<team_1_goals>,<team_2_goals>"
// Example: England,France,4,2 (England scored 4 goals, France 2).
//
// You have to build a scores table containing the name of the team, goals the
// team scored, and goals the team conceded. One approach to build the scores
// table is to use a Hashmap. The solution is partially written to use a
// Hashmap, complete it to pass the test.
@feoh
feoh / gdsetup.sh
Last active April 1, 2026 14:54
New maching dotfile as Github home dir setup script
#!/bin/sh
echo "Remember you need SSH credentials in place. You good?"
echo "Press enter to continue or Ctrl-C to break out and fix SSH :)"
read yesorno
MYDOTFILESREPO="feoh/git_dotfiles"
echo ".cfg" >> .gitignore
# gh repo clone $MYDOTFILESREPO $HOME/.cfg
git clone --recurse-submodules git@github.com:$MYDOTFILESREPO.git $HOME/.cfg
echo "alias config='/usr/bin/git --git-dir=$HOME/.cfg/.git --work-tree=$HOME'"
alias config='/usr/bin/git --git-dir=$HOME/.cfg/.git --work-tree=$HOME'
@feoh
feoh / florida_wifi_measurements.txt
Last active March 14, 2024 02:32
Geri & Ron's Wifi Bandwidth Measurements
```
## Living Room
144 MB/s
165 MB/s
165 MB/s
## TV Room
## Computer Room
@feoh
feoh / NJJR6.ROM.txt
Created November 18, 2023 23:05
NJJR6 ROM disassembly
This file has been truncated, but you can view the full file.
RAM:0000 00 ?? 00h
RAM:0001 00 ?? 00h
RAM:0002 00 ?? 00h
RAM:0003 00 ?? 00h
RAM:0004 00 ?? 00h
RAM:0005 00 ?? 00h
RAM:0006 00 ?? 00h
RAM:0007 00 ?? 00h
RAM:0008 18 ?? 18h
RAM:0009 18 ?? 18h
@feoh
feoh / .\test_craigtest.py
Created August 20, 2021 03:57
Working version using requests_mock
import pytest
from unittest.mock import Mock, patch
import requests_mock
import craigtest
def test_get_json_success():
with requests_mock.Mocker() as m:
m.get("http://localhost:8907/apinot.json", json=
{
"blue": [
@feoh
feoh / .\craigtest.py
Created August 20, 2021 03:20
Simple API client to be tested
from unicodedata import name
from pip import main
import requests
from requests import status_codes
import logging
from sys import exit
from time import sleep
import json
import subprocess