This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(defun bci/--screenshot-to-image-format (type) | |
"Save a screenshot of the current frame as a TYPE image, with | |
the appropriate file-extension. | |
TYPE should be given as a quoted symbol, as it is passed directly | |
to `x-export-frames'. | |
The result is saved to a temp file, with the filename placed also | |
in the kill-ring." | |
(let* ((file-extension |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
## Author: Abidán Brito | |
## This script builds GNU Emacs 28 with support for native elisp compilation, | |
## libjansson (C JSON library) 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 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
Brandon C. Irizarry | |
Create a doubly-linked list of 200 random integers in the range [0, | |
49]. Then, remove duplicates from this list. | |
Our strategy is to first sort the list, then remove duplicates by | |
scanning the sorted list in order, pushing non-repeated elements | |
onto a new list, and then returning this list. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
Brandon C. Irizarry | |
8/19/21 | |
Example of Bubble Sort (ascending order). | |
Upon studying this a bit further, I missed out on | |
an invariant of the sort. | |
(The array is always scanned from the beginning each time.) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
! Make communicating with other applications via the clipboard easy | |
xterm*selectToClipboard: true | |
! Important - if you leave out 'renderFont', 'faceName' and such won't work. See: | |
! https://superuser.com/questions/463414/how-to-get-truetype-fonts-to-display-in-xterm-from-a-xresources-file/575108#575108 | |
xterm*renderFont: true | |
xterm*faceName: monospace | |
xterm*faceSize: 20 | |
! Some sample configuration settings, to test whether xterm was |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
Small, fun proof-of-concept: | |
Given a command-line string, convert each argument to | |
SpongeBob-case. Invoking './spongebob spongebob meme' prints | |
'sPoNgEbOb mEmE' to stdout. | |
*/ | |
#include <stdio.h> | |
#include <ctype.h> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
Adapted, with light modifications, from | |
https://gist.github.com/lesovsky/f0f5d31ac48f2fc53e5f | |
The original name of the program was, "ncurses-get-key-code.c". | |
The problem was the following: | |
BACKGROUND: |