Skip to content

Instantly share code, notes, and snippets.

@joske
joske / alpm-2-deb.sh
Last active July 1, 2025 08:57
convert an Arch ALPM package to a debian package
#!/usr/bin/env bash
set -euo pipefail
ORIG=$(pwd)
TEMP=$(mktemp -d)
cleanup() {
local status=$?
cd "$ORIG" || true
@joske
joske / Firmware update.md
Last active May 14, 2025 08:01
Firmware update on asahi

Firmware update

  • boot into Linux
  • edit /etc/fstab and comment out the line with /boot/efi
  • reboot into macOS
  • mount the EFI partition of your linux install with diskutil mount 'EFI - LINUX' or similar (check the correct name with diskutil list)
  • copy the contents of this partition (using finder or cp) somewhere in macOS
  • unmount the partition again with diskutil umount 'EFI - LINUX'
  • wipe the APFS container (2.5 GB) using diskutil apfs deleteContainer disk0s3 !! double and triple check the device id !!
  • wipe the EFI partition (500MB) using diskutil eraseVolume free free disk0s4
@joske
joske / flowcharts.md
Last active March 12, 2025 20:46
Move LLVM

High Level

flowchart TD
    A([Start]) --> B[Create Move Model]
    B --> C[For All Modules]
    C --> translate[Translate Module]
    translate --> write[Write Object File]
    write --> isdone{All Modules Done?}
    isdone --> |No| C 
 isdone --> |Yes| F([End])
#!/bin/bash
declare -A mappings
mappings["bankstown"]="lv2-bankstown"
mappings["widevine"]="widevine-installer"
mappings["lzfse"]="lzfse-libs"
mappings["FEX-Emu"]="fex-emu"
mappings["fex-emu-rootfs-arch"]="fex-emu-rootfs-fedora"
mappings["linux-asahi"]="kernel-16k"
@joske
joske / yoga7x-speakers.md
Last active March 30, 2025 19:53
Speakers on Yoga Slim 7x

Speakers on Yoga Slim 7x

DISCLAIMER: I'm not responsible for broken speakers! Use this at your own risk. It works on my system but that doesn't mean it will work on yours!

TPLG

@joske
joske / arch-yoga.md
Last active June 23, 2025 08:21
Arch Linux Arm on Lenovo Yoga Slim 7x (X elite)

Arch

This is the method I used to install Arch on the yoga slim 7x. This is from memory so I may have forgotten things

prerequisites

  • disable bitlocker in windows
  • resize the windows partition
  • disable secure boot in BIOS

installation

tap "homebrew/bundle"
tap "homebrew/cask"
tap "homebrew/cask-fonts"
tap "homebrew/core"
brew "bash"
brew "bash-completion@2"
brew "bottom"
brew "btop"
brew "cloc"
brew "docker"