Skip to content

Instantly share code, notes, and snippets.

View rwuwon's full-sized avatar

Raymond Wu Won rwuwon

View GitHub Profile
@rwuwon
rwuwon / Hardware tips.md
Last active June 8, 2025 01:29
Hardware tips

Hardware Tips

memtest86+

(not to be confused with memtest86 or memtester)

  • Keyboard is recognised and works only if the N-Key Rollover DIP switch isn't on (for versions including and up to 6.10). Reboot between switch changes.
  • Dust really does make a difference for the contacts! If you see dust on the casing of your RAM sticks, but the contacts look clear don't assume the dust won't somehow obey the laws of gravity and end up making its way to the sockets. >_<
  • My favourite way to remove dust is to use a camera lens blower + vacuum cleaner. The vac must only be used at a distance to collect all the dust from the air that the lens blower throws up. I've never zapped a component with this technique. Keep the PSU earthed (plugged into the power outlet but switched off) of course, so you can touch it to regularly ground yourself.
@rwuwon
rwuwon / btrfs-convert.md
Last active May 27, 2025 11:07
btrfs-convert walkthrough

This is a draft guide for using btrfs-convert to convert Debian 12 root ext4 systems to btrfs.

I keep meaning to post this, so figured I might as well do it before it attains perfection.

Background: Successfully did a btrfs-convert on two Debian 12 installs around September 2024 and have had no issues since.

The ArchBang instructions were an initial attempt to develop a workflow to later test with Arch and improve ArchWiki, but that whole thing moves too quickly and I don't think anyone there cares about btrfs-convert.

Follow these instructions at your own risk. You must test them in a virtual environment first, preferably several times.

mkfs.btrfs is historically the more reliable method to use. Issues with btrfs-convert have existed in the past so perform at your own risk.

Debian 12

  1. btrfs-convert /dev/vda1
    1. mount /dev/vda1 /mnt
@rwuwon
rwuwon / gist:2d490d3ea5b65224dc0c2a4f5f1e8b4e
Last active April 19, 2025 15:49
Microsoft 365 / Office 365 Table of Contents page number bug: Possible Workaround

Microsoft 365 / Office 365 Table of Contents page number workaround

EDIT: Actually you know what - there's no point fighting MS365. You'll save far more time if you just update the index in LibreOffice, Google Docs, or offline Word and then re-upload and check. It should also be noted that the Table of Contents will display differently when you view the doc online vs offline. So it could well be that you can ignore how the online version appears since that one will never reflect reality. Additionally, MS365 works better in Chrome/Edge than Firefox.

The following steps still don't work under certain conditions, but are a tantalising step closer as far as much simpler documents go. It's remarkable how easy it is to reproduce this bug though.

┬──┬╯︵ /(.□. \) (╯°□°)╯︵ ┻━┻

@rwuwon
rwuwon / android-webview-troubleshooting.txt
Last active May 23, 2023 16:04
Troubleshooting Android WebView not updating in Google Play
In short, the workaround that eventually sorted it for me was to create a second profile on my phone (with the same Google Account details) allowed Google Play within that to update WebView properly.
----
Background: I had just bought a refurbished Pixel 6a, a phone that was first released about 9 months ago (https://endoflife.date/pixel) and was in the process of setting it up and bringing the software up to date and found that WebView was the only thing that wouldn't update.
At first, I suspected that it was because the System Updates hadn't caught up (it requires multiple reboots, and will tend to pause after each reboot; so each time you need to go into system Settings and resume the update over there). But I got it up to May 2023 and WebView still didn't update via Google Play, despite also making sure Google Play had the latest updates (which can be done the confusing navigation of Settings > About phone > Android version > Google Play system update).
Still no dice. I also tried several other sugges
@rwuwon
rwuwon / brompton.md
Last active June 8, 2022 14:54
Brompton/Bicycling Tips & Tricks
@rwuwon
rwuwon / JuiceSSHAutocomplete.md
Last active April 19, 2025 15:51
Swipe left

JuiceSSH Autocomplete!

(Update: I have long since switched to Termux.)

Swipe left on JuiceSSH's popup keyboard to use the autocomplete input field.

I've been using JuiceSSH about a year now (as of 2018-09) with tmux & irssi and have only just realised that there's an autocorrect/autocomplete area hidden in the pop-up keyboard. >_<

I now realise the changelog from October 2014 mentions it as well as the extremely lengthy FAQ (it should probably be a second manual...), but this feature isn't made obvious through the JuiceSSH website screenshots nor discoverable design indicators within the app (think SwiftKey's red dots).

@rwuwon
rwuwon / keybase.md
Created July 27, 2018 17:18
Keybase proof

Keybase proof

I hereby claim:

  • I am rwuwon on github.
  • I am rwuwon (https://keybase.io/rwuwon) on keybase.
  • I have a public key ASBUcsHLsch_uVdZCvN_iUZxN7CdL5Le5buCknE_YK4JHAo

To claim this, I am signing this object:

@rwuwon
rwuwon / 0 Linux-On-MBP-Late-2016.md
Last active July 10, 2018 04:01 — forked from roadrunner2/0 Linux-On-MBP-Late-2016.md
Linux on MacBook Pro Late 2016 and Mid 2017 (with Touchbar)

Introduction

This is about documenting getting Linux running on the late 2016 and mid 2017 MPB's; the focus is mostly on the MacBookPro13,3 and MacBookPro14,3 (15inch models), but I try to make it relevant and provide information for MacBookPro13,1, MacBookPro13,2, MacBookPro14,1, and MacBookPro14,2 (13inch models) too. I'm currently using Fedora 27, but most the things should be valid for other recent distros even if the details differ. The kernel version is 4.14.x (after latest update).

The state of linux on the MBP (with particular focus on MacBookPro13,2) is also being tracked on https://github.com/Dunedan/mbp-2016-linux . And for Ubuntu users there are a couple tutorials (here and here) focused on that distro and the MacBook.

Note: For those who have followed these instructions ealier, and in particular for those who have had problems with the custom DSDT, modifying the DSDT is not necessary anymore - se

@rwuwon
rwuwon / mosh.md
Last active December 3, 2024 08:59
Connect to a Google Cloud Compute Engine using Mosh (mobile shell)

Connect to a Google Cloud Compute Engine using Mosh (mobile shell)

Mosh is a great way to overcome lag and flakey connection issues when accessing remote terminals over SSH: https://mosh.org/

Unfortunately, there's still not a lot of clear documentation for "idiots" because a lot of the existing guides assume a) "it just works", or b) you're already skilled enough to set everything up from scratch (assumed knowledge/use cases).

One of the problems I ran into for quite a long time yesterday was getting the darn thing to connect to my Google Cloud instance. I kept running into the mosh: Nothing received from server on UDP port 60001. [To quit: Ctrl-^ .] error (by the way - to quit, you have to press . after Ctrl-^ - it's not just Ctrl-^, there is a dot there too!)

FAQs and the like made vague spartan references to NATs, firewalls, iptables and the like and I tried out various commands and configurations on the se