Skip to content

Instantly share code, notes, and snippets.

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

Cristian Molina megatux

🏠
Working from home
View GitHub Profile
@megatux
megatux / gist:4660545
Last active December 11, 2015 21:09
move imgs to jquery carousel
$('.md img').each(
function(i){
img = $(this);
$('#locations-carousel .carousel-inner').append(
'<div class="item">' + img.html() + '</div>');
//img.remove();
}
)
@megatux
megatux / cheat sheet
Created April 16, 2013 18:32
cheat sheet for rake, git, rvm, texmate, etc
bundle
------
bundle update
bundle show GEM_NAME
bundle exec ....
rake
----
@megatux
megatux / gist:5670584
Created May 29, 2013 14:16
setup ruby mac environment
instalar xcode o las dev-tools (muucho mas chico)
instalar un editor como Texmate o Sublime2
instalar brew
brew install bash-completion
brew install git
instalar ruby (con RVM o rbenv)
brew install mysql postgresql
brew install imagemagick
@megatux
megatux / .bashrc
Last active December 17, 2015 22:00
.bashrc bash shell configuration
GIT_PS1_SHOWDIRTYSTATE=true
PS1='\[\033[32m\]\u@\h\[\033[00m\]:\[\033[34m\]\w\[\033[31m\]$(__git_ps1)\[\033[00m\]\$ '
export PATH=/usr/local/sbin:/usr/local/bin:$PATH:$HOME/bin:`npm bin`
export PATH=/usr/local/php5/bin:$PATH
export PATH="$HOME/.rbenv/bin:$PATH"
export EDITOR='mate -w'
export GIT_EDITOR='mate -wl1'
export LESSEDIT='mate -l %lm %f'
export ANDROID_SDK_ROOT=/usr/local/Cellar/android-sdk/r18
@megatux
megatux / .tm_properties
Created May 30, 2013 16:22
Textmate2 .tm_properties configuration
fontSize = 20
excludeInFileChooser = "{$excludeInFileChooser,log,tmp,META-INF,.svn}"
excludeInBrowser = "{$excludeInBrowser,log,vendor,tmp,META-INF,.svn,.git}"
excludeInFolderSearch = "{$excludeInFolderSearch,log,public/system,public/uploads,tmp,META-INF,.svn,.git}"
TM_RUBY = "$HOME/.rbenv/shims/ruby"
PATH = "$HOME/.rbenv/bin:$PATH:/usr/local/bin:/Users/cristian/node_modules/.bin"
@megatux
megatux / .gitconfig
Created May 30, 2013 16:57
.gitconfig git configuration
[core]
excludesfile = /Users/cristian/.gitignore
editor = vim
[alias]
st = status
ci = commit
co = checkout
br = branch
[user]
name = Cristian Molina
@megatux
megatux / s3cmd commands
Created October 3, 2013 16:46
s3cmd commands
brew install s3cmd
s3cmd --configure
s3cmd --dry-run --recursive sync newsan-s3 s3://newsan-staging/
s3cmd --recursive sync newsan-s3 s3://newsan-staging/
s3cmd info s3://newsaniptv/
s3cmd --recursive setacl --acl-public s3://newsaniptv
@megatux
megatux / dockersetup.MD
Created September 22, 2016 14:16 — forked from diniremix/dockersetup.MD
setup docker on elementary OS freya

instalar docker

instalar una imagen (ubuntu 14.04 en este caso)

  • sudo docker run ubuntu:14.04

revisar las imagenes instaladas

  • sudo docker images

entrar en la imagen recien creada

@megatux
megatux / Capybara cheat sheet.md
Last active August 9, 2017 13:29 — forked from zhengjia/capybara cheat sheet
Capybara cheat sheet

Navigating

visit('/projects')
visit(post_comments_path(post))

Inside same page

visit '#footer'
page.execute_script "window.scrollBy(0,500)"

page.execute_script(%Q{$("#scrollElement").prop("scrollTop", 1000000).trigger('scroll')})

This file has been truncated, but you can view the full file.
/home/megatux/.asdf/installs/ruby/2.5.1/lib/:
total 60504
-rw-r--r-- 1 megatux megatux 61947304 sep 23 23:37 libruby-static.a
drwxr-xr-x 2 megatux megatux 4096 sep 23 23:39 pkgconfig
drwxr-xr-x 6 megatux megatux 4096 sep 23 23:39 ruby
/home/megatux/.asdf/installs/ruby/2.5.1/lib/pkgconfig:
total 4
-rw-r--r-- 1 megatux megatux 1945 sep 23 23:36 ruby-2.5.pc