Skip to content

Instantly share code, notes, and snippets.

View bplaat's full-sized avatar
💻
Working from home on cool shit...

Bastiaan van der Plaat bplaat

💻
Working from home on cool shit...
View GitHub Profile
@bplaat
bplaat / macos-setup.md
Last active May 21, 2025 12:08
macOS Setup

macOS Setup

  • Setup macOS
  • Setup displays, user avatar, appearance color and wallpaper
  • Keyboard switch ctrl <-> command keys and key repeat time
  • Install homebrew
    /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
  • Install essential casks
@bplaat
bplaat / link.md
Last active January 29, 2025 12:30
JavaScript matrix benchmark
@bplaat
bplaat / sind24.md
Created November 17, 2024 14:23
Sinterklaas Lootje 2024

Sinterklaaslootje 2024

Je maakt mij het meest blij met (kan je alleen tweedehands kopen):

  • Buck Danny - De zwarte draak
  • Evert Hartman - Vechten voor overmorgen
  • Evert Hartman - Niemand houdt mij tegen
  • Evert Hartman - De vloek van Polyfemos
  • Evert Hartman - De voorspelling

Maar dit wil ik ook graag (als het te duur is betaal ik het verschil):

@bplaat
bplaat / .gitconfig
Last active January 19, 2025 20:43
Bassie's gitconfig
[user]
name = Bastiaan van der Plaat
email = [email protected]
[core]
autocrlf = false
editor = nano
[help]
autocorrect = prompt
[fetch]
prune = true
@bplaat
bplaat / README.md
Last active June 18, 2024 09:29
Python TLS Client Auth Example

Python TLS Client Auth Example

Generate certs

openssl req -new -newkey rsa:2048 -days 3650 -nodes -x509 -subj "/CN=ca" -keyout ca.key -out ca.crt

openssl req -new -newkey rsa:2048 -days 3650 -nodes -x509 -subj "/CN=localhost" -config <(cat <<EOF
[req]
x509_extensions = v3_req
[v3_req]
@bplaat
bplaat / Cargo.toml
Last active May 29, 2024 08:41
Rust raw https request example
[package]
name = "bassietest"
version = "0.1.0"
edition = "2021"
[dependencies]
anyhow = "1.0"
rustls = { version = "0.23", default-features = false, features = ["std", "tls12", "ring"] }
webpki-roots = "0.26"
@bplaat
bplaat / wpt-runner.py
Created March 26, 2024 17:35
Simple WPT tests runner script for Ladybird
#!/usr/bin/env python3
# Simple WPT tests runner script for Ladybird
# Usage: ./wpt-runner.py dom/
import subprocess
import sys
import requests
from bs4 import BeautifulSoup
bin_path = "Build/lagom/bin/Ladybird.app/Contents/MacOS"
@bplaat
bplaat / ws.c
Created November 10, 2023 16:04
A bare bones websocket client written in C
#include <stdio.h>
#include <stdint.h>
#include <time.h>
#ifdef _WIN32
#include <winsock2.h>
#else
#include <sys/socket.h>
#include <netinet/in.h>
#include <netdb.h>
#include <unistd.h>
@bplaat
bplaat / sint23.txt
Last active November 8, 2023 16:16
Sinterklaas Lootje 2023
Hey Sinterklaas,
Voor de liefhebber:
be 1b 01 bf 00 80 ac 34 69 84 c0 74 03 aa eb f6 b4 09 ba 00 80 cd 21 b4 4c cd 21 3a 00 07 1d 0c 1b 02 05 08 08 1a 49 05 06 06 1d 03 0c 49 5b 59 5b 5a 49 41 01 1d 1d 19 1a 53 46 46 10 06 1c 1d 1c 47 0b 0c 46 0f 03 3b 0a 20 2b 39 39 19 50 59 56 1d 54 5b 5c 40 63 63 21 0c 10 49 03 0c 49 01 0c 0b 1d 49 01 0c 1d 49 05 06 06 0d 03 0c 49 0e 0c 1d 1b 06 02 02 0c 07 49 1f 08 07 49 0c 0c 07 0c 49 2b 08 1a 1a 00 0c 2b 28 3a 49 0d 0c 1b 49 39 05 08 1d 06 1a 45 49 41 01 1d 1d 19 1a 53 46 46 10 06 1c 1d 1c 47 0b 0c 46 50 3e 1c 03 01 21 0a 38 01 51 02 56 1d 54 5a 50 5d 51 40 63 3e 08 1d 49 05 0c 1c 02 49 07 1c 49 04 08 0e 49 03 0c 49 13 06 06 00 49 1f 06 06 1b 49 01 0c 04 49 0e 08 08 07 49 02 06 19 0c 07 49 1d 0c 1b 1e 00 03 05 49 03 0c 49 0d 08 1d 49 0c 00 0e 0c 07 05 00 03 02 49 07 00 0c 1d 49 1e 00 05 1d 49 0d 06 0c 07 52 49 41 01 1d 1d 19 1a 53 46 46 10 06 1c 1d 1c 47 0b 0c 46 5b 51 0f 06 0e 07 0e 26 24 31 2c 56 1d 54 51 5a 51 40 63 06 04 49 01 0c 1d 49 1d 06 0a 01 49 1e 08 1d 49 0
@bplaat
bplaat / config.json
Created November 3, 2023 08:29
BassieLight Stamlokaal config
{
"name": "Stamlokaal",
"version": "0.1.0",
"author": "Bastiaan van der Plaat <[email protected]>",
"fixtures": [
{
"name": "led1x1",
"label": "LED 1x1",
"type": "p56led",
"addr": 1