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 / Wayland.md
Created October 5, 2023 21:14 — forked from probonopd/Wayland.md
Boycott Wayland. It breaks everything!

Think twice before abandoning Xorg. Wayland breaks everything!

Hence, if you are interested in existing applications to "just work" without the need for adjustments, then you may be better off avoiding Wayland.

Wayland solves no issues I have but breaks almost everything I need. And usually it stays broken, because the Wayland folks mostly seem to care about Automotive, Gnome, maybe KDE - and alienating everyone else (e.g., people using just an X11 window manager or something like GNUstep) in the process. DO NOT USE A WAYLAND SESSION! Let Wayland not destroy everything and then have other people fix the damage it caused. Or force more Red Hat/Gnome components (glib, Portals, Pipewire) on everyone!

Please add more examples to the list.

Wayland seems to be made by people who do not care for existing software. They assume everyone is happy to either rewrite everything or to just use Gnome on Linux (rather than, say, twm with ROX Filer on NetBSD).

@astrolemonade
astrolemonade / Editor.tres
Created October 5, 2023 17:25 — forked from passivestar/Editor.tres
Godot editor theme
[gd_resource type="Theme" load_steps=10 format=3 uid="uid://baux6bqje2p6j"]
[sub_resource type="StyleBoxFlat" id="StyleBoxFlat_6h42l"]
content_margin_left = 10.5
content_margin_top = 8.75
content_margin_right = 10.5
content_margin_bottom = 8.75
bg_color = Color(0.116078, 0.116078, 0.116078, 1)
draw_center = false
border_width_left = 4
@astrolemonade
astrolemonade / bambu-ssdp-discovery.py
Created October 1, 2023 14:26 — forked from Alex-Schaefer/bambu-ssdp-discovery.py
Python implementation to send a fake SSDP discovery message to Bambu Studio or Orca Slicer
# Derived from this: https://github.com/gashton/bambustudio_tools/blob/master/bambudiscovery.sh
# Python implementation without need for linux
# Send the IP address of your BambuLab printer to port 2021/udp, which BambuStudio is listens on.
# Ensure your PC has firewall pot 2021/udp open. This is required as the proper response would usually go to the ephemeral source port that the M-SEARCH ssdp:discover message.
# But we are are blindly sending a response directly to the BambuStudio listening service port (2021/udp).
# Temporary solution to BambuStudio not allowing you to manually specify the Printer IP.
# Usage:
@astrolemonade
astrolemonade / Stacked-diff-steps.md
Created September 28, 2023 08:05 — forked from Whoaa512/Stacked-diff-steps.md
Cheatsheet for the stacked diffs workflow in phabricator at Fictiv

stack diff steps

  1. Checkout & pull latest master
git checkout master && git pull --rebase origin master
  1. Cut branch from master
arc branch stacked_feature_1
  1. Make changes, add commits

During the past days, this great article by Sam Pruden has been making the rounds around the gamedev community. While the article provides an in-depth analysis, its a bit easy to miss the point and exert the wrong conclusions from it. As such, and in many cases, users unfamiliar with Godot internals have used it points such as following:

  • Godot C# support is inefficient
  • Godot API and binding system is designed around GDScript
  • Godot is not production ready

In this brief article, I will shed a bit more light about how the Godot binding system works and some detail on the Godot

@astrolemonade
astrolemonade / roundedcube.scad
Created September 10, 2023 20:19 — forked from groovenectar/roundedcube.scad
roundedcube.scad - Fork me and make me better!
// More information: https://danielupshaw.com/openscad-rounded-corners/
// Set to 0.01 for higher definition curves (renders slower)
$fs = 0.15;
module roundedcube(size = [1, 1, 1], center = false, radius = 0.5, apply_to = "all") {
// If single value, convert to [x, y, z] vector
size = (size[0] == undef) ? [size, size, size] : size;
translate_min = radius;
@astrolemonade
astrolemonade / stackless-eval.md
Created September 10, 2023 09:57 — forked from divs1210/stackless-eval.md
Writing a Stackless Evaluator

Writing a Stackless Evaluator

Divyansh Prakash, September 2023

tiny-stackless-eval

Preface

Now that we have learnt how to write stackless recursive functions using trampoline, and we know that JS's eval is not stack-safe, it's time to write our own stackless eval!

@astrolemonade
astrolemonade / ZeroCostGC.md
Created August 11, 2023 11:02 — forked from AndrasKovacs/ZeroCostGC.md
Garbage collection with zero-cost at non-GC time

Garbage collection with zero cost at non-GC time

Every once in a while I investigate low-level backend options for PL-s, although so far I haven't actually written any such backend for my projects. Recently I've been looking at precise garbage collection in popular backends, and I've been (like on previous occasions) annoyed by limitations and compromises.

I was compelled to think about a system which accommodates precise relocating GC as much as possible. In one extreme configuration, described in this note, there

https://github.com/reireias/dotseeker

grep -r -E -v -h '^\s*#' files | grep --color=none -E "^\s*alias " | sed -e 's/#.*//g' -e 's/^\s*//g' -e 's/\s*$//g' | sort | uniq -c | sort -k2 | pbcopy
  1 alias      ..='cd ..'
  1 alias     ...='cd ../..'
  1 alias     ci='git commit'

1 alias co='git checkout'