Skip to content

Instantly share code, notes, and snippets.

View bananatron's full-sized avatar
🍞
Stale bread is just lofi toast.

Spenser X bananatron

🍞
Stale bread is just lofi toast.
View GitHub Profile
@bananatron
bananatron / visual_studio_tab_selection.md
Last active May 15, 2019 07:45
Visual Studio Next/Previous Tab Keyboard Settings

Visual Studio code made the decision to change the next/previous tab behavior in newer versions (using the tab selector instead of moving you to the next/previous tab). In addition, the actions don't even have the word 'tab' in them, making them really annoying to track down. To restore the previous behavior you'll need to rebind the following actions:

On OSX go to Code > Preference > Keyboard Shortcuts and search for:

workbench.action.nextEditor workbench.action.previousEditor

A config might look something like:

@bananatron
bananatron / postgres-brew.md
Created March 28, 2019 14:16 — forked from ibraheem4/postgres-brew.md
Installing Postgres via Brew (OSX)

Installing Postgres via Brew

Pre-Reqs

Brew Package Manager

In your command-line run the following commands:

  1. brew doctor
  2. brew update
@bananatron
bananatron / oil_recipe.md
Last active February 1, 2019 15:56
Cannabis Oil Recipe (from flower)

Cannabis Oil Recipe (from flower)

Step 1 (Decarb)

  • Preheat oven to 100 - 150C (220 – 300F)
  • Cut bud into smaller peices (no need to finely chop)
  • Bake the bud on a clean/dry surface using the chart below as a guide. Glass containers or clean baking sheets work well. Do not oil this pan, and keep it from direct heat sources (put it high on the highest rack for most ovens). Prefer lower temperatures over a longer time period vs. higher temperatures (115C for 40 minutes is preferred for many 'bakers')*.
TEMP(C) TEMP(F) TIME
@bananatron
bananatron / gist:48724f19c52e49cfb042543463b1e6c1
Created December 31, 2018 13:51
too_much_and_for_too_long.txt
"Too much and for too long, we seemed to have surrendered personal excellence and community values in the mere accumulation of material things. Our Gross National Product, now, is over $800 billion dollars a year, but that Gross National Product - if we judge the United States of America by that - that Gross National Product counts air pollution and cigarette advertising, and ambulances to clear our highways of carnage. It counts special locks for our doors and the jails for the people who break them. It counts the destruction of the redwood and the loss of our natural wonder in chaotic sprawl. It counts napalm and counts nuclear warheads and armored cars for the police to fight the riots in our cities. It counts Whitman's rifle and Speck's knife, and the television programs which glorify violence in order to sell toys to our children. Yet the gross national product does not allow for the health of our children, the quality of their education or the joy of their play. It does not include the beauty of our poe
@bananatron
bananatron / gist:928d6e696e2f72e65c4339b1997ecb9a
Created November 23, 2018 15:23
Start and Stop Postgres on OSX
pg_ctl -D /usr/local/var/postgres start
pg_ctl -D /usr/local/var/postgres stop
@bananatron
bananatron / german_zip_codes.csv
Created September 18, 2018 13:05
List of German Zip codes, w/ city & state
osm_id ort plz bundesland
1104550 Aach 78267 Baden-Württemberg
1255910 Aach 54298 Rheinland-Pfalz
62564 Aachen 52062 Nordrhein-Westfalen
62564 Aachen 52064 Nordrhein-Westfalen
62564 Aachen 52066 Nordrhein-Westfalen
62564 Aachen 52068 Nordrhein-Westfalen
62564 Aachen 52070 Nordrhein-Westfalen
62564 Aachen 52072 Nordrhein-Westfalen
62564 Aachen 52074 Nordrhein-Westfalen
@bananatron
bananatron / German_Cities.rb
Created September 18, 2018 13:01
List of German Cities as Array
[
"Aach",
"Aachen",
"Aalen",
"Aarbergen",
"Aasbüttel",
"Abenberg",
"Abensberg",
"Abentheuer",
"Absberg",

Shortcuts

  • Ctrl + A Go to the beginning of the line you are currently typing on
  • Ctrl + E Go to the end of the line you are currently typing on
  • Ctrl + R Lets you search through previously used commands
  • Ctrl + W Delete the word before the cursor

Edit .profile || .bash_profile

@bananatron
bananatron / fix-vs-code.txt
Created July 24, 2018 07:33
Change tab order to work sequencially in Visual Studio Code
- Preferences > Keyboard Shortcuts
- Override the 'Open Next Editor' and 'Open Previous Editor' commands, (you may have to unset previous bindings).
Why this default was changed blows my mind.
😎
#!/bin/bash
# Logout current GitHub credentials and remove global user.name, user.email
echo -e "host=github.com\nprotocol=https\n" | git credential-osxkeychain erase
git config --unset-all --global user.name
git config --unset-all --global user.email