Skip to content

Instantly share code, notes, and snippets.

View rderoldan1's full-sized avatar
🇨🇴

Ruben Espinosa rderoldan1

🇨🇴
  • Medellin, Colombia
View GitHub Profile
@kwhinnery
kwhinnery / twilio.md
Last active December 27, 2015 17:19
Tutorial for the node knockout 2013

Send Text Messages and Make Phone Calls with Node

The Node Knockout is nigh! As you make last minute preparations for your weekend masterpiece, you may be planning Android, iOS, and browser-based UI for your application. But there's another client platform that's even more ubiquitous - that's the telephone, particularly mobile phones. If you'd like to create experiences for all these devices, Twilio can help you get it done.

In this tutorial, we'll explore how to use the Twilio module for node.js to make and receive phone calls and text messages. This is slightly adapted from a series of introductory blog posts on the Twilio module, which are worth checking out as well if you're interested!

Getting Started

In order to use the Twilio API, you will first need to sign up for a free account. If you sign up with th

.bs-header
.container
= render_breadcrumbs :builder => ::BootstrapBreadcrumbsBuilder
@jookyboi
jookyboi / javascript_resources.md
Created October 19, 2013 16:45
Here are a set of libraries, plugins and guides which may be useful to your Javascript coding.

Libraries

  • jQuery - The de-facto library for the modern age. It makes things like HTML document traversal and manipulation, event handling, animation, and Ajax much simpler with an easy-to-use API that works across a multitude of browsers.
  • Backbone - Backbone.js gives structure to web applications by providing models with key-value binding and custom events, collections with a rich API of enumerable functions, views with declarative event handling, and connects it all to your existing API over a RESTful JSON interface.
  • AngularJS - Conventions based MVC framework for HTML5 apps.
  • Underscore - Underscore is a utility-belt library for JavaScript that provides a lot of the functional programming support that you would expect in Prototype.js (or Ruby), but without extending any of the built-in JavaScript objects.
  • lawnchair - Key/value store adapter for indexdb, localStorage
@n00b2pr0
n00b2pr0 / bs3-panel-heading-pagination.html
Last active December 25, 2015 05:49
Snippet for Pagination in Panel Components Heading and Footer in Bootstrap 3
<div class="panel panel-default">
<div class="panel-heading">
<h3 class="panel-title pull-left">Panel title</h3>
<ul class="pagination pagination-panel pull-right">
<li><a href="#">«</a></li>
<li class="active"><a href="#">1</a></li>
<li><a href="#">2</a></li>
<li><a href="#">3</a></li>
<li><a href="#">4</a></li>
<li><a href="#">5</a></li>
@konklone
konklone / Dockerfile
Created September 22, 2013 18:17
Dockerfile for installing Ruby 2.0 and RVM
FROM ubuntu
MAINTAINER Eric Mill "eric@konklone.com"
# turn on universe packages
RUN echo "deb http://archive.ubuntu.com/ubuntu raring main universe" > /etc/apt/sources.list
RUN apt-get update
# basics
RUN apt-get install -y nginx openssh-server git-core openssh-client curl
RUN apt-get install -y nano
@JamesDullaghan
JamesDullaghan / digitalocean.md
Created July 6, 2013 20:54
Deploy rails app to digitalocean with nginx, unicorn, capistrano & postgres

Deploy Rails app to digitalocean with nginx, unicorn, capistrano & postgres

Create droplet of your liking (ubuntu 12.10 x32)

ssh to root in terminal with your server ip

ssh root@123.123.123.123

Add ssh fingerprint and enter password provided in email

@ryansobol
ryansobol / gist:5252653
Last active November 22, 2023 11:53
15 Questions to Ask During a Ruby Interview

Originally published in June 2008

When hiring Ruby on Rails programmers, knowing the right questions to ask during an interview was a real challenge for me at first. In 30 minutes or less, it's difficult to get a solid read on a candidate's skill set without looking at code they've previously written. And in the corporate/enterprise world, I often don't have access to their previous work.

To ensure we hired competent ruby developers at my last job, I created a list of 15 ruby questions -- a ruby measuring stick if you will -- to select the cream of the crop that walked through our doors.

What to expect

Candidates will typically give you a range of responses based on their experience and personality. So it's up to you to decide the correctness of their answer.

@vital101
vital101 / gil_test.rb
Created November 20, 2012 20:59
Ruby GIL Test Program
# Given the word list, count how many words are in the dictionary.
# Note: This isn't the most efficient way to do thise. If I was going for
# speed, I would have made each dicitonary word the key of a hash, and
# had O(n) lookup times.
def process_words(words, dictionary)
puts "Starting thread #{Thread.current.object_id}\n"
found = 0
words.each do |word|
if dictionary.include? word
@cyx
cyx / gist:3690597
Created September 10, 2012 12:13 — forked from inkel/gist:3690584
Monit Redis
check process redis-server
with pidfile "/var/run/redis.pid"
start program = "/etc/init.d/redis-server start"
stop program = "/etc/init.d/redis-server stop"
if 2 restarts within 3 cycles then timeout
if totalmem > 100 Mb then alert
if children > 255 for 5 cycles then stop
if cpu usage > 95% for 3 cycles then restart
if failed host 127.0.0.1 port 6379 then restart
if 5 restarts within 5 cycles then timeout
@johnantoni
johnantoni / unicorn.rb
Created August 2, 2012 15:48
unicorn + nginx setup + ssl
unicorn.rb
-----------------------------------
application = "jarvis"
remote_user = "vagrant"
env = ENV["RAILS_ENV"] || "development"
RAILS_ROOT = File.join("/home", remote_user, application)
worker_processes 8
timeout 30