Skip to content

Instantly share code, notes, and snippets.

View astrolemonade's full-sized avatar
🔍
Happiness should be a pure function without any parameters.

astrolemonade astrolemonade

🔍
Happiness should be a pure function without any parameters.
View GitHub Profile
@astrolemonade
astrolemonade / split_keyboards.md
Created March 23, 2024 21:00 — forked from itod/split_keyboards.md
Every "split" mechanical keyboard currently being sold that I know of
@astrolemonade
astrolemonade / ATTiny + Micronucleus
Created March 11, 2024 00:19 — forked from amcolash/ATTiny + Micronucleus
ATTiny85 + micronucleus using an AVR programmer
This gist is a list of instructions that I used to program my ATTiny85s with Micronucleus. They worked for me, but your mileage may vary! I would highly recommend starting by looking at the SparkFun article linked at the bottom for schematics and more in-depth info. This gist is mostly just a copy/paste list.
## Required:
- ATTiny85
- AVR programmer
- 1 uF capacitor
- Micronucleus FW: https://github.com/micronucleus/micronucleus/releases
- avrdude: http://www.nongnu.org/avrdude/
## Setup:
@astrolemonade
astrolemonade / post.md
Last active March 4, 2024 20:21 — forked from wheremyfoodat/post.md
Why having multiple emulators is good

Forenote: Most of the following is simply my point of view as an emulator developer. Various names are omitted for privacy reasons.

I usually write blog posts aimed at developers, but I'd like to make an exception just this once. For a lot of game consoles you have likely noticed that there's multiple emulators for said console. Even for more modern systems like the Nintendo 3DS, you've got several active emulators such as Citra, Mikage and Panda3DS, and some less active ones at the moment such as Corgi3DS. This has made many people in the emulation community ask "Why do emulator developers not simply collaborate"? Thus, I'd like to dedicate this post to answering this question as an emulator developer myself.

1) We actually do collaborate!

Even when we're working on different emulators, we very often collaborate and help each other. A lot of people don't know, since it usually happens ov

@astrolemonade
astrolemonade / zen-display-improvements.md
Created February 17, 2024 17:20 — forked from caksoylar/zen-display-improvements.md
Corne-ish Zen display improvements

Display improvements for the Corne-ish Zen keyboard

This note details the changes made to the Zen and ZMK codebase to improve the experience of e-ink displays.

Getting the changes

You can test out below changes using your Zen config repo by modifying your config/west.yml file, following ZMK instructions:

manifest:
  remotes:
 - name: caksoylar
@astrolemonade
astrolemonade / how-to-git-patch-diff.md
Created December 22, 2023 18:12 — forked from nepsilon/how-to-git-patch-diff.md
How to generate and apply patches with git? — First published in fullweb.io issue #33

How to generate and apply patches with git?

It sometimes happen you need change code on a machine from which you cannot push to the repo. You’re ready to copy/paste what diff outputs to your local working copy.

You think there must be a better way to proceed and you’re right. It’s a simple 2 steps process:

1. Generate the patch:

git diff > some-changes.patch
@astrolemonade
astrolemonade / install-docker.sh
Created December 15, 2023 02:15 — forked from p3jitnath/install-docker.sh
Docker and Nvidia Docker installation in Ubuntu 20.04 LTS
# WARNING : This gist in the current form is a collection of command examples. Please exercise caution where mentioned.
# Docker
sudo apt-get update
sudo apt-get remove docker docker-engine docker.io
sudo apt install docker.io
sudo systemctl start docker
sudo systemctl enable docker
docker --version
@astrolemonade
astrolemonade / Dockerfile
Created December 15, 2023 00:38
Run QT5 gui app in Docker container
FROM ubuntu:bionic
RUN mkdir /app
COPY requirements.txt icons_rc.py main.py mainwindow_ui.py config.json /app/
RUN apt-get update && \
apt-get install -y python3 python3-pip xvfb libqt5x11extras5 && \
pip3 install -r /app/requirements.txt
#lang racket
(define (expr? e)
(match e
[(? number? n) #t]
[(? symbol? x) #t]
[`(λ (,(? symbol? x)) ,(? expr? e)) #t]
[`(,(? expr? e0) ,(? expr? e1)) #t]
[_ #f]))
@astrolemonade
astrolemonade / index.md
Created October 20, 2023 10:56 — forked from davesnx/index.md
Safer Tailwind with OCaml-derived languages

Safer Tailwind with OCaml-derived languages (OCaml, Reason, ReScript or Melange)

Tailwind is optimised to work with JavaScript/TypeScript ecosystems, but other languages might have good integrations also.

This is the case for OCaml-derived languages that are used to do Frontend development. For the most part, a tighter integration might not be needed and using the Tailwind setup guide and regular classNames with strings is good enought.

let make = (~text) => {
  <h1 className="text-3xl font-bold underline">{React.string(text)}<h1>
// ==UserScript==
// @name youtube popup killer
// @namespace http://tampermonkey.net/
// @version 0.3
// @description try to take over the world!
// @author Selbereth
// @match https://*.youtube.com/*
// @icon https://www.google.com/s2/favicons?sz=64&domain=youtube.com
// @grant none
// ==/UserScript==