Skip to content

Instantly share code, notes, and snippets.

View loderunner's full-sized avatar
👨‍💻
𝚌𝚘𝚍𝚎 𝚕𝚒𝚏𝚎

Charles Francoise loderunner

👨‍💻
𝚌𝚘𝚍𝚎 𝚕𝚒𝚏𝚎
View GitHub Profile
@loderunner
loderunner / 01-mac-profiling.md
Last active December 4, 2024 19:33
Profiling an application in Mac OS X

Profiling an application in Mac OS X

Finding which process to profile

If your system is running slowly, perhaps a process is using too much CPU time and won't let other processes run smoothly. To find out which processes are taking up a lot of CPU time, you can use Apple's Activity Monitor.

The CPU pane shows how processes are affecting CPU (processor) activity:

@loderunner
loderunner / osx-ld.md
Last active November 26, 2024 03:26
potential blog posts

ld – Wading through Mac OS X linker hell

Intro

Friend: I tried looking at static linking in Mac OS X and it seems nearly impossible. Take a look at this http://stackoverflow.com/a/3801032

Me: I have no idea what that -static flag does, but I'm pretty sure that's not how you link to a library. Let me RTFM a bit.

Minutes later...

@loderunner
loderunner / client.go
Last active September 20, 2024 09:16
Websocket with Gin in Go
package main
import (
"fmt"
"math/rand"
"net/http"
"time"
"github.com/gorilla/websocket"
)
const puppeteer = require('puppeteer');
const moment = require('moment');
const process = require('process');
let browser;
(async () => {
browser = await puppeteer.launch();
const url = process.argv[2];
@loderunner
loderunner / quiche-aux-epinards.md
Created March 13, 2024 16:37
Quiche aux épinards

Quiche aux épinards

Ingrédients

  • 300g épinards hachés surgelés
  • 3 oeufs
  • 30 cl de crème fraîche
  • 100g de comté râpé
  • sel
  • poivre

2023-09-12 — AG des parents

Infos de rentrée

L'école

  • Cécile et Anna - institutrices du groupe CM1-CM1 cette année
  • Il y aura un conseil d'école avec les professeurs de la ville de Paris (sports, arts plastiques, etc.)
    • Pas présents à cette AG informelle
  • Convention avec l'Education Nationale pour ne pas avoir de directeur
@loderunner
loderunner / dns-resolve.js
Last active September 4, 2023 14:34
Node dns.resolve issue
const dns = require("node:dns/promises");
const os = require("node:os");
const process = require("node:process");
function log(s) {
console.log(`${new Date().toISOString().slice(11, -1)} - ${s}`);
}
let interfaces;
export class Client {
doTheThing(message: string, count: number): boolean { /* ... */ }
}

Fondue de poireaux

Ingrédients

  • 300g de blancs de poireaux
  • 25 cl de crème fraîche
  • 1 tbsp moutarde à l'ancienne
  • 1 tsp cumin en poudre
  • 1 tsp coriandre moulue
  • sel + poivre

Dahl de lentilles corail

Ingrédients

Lentilles

  • 1 cup de lentilles corail
  • 2 cups d'eau
  • 1 cup de lait de coco
  • 1 cube de bouillon (ou 1 tbsp)