Skip to content

Instantly share code, notes, and snippets.

View jemc's full-sized avatar

Joe Eli McIlvain jemc

  • TheoremOne
  • Cascadia
View GitHub Profile
@jemc
jemc / gh-enable-all-inactivity-disabled-workflows.fish
Created October 20, 2023 15:14
Use GitHub CLI to enable all workflows that were disabled due to repository inactivity - either for all repos in a given org that you manage, or (by default) your personal repos.
function gh-enable-all-inactivity-disabled-workflows
set org $argv[1]
gh repo list $org | cut -f 1 | xargs -I REPO sh -c 'gh workflow list --all -R REPO | grep disabled_inactivity | cut -f 3 | xargs -I WORKFLOW sh -xc "gh workflow enable WORKFLOW -R REPO"'
end
interface val Auth
fun val apply[B: Auth val](): B ? =>
this as B
fun val add(that: Auth): AuthSet =>
AuthSet(this, that)
class val AuthSet is Auth
let _a: Auth
let _b: Auth
@jemc
jemc / comp-sci-notation.md
Last active January 17, 2022 18:42
An informal glossary of formal notation commonly used in academic papers relevant to computer science

Overview

Laypersons who are not trained in the relevant formal notation may sometimes feel lost when trying to read academic papers on computer science.

This gist is intended to be a short introductory "cheat sheet" for some of the symbols we may encounter in such papers, to help make the work more accessible to a broader audience, particularly those working in the software industry looking to gain a deeper understanding into formal computer science.

In addition to this introductory glossary of symbols, it may also be helpful to reference this glossary of terms so that the formal usage of certain words can be known to the reader.

One can also read a great bit more detail on this topic in The Formal Semantics of Programming Languages, a text introducing a lot of details in formal notation.

@jemc
jemc / .gitignore
Last active September 5, 2021 02:03
pony-sdl-wrapper
*.so
*.o
TAGS
pony-sdl-example
@jemc
jemc / docker-on-m1.md
Created February 13, 2021 13:19
Docker on M1

Follow instructions here to get qemu setup working

Keybase proof

I hereby claim:

  • I am jemc on github.
  • I am jemc (https://keybase.io/jemc) on keybase.
  • I have a public key whose fingerprint is 5055 37F5 8770 7D46 5A22 5D35 1858 AD28 B2A9 65CC

To claim this, I am signing this object:

sudo dd if=/dev/sdb2 bs=512 count=1953523711 conv=sync,noerror | pv -s 931G | sudo dd of=/run/media/liveuser/f09ad2eb-b80a-4bae-ac9a-33c71b6aa191/disk-image-2020-01-02.dd
set -ex
# This script sets up a fresh Raspberry Pi 2 with Raspbian for the purposes
# of driving a string of color-changing LEDs to act as Christmas lights.
# I've written this out because it's common for the flash to get corrupted
# and have to start over fresh from recovery mode.
sudo apt-get remove wolfram-engine # way too huge and unnecessary
sudo apt-get update
sudo dnf install -y boost-devel glibmm24-devel libsndfile-devel libarchive-devel liblo-devel taglib-devel vamp-plugin-sdk-devel rubberband-devel fftw-devel aubio-devel pangomm-devel liblrdf-devel libsamplerate-devel lv2-devel serd-devel sord-devel sratom-devel lilv-devel gtkmm24-devel
let alloc_fn = @{(size: USize): Pointer[U8] =>
@pony_alloc[Pointer[U8]](@pony_ctx[Pointer[None] iso](), size)
}
let realloc_fn = @{(p: Pointer[U8], oldsz: USize, sz: USize): Pointer[U8] =>
@pony_realloc[Pointer[U8]](@pony_ctx[Pointer[None] iso](), p, sz)
}
let free_fn = @{(p: Pointer[U8], size: USize) =>