Skip to content

Instantly share code, notes, and snippets.

View jneander's full-sized avatar
🦆
Quack!

Jeremy Neander jneander

🦆
Quack!
View GitHub Profile
@jneander
jneander / console_color_codes.sh
Created November 13, 2013 03:22
Console Color Codes
# Reset
Color_Off='\e[0m' # Text Reset
# Regular Colors
Black='\e[0;30m' # Black
Red='\e[0;31m' # Red
Green='\e[0;32m' # Green
Yellow='\e[0;33m' # Yellow
Blue='\e[0;34m' # Blue
Purple='\e[0;35m' # Purple
@jneander
jneander / screenreader-only.css
Created July 14, 2016 01:55
Visually hide an element, yet keep it available to screenreaders.
.screenreader-only {
border: 0;
clip: rect(0 0 0 0);
height: 1px;
margin: -1px;
overflow: hidden;
padding: 0;
position: absolute;
width: 1px;
transform: translatez(0);
PRETTY FORMATS
--------------
If the commit is a merge, and if the pretty-format
is not 'oneline', 'email' or 'raw', an additional line is
inserted before the 'Author:' line. This line begins with
"Merge: " and the sha1s of ancestral commits are printed,
separated by spaces. Note that the listed commits may not
necessarily be the list of the *direct* parent commits if you
have limited your view of history: for example, if you are
@jneander
jneander / del.sh
Last active August 29, 2015 14:27 — forked from itsthatguy/del.sh
The `rm` command is destructive. Here's a command to move files to the trash, with a prompt, instead of deleting permanently.
# Add this to your .bash_profile, .bashrc, .zshrc or wherever you keep your bash functions and aliases.
del() {
RED="\e[31m"
YELLOW="\e[33m"
WHITE="\e[97m"
if [[ $# -eq 0 ]] ; then
echo -e "Sorry dude, I can't do anything with that. Nothing specified."
else
@jneander
jneander / digital_ocean_setup.md
Last active August 29, 2015 14:26 — forked from ChuckJHardy/digital_ocean_setup.md
DigitalOcean Ubuntu 14.04 x64 + Rails 4 + Nginx + Unicorn + PostgreSQL + Capistrano 3 Setup Instructions

DigitalOcean Ubuntu 14.04 x64 + Rails 4 + Nginx + Unicorn + PostgreSQL + Capistrano 3

SSH into Root

$ ssh root@123.123.123.123

Change Root Password

@jneander
jneander / _instructions.md
Last active August 29, 2015 14:26
Setting up a Ubuntu instance to run NGINX and Unicorn, with deployment using Capistrano.

Disclaimer: This is a work in progress and may not represent best practices.

Linux Instance Setup

Update Linux packages.

sudo apt-get update

Security