Skip to content

Instantly share code, notes, and snippets.

View derekthecool's full-sized avatar
🏠
Working from home

Derek Lomax derekthecool

🏠
Working from home
View GitHub Profile
@derekthecool
derekthecool / clash_of_code_assembly_runner.sh
Created November 29, 2024 04:50
Clash of code assembly
#!/bin/bash
# Use a here document to write assembly code into clash.s
cat <<EOF > clash.s
.global _start
.section .data
msg:
.asciz "Hello, World!\n"
@derekthecool
derekthecool / get_wezterm.sh
Last active March 20, 2023 14:57
Downed the latest wezterm appimage
# Get the latest version and rename it to simply wezterm
curl -L https://github.com/wez/wezterm/releases/download/20221119-145034-49b9839f/WezTerm-20221119-145034-49b9839f-Ubuntu18.04.AppImage -o wezterm
# Make executable
chmod +x wezterm
# Move to location of exiting path variable, optionally using sudo
if [[ $(which sudo) ]]; then
sudo mv wezterm /usr/bin
else
read n
awk '
{ratio=$2/$3; if(ratio>oldRatio){oldRatio=ratio;name=$1}}
END{print name}'