Skip to content

Instantly share code, notes, and snippets.

View ericandrewlewis's full-sized avatar

Eric Lewis ericandrewlewis

View GitHub Profile
<!DOCTYPE html>
<html>
<head>
<title>Page Title</title>
</head>
<body>
<h1>Shoyu Ramen Recipe</h1>
<img src="http://www.kobayashinoodle.com/wp/wp-content/uploads/2011/06/QuickShoyuRamen.jpg">
<blockquote>"My first bowl of ramen was like my first bowl of cereal, all over again" — Neil Young</blockquote>
<p>Shoyu Ramen is a popular soup-based meal in Japan. </p>

top (the UNIX process inspector) cheat sheet

This is a list of the most helpful keyboard commands I use within top.

The basics

h shows help on interactive commands. Also see the top manual page

q to quit the program.

csrutil disable
bless --folder=/Volumes/EFI --file=/Volumes/EFI/EFI/grub-patched/grubx64.efi --setBoot
bless --mount=/Volumes/EFI --file=/Volumes/EFI/EFI/grub-patched/grubx64.efi --setBoot
@ericandrewlewis
ericandrewlewis / index.js
Created March 2, 2016 03:21
requirebin sketch
console.log('hi')
@ericandrewlewis
ericandrewlewis / index.js
Last active March 2, 2016 03:23
requirebin sketch
var ProseMirror = require("prosemirror").ProseMirror
require("prosemirror/dist/inputrules/autoinput")
require("prosemirror/dist/menu/tooltipmenu")
require("prosemirror/dist/menu/menubar")
var pm = window.pm = new ProseMirror({
place: document.querySelector(".full"),
autoInput: true,
tooltipMenu: {selectedBlockMenu: true},
menuBar: {float: true},
@ericandrewlewis
ericandrewlewis / Dockerfile
Created December 9, 2015 17:33
Varnish 4.0 Dockerfile for VMODs that don't need Varnish source
FROM debian:jessie
RUN apt-get update && \
apt-get install -y varnish
# Dependencies for installing Varnish Modules.
RUN apt-get install -y libvarnishapi-dev curl automake libtool pkg-config make python-docutils
@ericandrewlewis
ericandrewlewis / a.md
Last active October 9, 2024 00:31
The WordPress Customizer

The WordPress Customizer

The WordPress Customizer is an interface for drafting changes to content while previewing the changes before they are saved. This is an alternative to the "save and suprise" model of changing settings without knowing what exactly will happen.

The customizer can be accessed in the admin interface under Appearance > Customize.

A screenshot of the customizer

#19909 is the trac ticket that introduced the Customizer during the 3.4 release cycle.

@ericandrewlewis
ericandrewlewis / 32.asm
Last active November 24, 2020 08:54 — forked from FiloSottile/32.asm
NASM Hello World for x86 and x86_64 Intel Mac OS X(get yourself an updated nasm with brew)
; /usr/local/bin/nasm -f macho 32.asm && ld -macosx_version_min 10.7.0 -o 32 32.o && ./32
global start
section .text
start:
push dword msg.len
push dword msg
push dword 1
mov eax, 4
@ericandrewlewis
ericandrewlewis / index.md
Last active June 6, 2024 01:43
C++ Pointer Tutorial

C++ Pointer Tutorial

Because pointers can be ugh

"Regular" variables (not pointers)

To understand a pointer, let's review "regular" variables first. If you're familiar with a programming language without pointers like JavaScript, this is what you think when you hear "variable".

When declaring a variable by identifier (or name), the variable is synonymous with its value.

@ericandrewlewis
ericandrewlewis / index.md
Last active February 6, 2019 21:36
PHP Cheat Sheet

PHP is a general purpose programming language with a focus on web programming.

PHP is a dynamically typed language; the type of variables is not known and type-checking occurs at run-time.

function takes_anything($anything) {
	// ...
}

takes_anything( 12345 );