Skip to content

Instantly share code, notes, and snippets.

View mcandre's full-sized avatar

Andrew mcandre

  • Milwaukee, WI
View GitHub Profile
@mcandre
mcandre / debian-disable-sleep.md
Created April 8, 2024 03:37
Debian Disable Sleep

Debian Disable Sleep

$ sudo systemctl mask sleep.target suspend.target hibernate.target hybrid-sleep.target
@mcandre
mcandre / macos-finder-quirks.md
Last active April 7, 2024 19:27
macOS Finder Quirks

macOS Finder Quirks

Reverse Sort

Reverse sort was unfortunately never implemented in certain view modes. To enable reverse sort, activate View -> as List. Then select the desired column header to apply for sorting the entries, such as Name, Date Modified, Size, Kind, etc. Finally, select the same column again to reverse the current ordering.

However, if you primarily use as Columns or other views for your folders, then these view settings will be reset each time you navigate to the folder. To work around this, select a suitable ancestor folder and add to your Finder Favorites. Apply View -> as List to the ancestor. Then you can quickly return to the original by descending through this favorite directory root.

Jump to Top/Bottom

@mcandre
mcandre / dumbphones-theory-and-practice.md
Last active March 27, 2024 21:35
Dumbphones: Theory and Practice

Dumbphones: Theory and Practice

Consumers have implicitly accepted the intrusive advertisements, privacy violations, overstimulating notifications, and seedy business model built of dopamine addiction as part and parcel of mobile technology. Long term smartphone use is associated with poor working memory, poor navigation skills, restlessness, sleep apnea, financial loss, privacy issues, computer security issues, and many other problems. But it doesn't have to be that way.

Many of the tasks we have grown used to performing with fragile, glitchy apps, can be accomplished with a paper pocket notepad, or even done with some mental effort alone.

Indie cell phone manufacturers Punkt and Light Phone provide minimalist cell phone models, that are designed to reduce the distractions that have unfortunately crept into modern smartphones. In contrast to smartphones, these "dumbphones" prune away many extraneous features to arrive at svelte core. The dumb

@mcandre
mcandre / anduril-flashlight-guide.md
Last active April 6, 2024 21:08
Anduril Flashlight Guide

Anduril Flashlight Guide

Overview

Popular flashlight models such as the Noctigon KR4 and Sofirn BLF LT1 include a wealth of customizable features, based on the portable Anduril firmware standard. Anduril unifies many proprietary flashlight control mechanisms into a single, repeatable operational workflow.

Unfortunately, some Anduril models neglect to document their true capabilities. We detail core functions here for your convenience.

This is particularly relevant for the Nocticon Emissar KR4 and Sofirn LT1 models, which fail to persist settings when replacing the batteries.

@mcandre
mcandre / fixing-vape-power-loss.md
Last active December 24, 2023 03:42
Fixing Vape Power Loss

Fixing Vape Power Loss

Your mechanical, semimechanical, protected, or boro vape mod frequently experiences power loss. But the battery is freshly charged.

The good news is that this problem is usually easy to correct.

Check the (rebuildsble) atomizer for circuit faults on a separate, known working mod, preferably a non-boro, protected mod with an an ohm meter. If mecessary, rebuild and rewick the atomizer. Ensure that all electrical surfaces, including screws, are wiped clean. If necessary, select a new coil.

If the atomizer appears to work with other mods, then the problem is likely poor electric conductivity elsewhere in the system. For example, the big drip tip screw that completes a boro mod's circuit. Dust, dirt, ejuice condensate, and other debris will naturally accumulate on electrical components over time.

@mcandre
mcandre / quest-3-bugs.md
Created December 22, 2023 19:01
Quest 3 Bugs

Quest 3 Bugs

Your fully charged Quest 3 headset may suddenly spaz out. You may see weird graphics for a second, followed by loss of power to the screen. Followed by the charging indicator light failing to work.

To temporarily work around this bug, press and hold the power button for an entire thirty seconds.

@mcandre
mcandre / how-to-disable-android-talkback.md
Last active December 18, 2023 19:40
How to Disable Android TalkBack

How to Disable Android TalkBack

So you're seeing green rectangles everywhere, oh no! You may be hearing a narrator, and none of the UI is working properly. Congratulations, you have turned on Android TalkBack. More generally, this is known as speech over or voice over. It's like hitting the Shift key too long in Windows, with similarly annoying results.

This is unfortunately very easy to do, because there is a stupid, secret gesture for this. As of this writing, the gesture is pressing and holding both the volume up and volume down buttons. But in the future, it could be anything. Whatever the gesture is, try doing it again. If you're lucky, you'll stumble upon the right combination and manage to turn the feature back off.

Rebooting has broken. Rebooting does not fix the problem. There was never a prompt to persist the questionable setting across reboots, but alas here we are anyway.

Swiping and scrolling have broken. You cannot swipe or scroll normally to leave the current application. Nor to activate

@mcandre
mcandre / how-to-treat-black-mold-in-water-bottles.md
Last active December 13, 2023 01:32
How to Treat Black Mold in Water Bottles

How to Treat Black Mold in Water Bottles

What is black mold?

Black mold is a common fungus that accumulates in wet environments, such as damp walls and reusable water bottles. It rarely causes severe health conditions, but it is best avoided nevertheless. Black mold is associated with sneezing, coughing, congesting, asthma, and eye irritation. When you see black mold safe choices of response include departing the area, disposing of the moldy object, or cleaning the mold off the object.

Unlike commercial beverages, refillable water bottles are unfortunately easy for black mold and other pathogens to continually reinfect. Even if you filter your water with a purifier, the fact that you have a surface that is often wet and unrefridgerated, produces essentially a petri dish for mold.

Cleaning Process

@mcandre
mcandre / expose_cors.go
Created June 29, 2023 15:43
Expose CORS for local backend development and testing with Google Chrome
func exposeCors(w http.ResponseWriter) {
w.Header().Set("Access-Control-Allow-Origin", "*")
w.Header().Set("Access-Control-Allow-Methods", "*")
w.Header().Set("Access-Control-Allow-Headers", "*")
}
@mcandre
mcandre / docker-fix-missing-images.md
Created May 19, 2023 05:37
Docker Fix Missing Images

Docker now defaults to using buildx, which means that images no longer populate the normal docker images list.

When building images, make sure to include the --load option:

$ docker build -t <name> --load .