Skip to content

Instantly share code, notes, and snippets.

View pomettini's full-sized avatar
🦀
Code speaks for itself

Giorgio Pomettini pomettini

🦀
Code speaks for itself
View GitHub Profile
@tkafka
tkafka / Detect electron apps causing macOS Tahoe lag.md
Last active October 29, 2025 18:42
Detect Electron apps on mac where the Electron hasn't yet been updated to fix the system wide lag
@nodlag
nodlag / easing_functions.gd
Last active July 18, 2025 18:07
Easing Functions for GODOT ENGINE 4 in GDScript
#
# Easing Functions for GODOT ENGINE 4 in GDScript
#
# Created by Javier Garrido Galdón
#
# The MIT License (MIT)
#
# Copyright (c) 2024
#
# Permission is hereby granted, free of charge, to any person obtaining a copy
@p4bl0-
p4bl0- / 00_readme.md
Last active January 2, 2025 09:03
A complete compiler for a simple language (in less than 150 LoC)

This project is a tiny compiler for a very simple language consisting of boolean expression.

The language has two constants: 1 for true and 0 for false, and 4 logic gates: ! (not), & (and), | (or), and ^ (xor).

It can also use parentheses to manage priorities.

Here is its grammar in BNF format:

expr ::= "0" | "1"

@akihikodaki
akihikodaki / README.en.md
Last active October 29, 2025 09:09
Linux Desktop on Apple Silicon in Practice

Linux Desktop on Apple Silicon in Practice

I bought M1 MacBook Air. It is the fastest computer I have, and I have been a GNOME/GNU/Linux user for long time. It is obvious conclusion that I need practical Linux desktop environment on Apple Silicon.

Fortunately, Linux already works on Apple Silicon/M1. But how practical is it?

  • Two native ports exist.
@prologic
prologic / LearnGoIn5mins.md
Last active August 12, 2025 02:24
Learn Go in ~5mins
@ityonemo
ityonemo / test.md
Last active October 23, 2025 01:27
Zig in 30 minutes

A half-hour to learn Zig

This is inspired by https://fasterthanli.me/blog/2020/a-half-hour-to-learn-rust/

Basics

the command zig run my_code.zig will compile and immediately run your Zig program. Each of these cells contains a zig program that you can try to run (some of them contain compile-time errors that you can comment out to play with)

@graninas
graninas / haskeller_competency_matrix.md
Last active June 27, 2025 16:13
Haskeller competency matrix
@Treeki
Treeki / TurnipPrices.cpp
Last active October 29, 2025 10:41
AC:NH turnip price calculator
#include <stdint.h>
#include <stdio.h>
#include <stdlib.h>
// munged from https://github.com/simontime/Resead
namespace sead
{
class Random
{
@AsherVo
AsherVo / RequireReferenceAlert.cs
Last active October 26, 2020 04:03
Using unity's standard ObjectField in RequireReferenceDrawer to fix bugs and improve prefab workflow.
// PLEASE NOTE: This will add ~1sec to your save time
// If that is unacceptable (which it was to me), then you can change all the
// references to "MonoBehaviour" in this file to your own custom behaviour type
// that this script will search through each time you save
using UnityEditor;
using UnityEngine;
using System.Linq;
using System.Reflection;
using System.Collections;
@JoeyBurzynski
JoeyBurzynski / 55-bytes-of-css.md
Last active October 28, 2025 06:41
58 bytes of css to look great nearly everywhere

58 bytes of CSS to look great nearly everywhere

When making this website, i wanted a simple, reasonable way to make it look good on most displays. Not counting any minimization techniques, the following 58 bytes worked well for me:

main {
  max-width: 38rem;
  padding: 2rem;
  margin: auto;
}