Skip to content

Instantly share code, notes, and snippets.

View vyper's full-sized avatar

Leonardo Saraiva vyper

View GitHub Profile
@steveclarke
steveclarke / capybara.md
Created April 10, 2012 17:32
RSpec Matchers

Capybara

save_and_open_page

Matchers

have_button(locator)
@MohamedAlaa
MohamedAlaa / tmux-cheatsheet.markdown
Last active November 19, 2024 10:49
tmux shortcuts & cheatsheet

tmux shortcuts & cheatsheet

start new:

tmux

start new with session name:

tmux new -s myname
@adilsoncarvalho
adilsoncarvalho / kernel-task-fixer.sh
Created January 7, 2013 03:31
Fixing the issue that was making kernel_task be always at 300% on Mac -- still no idea how to make the fans get back at 2.000 rpm
# from: http://www.rdoxenham.com/?p=259
# Mine is Model Identifier: MacBookPro8,3
system_profiler -detailLevel mini | grep "Model Identifier:"
cd /System/Library/Extensions/IOPlatformPluginFamily.kext/Contents/PlugIns/ACPI_SMC_PlatformPlugin.kext/Contents/Resources
sudo mv MacBookPro8_3.plist ~/Desktop
sudo reboot now
@koycarraway
koycarraway / _vars-social-colors.scss
Last active April 7, 2020 05:34
Sass color variables for popular brands and social media.
// Social Colors
// ====================================================================
$facebook_color : hsla(222, 47%, 40%, 1); // #365397
$twitter_color : hsla(198, 100%, 47%, 1); // #00a9f1
$linkedin_color : hsla(203, 100%, 35%, 1); // #006db3
$apple_color : hsla(0, 0%, 45%, 1); // #737373
$google_color : hsla(217, 89%, 61%, 1); // #4285f4
$google_plus_color : hsla(8, 74%, 53%, 1); // #e0452c
@marcocarvalho
marcocarvalho / excel_spreedsheet_column_notation_calculator
Last active December 21, 2015 21:08
Excel / SpreedSheet column notation calculator in ruby
#!/usr/bin/env ruby
module Spreedsheet
module ColumnNotation
def seed
@seed ||= ('A'..'Z').to_a
end
def position_to_column_notation(num, minus = 0)
m = num.divmod(seed.size)
@sidonath
sidonath / flash.rb
Last active August 29, 2015 14:00
An implementation of flash feature on top of Lotus::Action::Session
# A basic Rails-like Flash implementation built upon Lotus::Action::Session.
# Based upon Rack-flash:
# https://github.com/nakajima/rack-flash
module Flash
def self.included(action)
action.class_eval do
# We rely on features provided by Lotus::Action::Session so let's include
# it right here
include Lotus::Action::Session
@skanev
skanev / rubocop.rb
Last active March 13, 2024 08:24
A Rubocop wrapper that checks only added/modified code
#!/usr/bin/env ruby
# A sneaky wrapper around Rubocop that allows you to run it only against
# the recent changes, as opposed to the whole project. It lets you
# enforce the style guide for new/modified code only, as opposed to
# having to restyle everything or adding cops incrementally. It relies
# on git to figure out which files to check.
#
# Here are some options you can pass in addition to the ones in rubocop:
#
@MaxLap
MaxLap / rubocop.rb
Last active March 12, 2024 17:15 — forked from skanev/rubocop.rb
A Rubocop wrapper that checks only added/modified code
#!/usr/bin/env ruby
# A sneaky wrapper around Rubocop that allows you to run it only against
# the recent changes, as opposed to the whole project. It lets you
# enforce the style guide for new/modified code only, as opposed to
# having to restyle everything or adding cops incrementally. It relies
# on git to figure out which files to check.
#
# Here are some options you can pass in addition to the ones in rubocop:
#