Skip to content

Instantly share code, notes, and snippets.

View ylluminarious's full-sized avatar

George Plymale II ylluminarious

View GitHub Profile
@OrionReed
OrionReed / dom3d.js
Last active July 22, 2024 08:58
3D DOM viewer, copy-paste this into your console to visualise the DOM topographically.
// 3D Dom viewer, copy-paste this into your console to visualise the DOM as a stack of solid blocks.
// You can also minify and save it as a bookmarklet (https://www.freecodecamp.org/news/what-are-bookmarklets/)
(() => {
const SHOW_SIDES = false; // color sides of DOM nodes?
const COLOR_SURFACE = true; // color tops of DOM nodes?
const COLOR_RANDOM = false; // randomise color?
const COLOR_HUE = 190; // hue in HSL (https://hslpicker.com)
const MAX_ROTATION = 180; // set to 360 to rotate all the way round
const THICKNESS = 20; // thickness of layers
const DISTANCE = 10000; // ¯\\_(ツ)_/¯
@genegoykhman
genegoykhman / multi-tty.patch
Created December 6, 2020 17:14
Fix support for macOS multi-tty in Emacs 27.1
diff --git a/lisp/server.el b/lisp/server.el
index 5efba17a01..c194d78ad1 100644
--- a/lisp/server.el
+++ b/lisp/server.el
@@ -1182,10 +1182,9 @@ The following commands are accepted by the client:
;; choice there.) In daemon mode on Windows, we can't
;; make tty frames, so force the frame type to GUI
;; there too.
- (when (or (and (eq system-type 'windows-nt)
- (or (daemonp)
@jodosha
jodosha / benchmark.rb
Created July 22, 2020 07:37
Ruby Method Overloading
require "benchmark/ips"
require_relative "./method_overloading"
class Foo
include MethodOverloading
def call(number)
"foo #{number}"
end
end
@yovko
yovko / ohmyzsh.md
Last active June 19, 2024 06:18
ZSH (using Oh My ZSH) on Manjaro Linux

ZSH (using Oh My ZSH) on Manjaro Linux

0. If ZSH is not already installed on your Manjaro system you can do it with the command:

sudo pacman -Syu zsh

You do not need to install manjaro-zsh-config and all the other related packages like zsh-syntax-highlighting, zsh-history-substring-search, zsh-autosuggestions, etc., as we will use Oh My Zsh.

@mikroskeem
mikroskeem / gccemacs_osx.md
Last active July 7, 2024 09:37
gccemacs on OSX

gccemacs on OS X

Read this first: http://akrl.sdf.org/gccemacs.html

Prerequisites

1) GCC with libgccjit enabled

For that you need to compile gcc (duh). I edited Homebrew's gcc formula:

Building Emacspeak: Making GNU Emacs Accessible

In 2015, I started diving deeper into GNU Emacs because I saw its potential as an assistive technology. Not only as a way of providing better access to books and code for my students and clients, many of whom are blind, but also as a tool for creating more accessible content. Regular expressions and modes like Org, Markdown, and AucTex are extremely useful in the production of alternate formats.

Although I had used Emacs as a vanilla text editor off and on since the 90's, I didn't learn anything about the underlying Emacs Lisp (elisp) programming language until the end of 2015, when I got a hardcopy Emacs manual, quit my day job, and grew t

@noperator
noperator / mount-encrypted-sparsebundle.sh
Last active March 6, 2022 21:25
Decrypt and mount an encrypted sparse bundle disk image using https://github.com/jief666/sparsebundlefs.
# Create mount points for decrypted sparse bundle disk image and full Apple disk image.
sudo mkdir /mnt/bundle /mnt/dmg
# Ensure loopback kernel module is loaded.
lsmod | grep ^loop || sudo modprobe loop
# Decrypt and FUSE-mount sparse bundle disk image. Trailing options help with debugging.
sudo sparsebundlefs <ENCRYPTED_SPARSE_BUNDLE_DISK_IMAGE> /mnt/bundle -s -f -D
# Note partition 2's "Start" and "Size" values.
@sidneys
sidneys / youtube.expand-all-video-comments.js
Last active July 2, 2022 08:30
Greasemonkey | YouTube (New Design) | Expand All Video Comments
// ==UserScript==
// @name YouTube: Expand All Video Comments
// @namespace org.sidneys.userscripts
// @homepage https://gist.githubusercontent.com/sidneys/6756166a781bd76b97eeeda9fb0bc0c1/raw/
// @version 4.7.8
// @description Adds a "Expand all" button to video comments which expands every comment and replies - no more clicking "Read more".
// @author sidneys
// @icon https://www.youtube.com/favicon.ico
// @noframes
// @match http*://www.youtube.com/*
@rocky
rocky / gcd-phase1.lap
Last active October 4, 2017 21:30
Amazing emacs decompilation
# preprocessed disassembly. Fake "LABEL" and "COME_FROM" instructions have been added
0 VARREF a
1 VARREF b
2 GTR
3 GOTO-IF-NIL 1
6 VARREF a
7 VARBIND c
8 VARREF b
9 VARSET a
10 VARREF c