Skip to content

Instantly share code, notes, and snippets.

View jorgeacaballero's full-sized avatar
🎯
Focusing

Jorge Caballero jorgeacaballero

🎯
Focusing
View GitHub Profile
@jorgeacaballero
jorgeacaballero / deploy.rb
Last active January 27, 2016 17:28
Mina Deploy Config
require 'mina/bundler'
require 'mina/rails'
require 'mina/git'
# require 'mina/rbenv' # for rbenv support. (http://rbenv.org)
require 'mina/rvm' # for rvm support. (http://rvm.io)
# Basic settings:
# domain - The hostname to SSH to.
# deploy_to - Path to deploy into.
# repository - Git repo to clone from. (needed by mina/git)
@jorgeacaballero
jorgeacaballero / mina-deploy
Created January 27, 2016 17:42
Mina deploy output
mina deploy
[email protected]'s password:
-----> Using RVM environment 'ruby-2.2.1@default'
= rvm
* https://rvm.io/
* https://github.com/wayneeseguin/rvm/
== DESCRIPTION:
posts = [p for p in posts if p.title != ""]
import collections
def get_flat_int_array(input):
for item in input:
# check if its an array
if isinstance(item, collections.Iterable):
# if it is, apply recursive
for sub_array in get_flat_int_array(item):
yield sub_array
else: