Skip to content

Instantly share code, notes, and snippets.

View alexcalaca's full-sized avatar

Alexandre Calaça alexcalaca

View GitHub Profile

Gem commands cheatsheet.md

gem list - List all gems installed

gem list -i <gem_name> - It shows if a gem exists or not. The output is true or false

gem list <gem_name> - It shows the gem version Example: gem list zlib

gem which - It shows the gem path

@alexcalaca
alexcalaca / Github cheatsheet-ac.md
Created April 4, 2022 03:38
Github cheatsheet-ac

Github cheatsheet-ac

git log : View commit history git log --stat : View commit history with more details

@alexcalaca
alexcalaca / Immediate versus non-immediate objects benchmark.rb
Created July 18, 2024 04:19
Immediate versus non-immediate objects benchmark
require 'benchmark'
num1 = 42
num2 = 43
immediate_time = Benchmark.realtime do
9_000_000.times do
num1 + num2
end
end