注意:本文内容适用于 Tmux 2.3 及以上的版本,但是绝大部分的特性低版本也都适用,鼠标支持、VI 模式、插件管理在低版本可能会与本文不兼容。
启动新会话:
tmux [new -s 会话名 -n 窗口名]
恢复会话:
• Node 1, 2, … X | |
○ sudo su -l | |
○ cd | |
○ apt-get update | |
○ apt-get upgrade | |
○ apt-get install git-core | |
○ apt-get install libyaml-dev | |
○ apt-get install erlang | |
○ apt-get install unzip | |
○ apt-get build-dep ejabberd |
class Api::RegistrationsController < Api::BaseController | |
respond_to :json | |
def create | |
user = User.new(params[:user]) | |
if user.save | |
render json: user.as_json(auth_token: user.authentication_token, email: user.email), status: :created | |
return | |
else |
Get the Heroku db as detailed here: | |
http://devcenter.heroku.com/articles/pgbackups#exporting_via_a_backup | |
1. heroku pgbackups:capture | |
2. heroku pgbackups:url <backup_num> #=>backup_url | |
- get backup_num with cmd "heroku pgbackups" | |
3. curl -o latest.dump <backup_url> | |
Then locally do: | |
$ pg_restore --verbose --clean --no-acl --no-owner -h localhost -U myuser -d mydb latest.dump |