Skip to content

Instantly share code, notes, and snippets.

View thelastinuit's full-sized avatar
🖖
חֶסֶד שֶׁל אֱמֶת

luis ignacio thelastinuit

🖖
חֶסֶד שֶׁל אֱמֶת
View GitHub Profile
@thelastinuit
thelastinuit / silver.md
Created March 14, 2019 14:13
Silver Certification

Ruby Association Certified Ruby Examination Silver Sample Questions

Q1. Which of the following have true values in Ruby? (Choose two.)

  • (a) ""
  • (b) 0
  • (c) false
  • (d) nil

@thelastinuit
thelastinuit / gold.md
Created March 14, 2019 14:13
gold certification prep

Ruby Association Certified Ruby Examination Gold Sample Questions

Q1. Assume that the following code must have the stated execution result.

__(1)__
x.each_line { |line| puts line }

[Execution Result]
apple
@thelastinuit
thelastinuit / sidekiq_monitoring
Created March 4, 2019 16:50 — forked from ngsmrk/sidekiq_monitoring
Sidekiq queue checking via rails console
stats = Sidekiq::Stats.new
stats.queues
stats.enqueued
stats.processed
stats.failed
@thelastinuit
thelastinuit / wait_until.rb
Created January 25, 2019 18:16 — forked from metaskills/wait_until.rb
Never sleep() using Capybara!
# Have you ever had to sleep() in Capybara-WebKit to wait for AJAX and/or CSS animations?
describe 'Modal' do
should 'display login errors' do
visit root_path
click_link 'My HomeMarks'
within '#login_area' do
fill_in 'email', with: 'will@not.work'
fill_in 'password', with: 'test'
@thelastinuit
thelastinuit / life.lisp
Created November 10, 2018 23:27 — forked from masatoi/life.lisp
life
(ql:quickload 'lispbuilder-sdl)
(ql:quickload 'lispbuilder-sdl-gfx)
(ql:quickload 'alexandria)
(defparameter world (make-array '(100 100) :element-type 'fixnum))
;; initialize
(defun init-world! (world)
(loop for i from 0 to (1- (array-dimension world 0)) do
(loop for j from 0 to (1- (array-dimension world 1)) do
@thelastinuit
thelastinuit / ipfs.sh
Last active October 13, 2018 22:33 — forked from sanderpick/ipfs.sh
Install ipfs on Amazon Linux.
#!/usr/bin/env bash
set -e
echo 'export IPFS_PATH=/data/ipfs' >>~/.bash_profile
source ~/.bash_profile
# ipfs daemon
wget https://dist.ipfs.io/go-ipfs/v0.4.17/go-ipfs_v0.4.17_linux-amd64.tar.gz
tar xvfz go-ipfs_v0.4.17_linux-amd64.tar.gz
@thelastinuit
thelastinuit / docker.md
Created October 2, 2018 01:49 — forked from f3l1x/aliases
Docker - installation, tips, commands, aliases

Docker

Shortcuts

$ curl -fsSL https://raw.github.com/tcnksm/docker-alias/master/zshrc >> ~/.bashrc && source ~/.bashrc
# ------------------------------------
@thelastinuit
thelastinuit / readme.md
Created July 28, 2018 04:33
Full-stack Developer Interview Questions and Answers
require "test/unit"
module ArrayFunctions
class << self
def flatten(array, flatten_array = [])
raise "Nothing to do" unless array
array.each do |element|
if element.is_a? Integer
flatten_array << element
@thelastinuit
thelastinuit / Gemfile
Created February 25, 2018 08:38 — forked from Joseph-N/Gemfile
File upload using dropzone.js, paperclip in rails. Tutorial link http://josephndungu.com/tutorials/ajax-file-upload-with-dropezonejs-and-paperclip-rails
source 'https://rubygems.org'
# default gems here
#---------------------------
# add paperclip and bootstrap
gem "paperclip", "~> 4.1"
gem 'bootstrap-sass', '~> 3.1.1'