Skip to content

Instantly share code, notes, and snippets.


Wesley Aptekar-Cassels WesleyAC

View GitHub Profile
#!/usr/bin/env bash
cd $(dirname $0)
docker run --rm -it -v "$(pwd)":/home/rust/src -v cargo-git:/home/rust/.cargo/git -v cargo-registry:/home/rust/.cargo/registry -v "$(pwd)/target/":/home/rust/src/target ekidd/rust-musl-builder:nightly-2021-01-01 sudo chown -R rust:rust /home/rust/.cargo/git /home/rust/.cargo/registry /home/rust/src/target
docker run --rm -it -v "$(pwd)":/home/rust/src -v cargo-git:/home/rust/.cargo/git -v cargo-registry:/home/rust/.cargo/registry -v "$(pwd)/target/":/home/rust/src/target ekidd/rust-musl-builder:nightly-2021-01-01 cargo build --release
WesleyAC /
Last active Jun 8, 2020
a few adblock filters to hide all "recommended" youtube videos, while still allowing watching videos and looking at specific channels.

adblock filter to hide youtube recommendataions

this is an adblock fileter to hide "recommended" videos on youtube in every place in the UI where they show up, while allowing you to watch videos and browse specific channels.

how to install

you can either copy-paste the three lines in the youtube_recommended_adblock.txt file, or you can click on the "Raw" button, and add that URL to your adblockers list of lists, in which case you will get updated rules should youtube break the current ones.

WesleyAC /
Created Jun 24, 2019
janky z80 assembler
#!/usr/bin/env python3
# vim: ts=11
# Copyright 2019 Google LLC
# SPDX-License-Identifier: Apache-2.0
# A SUPER JANK Z80 assembler, written to see if writing a assembler that parses
# the opcode table was reasonable.
# (see
WesleyAC /
Created Mar 10, 2019
quick & dirty node.js dependency analysis tools
#!/usr/bin/env python3
# Copyright 2019 Google LLC
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
View .vimrc
" <3 Vim
" This is my .vimrc
" I'm still working on it...
set nocompatible
set rtp+=~/.vim/bundle/Vundle.vim
filetype off
WesleyAC / feed.xml
Last active Nov 6, 2018
Daily Musings
View feed.xml
<?xml version="1.0" encoding="utf-8"?>
<feed xmlns="">
<title>Wesley's Daily Musings</title>
<link href=""/>
<link rel="self" href=""/>
<name>Wesley Aptekar-Cassles</name>
WesleyAC /
Created Jan 2, 2017
A hacky script to generate a plot of a trapezoidal motion profile
import numpy as np
import matplotlib.pyplot as plt
x = np.linspace(0, 10, 1000)
pdot = np.piecewise(x, [x < 4, (x >= 4) & (x <= 6), x > 6], [lambda x: x/2, 2, lambda x: -x/2 + 5])
p = []
psum = 0
for v in pdot:
WesleyAC /
Created Dec 30, 2016
Cracklepop in brainfuck
CracklePop in brainfuck
Memory architecture:
00: "\n"
01: "p"
02: "o"
03: "P"
04: "e"
05: "l"
06: "k"

Keybase proof

I hereby claim:

  • I am wesleyac on github.
  • I am wesleyac ( on keybase.
  • I have a public key whose fingerprint is 4F1A F97B 91DA C9DD F1F1 B0B9 4E9A A89C A3E0 93CE To claim this, I am signing this object:
    "body": {
        "client": {
WesleyAC / worldphysics.lua
Created Dec 13, 2013
WorldPhysics, my new, hacked together, feature creeped library for love!
View worldphysics.lua
world = {
physics = {
new = function(objtype, d, i, w, h, ubody, ushape)
if world.physics[objtype] == nil then world.physics[objtype] = {all = {}} end
world.physics[objtype].all[#world.physics[objtype].all+1] = {}
world.physics[objtype].all[#world.physics[objtype].all].body = ubody
world.physics[objtype].all[#world.physics[objtype].all].shape = ushape
world.physics[objtype].all[#world.physics[objtype].all].fixture = love.physics.newFixture(world.physics[objtype].all[#world.physics[objtype].all].body, world.physics[objtype].all[#world.physics[objtype].all].shape, d)
world.physics[objtype].all[#world.physics[objtype].all].image = i
world.physics[objtype].all[#world.physics[objtype].all].width = w