Skip to content

Instantly share code, notes, and snippets.

View BrandonIrizarry's full-sized avatar

Brandon Irizarry BrandonIrizarry

  • New York, New York
  • 03:09 (UTC -04:00)
View GitHub Profile
@amno1
amno1 / aoc-helper.el
Last active December 4, 2023 23:56
Small utility to generate an empty skeleton file for solving AoC puzzles
;;; aoc-helper.el --- Gen AOC skeleton -*- lexical-binding: t; -*-
;; Copyright (C) 2023 Arthur Miller
;; Author: Arthur Miller <arthur.miller@live.com>
;; Keywords:
;; This program is free software; you can redistribute it and/or modify
;; it under the terms of the GNU General Public License as published by
;; the Free Software Foundation, either version 3 of the License, or
@abidanBrito
abidanBrito / build-emacs.sh
Last active June 5, 2024 20:41
Build GNU Emacs from source.
#!/usr/bin/env bash
## Author: Abidán Brito
## This script builds GNU Emacs 29.1 with support for native elisp compilation,
## tree-sitter, libjansson (C JSON library), pure GTK and mailutils.
# Exit on error and print out commands before executing them.
set -euxo pipefail
# Let's set the number of jobs to something reasonable; keep 2 cores
@sylt
sylt / ncurses_mouse_movement.c
Created November 22, 2015 20:17
Mouse movement example for NCURSES
// I had problems getting mouse movement events working in ncurses, but after
// some research, it seems as if this is how you can do it. The magic is in the
// printf("\033[?1003h\n") which was the missing piece in the puzzle for me
// (see console_codes(4) for more information). 1003 means here that all events
// (even position updates) will be reported.
//
// This seems to work in at least three X-based terminals that I've tested:
// xterm, urxvt and gnome-terminal. It doesn't work when testing in a "normal"
// terminal, with GPM enabled. Perhaps something for the next gist version? :)