Skip to content

Instantly share code, notes, and snippets.

View rafaellucio's full-sized avatar
🏠
Working from home

png rafaellucio

🏠
Working from home
View GitHub Profile
@rafaellucio
rafaellucio / robot.js
Created December 11, 2012 17:29
Rafael Lucio
//FightCode can only understand your robot
//if its class is called Robot
var Robot = function(robot) {};
Robot.prototype.onIdle = function(ev) {
var robot = ev.robot;
robot.ahead(100);
robot.turn(360);
robot.back(100);
};
@rafaellucio
rafaellucio / .bashrc
Last active December 26, 2015 03:39
Developer Config Files
#RVM Configure
PATH=$PATH:$HOME/.rvm/bin # Add RVM to PATH for scripting
[[ -s "$HOME/.rvm/scripts/rvm" ]] && . "$HOME/.rvm/scripts/rvm" # Load RVM function
#Color Bash and replace folder$branch
function parse_git_branch() {
git branch 2> /dev/null | sed -e '/^[^*]/d' -e 's/* \(.*\)/(\1)/'
@rafaellucio
rafaellucio / .gitconfig
Created October 21, 2013 17:28
Developer Config Files
[user]
name = rafaellucio
email = [email protected]
[color]
ui = true
branch = auto
diff = auto
grep = auto
interactive = auto
status = auto
@rafaellucio
rafaellucio / Makefile
Created October 21, 2013 17:37
Developer Config Files Nodejs Test with Mocha
REPORTER = dot
test:
@NODE_ENV=test ./node_modules/.bin/mocha \
--reporter $(REPORTER) \
--ui tdd \
--check-leaks
test-w:
@NODE_ENV=test ./node_modules/.bin/mocha \
@rafaellucio
rafaellucio / gist:29f1f04ca0b497a42309
Last active August 29, 2015 14:03
Install Oracle Java on a Debian

###How To Manually Install Oracle Java on a Debian or Ubuntu VPS

wget --header "Cookie: oraclelicense=accept-securebackup-cookie" http://download.oracle.com/otn-pub/java/jdk/8u5-b13/jdk-8u5-linux-x64.tar.gz

  • Create a directory for your JDK installation:

mkdir /opt/jdk

  • and extract java into the /opt/jdk directory:
@rafaellucio
rafaellucio / .vimrc
Last active August 29, 2015 14:07 — forked from guilhermegregio/.vimrc
"......................................................................ARQUIVO
"" Sai fora na marra!
imap <F12> <esc>:wqa!<cr>
map <F12> :wqa!<cr>
" Abreviacoes uteis para sua sanidade mental
cab W w| cab Q q| cab Wq wq| cab wQ wq| cab WQ wq
" Copy e paste
nmap <F3> :set paste<CR>:r !pbpaste<CR>:set nopaste<CR>
imap <F3> <Esc>:set paste<CR>:r !pbpaste<CR>:set nopaste<CR>
@rafaellucio
rafaellucio / Screen Debian
Last active August 29, 2015 14:23
Usando screen multi command teminal
Reference Install: http://www.tecmint.com/screen-command-examples-to-manage-linux-terminals/
Reference: http://unix.stackexchange.com/questions/26685/how-to-split-window-vertically-in-gnu-screen
Check out the video tutorial on Split Screen with Screen in Linux - BASH - https://www.youtube.com/watch?v=dFdqyccdWUE . At time 2:00 minute, there would be a solution.
`Ctrl`+`A`+`S` # Create another window
`Ctrl`+`A`+`Tab` # Moving from another window
@rafaellucio
rafaellucio / angular.upload.js
Last active May 3, 2016 19:07
Upload Component AngularJs
/*=============Module================*/
import service from './upload.service';
import directive from './upload.directive';
export default angular.module('app.upload', ['app.feedback'])
.service('uploadService', service)
.directive('upload', directive)
.name;
/*=============Service===============*/
@rafaellucio
rafaellucio / dojo-javascript-functions.md
Created June 27, 2017 00:19
Easynvest Dojo Javascript Functions Manipulação de Array

SOMA

let sum = 0
const numbers = [1,2,3,4,5,6,7,8,9,10]

for(let i = 0, len = numbers.length; i < len; i+=1) {
  sum += numbers[i]
}
@rafaellucio
rafaellucio / proposta-professionais
Last active August 28, 2017 01:24
Modelo de proposta - Profissionais
Profissional - A
35
_____________
| |
5 | 175m2 | 5
|_____________|
35
Profissional - B