Skip to content

Instantly share code, notes, and snippets.

José Albornoz eljojo

Block or report user

Report or block eljojo

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@eljojo
eljojo / 0_reuse_code.js
Created Jul 5, 2017
Here are some things you can do with Gists in GistBox.
View 0_reuse_code.js
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console
@eljojo
eljojo / hash_manipulation.rb
Created Dec 8, 2015
some playing with functional programming and ruby
View hash_manipulation.rb
# A HashManipulation is a helper object.
# The idea is to aid when modifying hashes.
# changes = HashManipulation.new
# changes.key { |key| key.upcase }
# changes.value { |value| value.length }
# changes.("children" => [1, 2, 3]) # {"CHILDREN" => 3}
module Reports
class HashManipulation
def initialize
@key = -> (obj) { obj }
@eljojo
eljojo / growth_hacking.md
Last active Aug 29, 2015
Growth Hacking
View growth_hacking.md

I know about the existence of Growth Hacking and I know that as a StartUp one of your goals is to, well, grow as much as possible.
I also know about the existence of promotional posts, and how they can benefit both writers and companies looking to reach audiences.
What I didn't know, is how low some companies can go in order to promote their business for free.
Without further ado, here's an email I got yesterday. Let it speak by itself.

Hi Jose Tomas,

We’d love to see what tips you have for social media marketers. 

We would like you to create a post on your personal blog where you share
View example_html.html
<html>
<head>
<title>This is the title</title>
<link rel="stylesheet" href="http://railsgirls.com/assets/bootstrap.css">
<link rel="stylesheet" href="http://railsgirls.com/assets/bootstrap-theme.css">
</head>
<body>
<h1>Hello HTML!</h1>
<p>How's it going?</p>
<form action="/add_to_list" method="get">
@eljojo
eljojo / gist:be8a0feff34b4d02509b
Created May 4, 2015
dokku_on_debian_after_fixing_nginx
View gist:be8a0feff34b4d02509b
root@dokku:~/dokku# make install
apt-get update
Hit http://security.debian.org jessie/updates InRelease
Hit http://ftp.de.debian.org jessie InRelease
Hit http://security.debian.org jessie/updates/main Sources
Hit http://ftp.de.debian.org jessie-updates InRelease
Hit http://security.debian.org jessie/updates/main amd64 Packages
Hit http://ftp.de.debian.org jessie/main Sources
Hit http://security.debian.org jessie/updates/main Translation-en
Hit http://ftp.de.debian.org jessie/main amd64 Packages
View gist:883518d6608507c10758
root@dokku:~# wget -qO- https://raw.github.com/progrium/dokku/master/bootstrap.sh|DOKKU_BRANCH=master bash
Hit http://security.debian.org jessie/updates InRelease
Hit http://ftp.de.debian.org jessie InRelease
Hit http://security.debian.org jessie/updates/main Sources
Hit http://ftp.de.debian.org jessie-updates InRelease
Hit http://security.debian.org jessie/updates/main amd64 Packages
Hit http://security.debian.org jessie/updates/main Translation-en
Hit http://ftp.de.debian.org jessie/main Sources
Hit http://ftp.de.debian.org jessie/main amd64 Packages
Hit http://ftp.de.debian.org jessie/main Translation-en
View rant.md

My problem is mainly when, because of sofware, database (or anything related to IT) architecture impose its way into how the real world works.

For example, imagine Deutsche Telekom. If you have a contract for both mobile phone and internet at home with them, it's completely reasonable that they have different internal systems and thus your name is stored in different locations.

Let's say you change your name. You call Deutsche Telekom (mobile) and tell them that you changed your name, the lady tells you that she updated your name in the computer and all is good. Next month you get the invoice and it shows your old name.

My question is: is this acceptable?

@eljojo
eljojo / internet_poetry.mail
Created Feb 23, 2015
Every now and then I receive this weird emails with seemingly random content.
View internet_poetry.mail
Delivered-To: 5baa711a@eljojo.net
Received: by 10.70.42.72 with SMTP id m8csp1076269pdl;
Mon, 23 Feb 2015 01:36:13 -0800 (PST)
X-Received: by 10.68.237.165 with SMTP id vd5mr17877560pbc.44.1424684173209;
Mon, 23 Feb 2015 01:36:13 -0800 (PST)
Return-Path: <Jane4b5@almaraya-uae.com>
Received: from node-ah4.pool-125-27.dynamic.totbb.net ([115.31.129.114])
by mx.google.com with ESMTP id su9si8855158pab.162.2015.02.23.01.36.12
for <5baa711a@eljojo.net>;
Mon, 23 Feb 2015 01:36:12 -0800 (PST)
View keybase.md

Keybase proof

I hereby claim:

  • I am eljojo on github.
  • I am eljojo (https://keybase.io/eljojo) on keybase.
  • I have a public key whose fingerprint is 85DE C355 32D7 551C 39D7 F35E 7342 F862 59B0 A5D0

To claim this, I am signing this object:

@eljojo
eljojo / callback_example.rb
Created Sep 23, 2014
example of what a callback is using active record
View callback_example.rb
class User < ActiveRecord::Base
# here we set tha callback to be executed before saving the user
before_save :create_username
def create_username
if username.blank?
self.username = "example username"
end
end
You can’t perform that action at this time.