Skip to content

Instantly share code, notes, and snippets.

View hectorm's full-sized avatar
🐳

Héctor Molinero Fernández hectorm

🐳
View GitHub Profile

Emscripten as a linker for Zig and C

This shows how to build a nontrivial program using Zig+Emscripten or C+Emscripten. In both cases Emscripten is only used as a linker, that is the frontend is either zig or clang.

"Nontrivial" here means the program uses interesting Emscripten features:

  • Asyncify
  • Full GLES3 support
  • GLFW3 support
@smcvey
smcvey / BruteForcer.cpp
Last active April 14, 2020 20:18
Animal Crossing New Horizons Turnip/Seed Bruteforcer
#include <stdio.h>
#include <stdlib.h>
namespace sead
{
class Random
{
public:
void init();
void init(uint32_t seed);
@Treeki
Treeki / TurnipPrices.cpp
Last active April 21, 2025 04:42
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
{
@fnky
fnky / ANSI.md
Last active April 21, 2025 18:34
ANSI Escape Codes

ANSI Escape Sequences

Standard escape codes are prefixed with Escape:

  • Ctrl-Key: ^[
  • Octal: \033
  • Unicode: \u001b
  • Hexadecimal: \x1B
  • Decimal: 27
@lvzongting
lvzongting / wget-gdrive.sh
Last active March 30, 2025 08:56
download google drive file only with wget 仅通过wget 在bash命令行下载谷歌网盘(狗哥网盘)上的文件
#reference https://unix.stackexchange.com/questions/136371/how-to-download-a-folder-from-google-drive-using-terminal
#get cookie and code
wget --save-cookies cookies.txt --keep-session-cookies --no-check-certificate 'https://docs.google.com/uc?export=download&id=FILEID' -O- | sed -rn 's/.*confirm=([0-9A-Za-z_]+).*/Code: \1\n/p'
#download the file
wget --load-cookies cookies.txt 'https://docs.google.com/uc?export=download&confirm=CODE_FROM_ABOVE&id=FILEID'
@jm3
jm3 / README.md
Last active February 19, 2024 04:47
Cognitive Bias Codex

Git Cheat Sheet

Commands

Getting Started

git init

or

@staltz
staltz / introrx.md
Last active April 21, 2025 04:15
The introduction to Reactive Programming you've been missing