As configured in my dotfiles.
start new:
tmux
start new with session name:
As configured in my dotfiles.
start new:
tmux
start new with session name:
# ================================================================================ | |
# ObjectStorageUploader.sh | |
# © Copyright IBM Corporation 2014. | |
# LICENSE: MIT (http://opensource.org/licenses/MIT) | |
# ================================================================================ | |
import argparse | |
import os | |
import math | |
import http.client |
.DS_Store | |
node_modules/* |
Find Raspberry Pi on the network:
brew install nmap
sudo nmap -v -sn 10.128.30.0/24 | awk '/^Nmap/{ip=$NF}/B8:27:EB/{print ip}'
where 10.128.30.0
is the network the thing is on.
Expand the filesystem with raspi-config
.
#!/bin/bash | |
# This is a unix wrapper around the erlang vm. It provides the following functionality: | |
# | |
# * Spawns in foreground | |
# * Handle SIGHUP and call RELOADFUNC | |
# * Handle SIGTERM SIGQUIT and SIGINT telling to the vm to quit | |
# * Dies if the vm dies (for example kernel killing because out of memory) | |
# | |
# Forks and improvements are welcome. |
-module(lb). | |
-compile(export_all). | |
-include_lib("stdlib/include/qlc.hrl"). | |
-include_lib("kernel/include/inet.hrl"). | |
start_lb() -> | |
{ok, Redis} = eredis:start_link(), | |
eredis:q(Redis, ["FLUSHALL" | []]), | |
spawn_link(?MODULE, loop0, [1883,Redis]), | |
spawn_link(?MODULE, loop1, [1884,Redis]). |
var https = require("https") | |
, fs = require("fs") | |
, spawn = require('child_process').spawn | |
, AWS = require('aws-sdk'); | |
var CONFIG = { | |
username: "<github-username>" | |
, password: "<github-password>" | |
, backupdir: "/where/to" | |
, bucket: "github.backup" |
#!/bin/bash | |
function opt_parse() { | |
local _idx=1 | |
local _last="" | |
while [ $_idx -lt $# ] || [ $_idx -eq $# ]; do | |
_v=${!_idx} | |
if [[ $_v == --* ]]; then | |
local _name=$(echo $_v | tr - _) | |
eval "__program_argument${_name}=::is-arg-set" |