$ whoami
Remeber this for later.
cd
git clone https://github.com/torch/distro.git ~/torch --recursive
module ApplicationHelper | |
# Wraps the commonly used `render partial:` to just `partial` | |
def partial(path, options={}, &block) | |
render partial: path.to_s, **options, &block | |
end | |
end |
This is a rough quickstart for the ESP8266 (NodeMCU ESP-12E) Development board. This is the one I use.
Download the Arduino IDE.
Go to Tools -> Board -> Board Manager
Search and install the esp8266 package.
Under Tools, make your settings look like this:
# Based off of http://www.johneday.com/422/time-based-gmail-filters-with-google-apps-script | |
# See instructions on that page for adding it via script.google.com | |
function expireEmails() { | |
var delayDays = 2 // Enter # of days before messages are moved to trash | |
var maxDate = new Date(); | |
maxDate.setDate(maxDate.getDate()-delayDays); | |
var labelExpiring = GmailApp.getUserLabelByName("Expiring"); | |
var labelExpired = GmailApp.getUserLabelByName("Expired"); |
#!/bin/zsh | |
# ================================================ | |
# PREPEND ======================================== | |
# ================================================ | |
# Prepends a string to a target file | |
# ------------------------------------------------ | |
# TRAP->TERM ------------------------------------- | |
# ------------------------------------------------ | |
trap "exit 1" TERM |
#!/bin/zsh | |
micro_host_suffixes=('white' 'green' 'orange') | |
for suffix in $micro_host_suffixes; do | |
echo -n "micro-$suffix... " | |
silence ssh -o "ConnectTimeout 10" micro-$suffix true && echo up || echo down | |
done |
function evalCS(source) { | |
// Compile source to Coffeescript (Array) | |
var coffeescript = CoffeeScript.compile(source.toString()).split("\n"); | |
// Prepend 'debugger' | |
coffeescript[1] = "debugger;" + coffeescript[1]; | |
// Join and eval | |
eval(coffeescript.join("\n")); |