start new:
tmux
start new with session name:
tmux new -s myname
| /** | |
| * Draw SVG in canvas | |
| */ |
| (Copied From: http://alexfluger.blogspot.com/2012/01/easy-deploy-to-ftp-from-git.html) (Thank you Alex, this has helped me alot!) | |
| Easy deploy to FTP from GIT | |
| Have a shared hosting? No SSH and Git? Take a look on git-ftp. It is very easy to install and use. Here I will show you how to install it and start to use. | |
| Installation | |
| First, clone source code repository from github (it will create git-ftp folder): |
| # edit smb.conf file | |
| # sudo vim /etc/samba/smb.conf | |
| # | |
| # Sample configuration file for the Samba suite for Debian GNU/Linux. | |
| # | |
| # |
| /*! ****************************** | |
| Handlebars helpers | |
| *******************************/ | |
| // debug helper | |
| // usage: {{debug}} or {{debug someValue}} | |
| // from: @commondream (http://thinkvitamin.com/code/handlebars-js-part-3-tips-and-tricks/) | |
| Handlebars.registerHelper("debug", function(optionalValue) { | |
| console.log("Current Context"); | |
| console.log("===================="); |
| var express = require('express'); | |
| var sys = require('util'); | |
| var oauth = require('oauth'); | |
| var app = express.createServer(); | |
| var _twitterConsumerKey = process.env['TWITTER_CONSUMER_KEY']; | |
| var _twitterConsumerSecret = process.env['TWITTER_CONSUMER_SECRET']; | |
| console.log("_twitterConsumerKey: %s and _twitterConsumerSecret %s", process.env['TWITTER_CONSUMER_KEY'], process.env['TWITTER_CONSUMER_SECRET']); |
| # First, download the latest version from: http://www.sublimetext.com/2 | |
| # In my case choice: Linux 64 bits [[http://c758482.r82.cf2.rackcdn.com/Sublime%20Text%202.0.2%20x64.tar.bz2]] | |
| cd ~/downloads | |
| # unzip: Sublime Text 2.0.2 x64.tar.bz2 | |
| tar xf Sublime\ Text\ 2.0.2\ x64.tar.bz2 |
| var loadQueue = function() { | |
| var q = queue(), | |
| defer = q.defer, | |
| dispatch = d3.dispatch("progress", "complete"), | |
| requests = []; | |
| q.defer = function(load, url) { | |
| return defer(function(callback) { | |
| var req = load(url, function(error, data) { | |
| req.loaded = req.total; |
| Se modifica el archivo en modo adminitrador: | |
| ~ sudo [nombre_editor] /etc/environment/ | |
| y se agregan estas líneas | |
| no_proxy="127.0.0.1,localhost" | |
| NO_PROXY="127.0.0.1,localhost" | |
| all_proxy=socks://172.21.0.12:3128/ | |
| ALL_PROXY=socks://172.21.0.12:3128/ |
| function server(){ | |
| local port="${1:-8000}" | |
| open "http://localhost:${port}/" | |
| python -m SimpleHTTPServer "$port" | |
| } |