(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:
| var flattenObject = function(ob) { | |
| var toReturn = {}; | |
| for (var i in ob) { | |
| if (!ob.hasOwnProperty(i)) continue; | |
| if ((typeof ob[i]) == 'object') { | |
| var flatObject = flattenObject(ob[i]); | |
| for (var x in flatObject) { | |
| if (!flatObject.hasOwnProperty(x)) continue; |
| # This is a template .gitignore file for git-managed Prestashop projects. Inspired by micahwalter wordpress gitignore | |
| #Ignore ds_store | |
| *.DS_Store | |
| # Ignore everything in the root except modules, themes and override. | |
| /* | |
| !modules/ | |
| !themes/ |
| # Git visual log displays commit tree view with who did what when and in which branch | |
| git config --global alias.vlog 'log --graph --date-order --date=relative --pretty=format:"%C(cyan)%h: %Cblue - %an - %Cgreen %C(cyan)%ar:%Creset%n%s%n" --color' |
| var http = require('http'), | |
| url = require('url'), | |
| util = require('util'); | |
| http.createServer( function (req, res) { | |
| res.writeHead( 200, {'Content-Type': 'text/plain'} ); | |
| var qs = url.parse( req.url, true ); | |
| res.write( util.inspect( qs.query ) ); |
| -- start the server: $ mysqld --console | |
| -- login: $ mysql -u root --password=wxyz | |
| -- run the script: mysql> source /Users/javapro/dev/src/sql/Cookbook.sql | |
| -- the script: | |
| drop database if exists Cookbook; | |
| create database Cookbook; | |
| connect Cookbook; |
| // Extraido de https://github.com/visionmedia/finance/blob/master/lib/helpers.js | |
| /** | |
| * Months. | |
| */ | |
| var months = [ | |
| 'January' | |
| , 'February' | |
| , 'March' |
| var goose = require('mongoose') | |
| , db = goose.connect('mongodb://localhost/testmongo') | |
| , Schema = goose.Schema | |
| , sc = new Schema({ | |
| a: String, | |
| b: Date | |
| }) | |
| sc.methods.bbb = function() { | |
| return this.b.getFullYear() |
| [alias] | |
| verbs = !git log --pretty=format:'%s' | cut -d \" \" -f 1 | sort | uniq -c | sort -nr |
| A warning occurred (42 apples) | |
| An error occurred |