(C-x means ctrl+x, M-x means alt+x)
The default prefix is C-b. If you (or your muscle memory) prefer C-a, you need to add this to ~/.tmux.conf
:
require 'io/console' | |
# Reads keypresses from the user including 2 and 3 escape character sequences. | |
def read_char | |
STDIN.echo = false | |
STDIN.raw! | |
input = STDIN.getc.chr | |
if input == "\e" then | |
input << STDIN.read_nonblock(3) rescue nil |
#!/bin/bash | |
usage() { | |
echo "usage: git switchbranch" | |
} | |
version() { | |
echo "switchbranch v0.0.2" | |
} |
#!/usr/bin/env bash | |
mkdir vim | |
curl https://s3.amazonaws.com/heroku-vim/vim-7.3.tar.gz --location --silent | tar xz -C vim | |
export PATH=$PATH:/app/vim/bin |
create different ssh key according the article Mac Set-Up Git
$ ssh-keygen -t rsa -C "your_email@youremail.com"
// Generated from message.mirah | |
// Also See: https://github.com/mirah/mirah_model/blob/master/src/model.mirah | |
package models; | |
public class Message extends com.google.appengine.ext.mirah.db.Model { | |
private java.lang.String title; | |
private java.util.Date published; | |
private java.lang.String link; | |
private java.lang.String summary; | |
private boolean is_reply; | |
private boolean is_featured; |
<!DOCTYPE html> | |
<html> | |
<body> | |
<canvas id="c" style="width:500px; height:500px; background-color: grey"> | |
</canvas> | |
<script> |
namespace :deploy do | |
PRODUCTION_APP = 'myapp' | |
STAGING_APP = 'myapp-staging' | |
def run(*cmd) | |
system(*cmd) | |
raise "Command #{cmd.inspect} failed!" unless $?.success? | |
end | |
def confirm(message) |
desc "Deploy to Heroku. Pass APP=appname to deploy to a different app" | |
task :deploy do | |
require 'heroku' | |
require 'heroku/command' | |
user, pass = File.read(File.expand_path("~/.heroku/credentials")).split("\n") | |
heroku = Heroku::Client.new(user, pass) | |
cmd = Heroku::Command::BaseWithApp.new([]) | |
remotes = cmd.git_remotes(File.dirname(__FILE__) + "/../..") |