This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Configure touchpads to use xf86-input-synaptics X input driver | |
Section "InputClass" | |
Identifier "touchpad" | |
MatchIsTouchpad "on" | |
MatchDevicePath "/dev/input/event*" | |
Driver "synaptics" | |
Option "MinSpeed" "0.4" | |
Option "MaxSpeed" "1.0" | |
Option "AccelFactor" "0.0035" | |
Option "HorizScrollDelta" "6" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def 😄(😡) | |
if 😡 == "😎" | |
puts "Yay UTF8!" | |
end | |
end | |
😛 = "😎" | |
😄 😛 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$('.gallery_button a').click -> | |
console.log('y0') |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
dispatch_queue_t myQueue = dispatch_get_global_queue(DISPATCH_QUEUE_PRIORITY_HIGH, 0); | |
dispatch_async(myQueue, ^{ | |
[self performSelectorOnMainThread:@selector(someActionToUpdate:) withObject:an_object waitUntilDone:YES]; | |
}); | |
-(void)someActionToUpdate:(id)an_object { | |
// an_object can be any kind of type | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
module Screen | |
def self.clear | |
print "\e[2J\e[f" | |
end | |
end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
source :rubygems | |
# We are not loading Active Record, nor Active Resources etc. | |
# We can do this in any app by simply replacing the rails gem | |
# by the parts we want to use. | |
gem "actionpack", "~> 3.2" | |
gem "railties", "~> 3.2" | |
gem "tzinfo" | |
# Let's use thin |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
total = 0 | |
Dir["./**/*.*"].each do |f| | |
filenumber =%x{wc -l #{f}}.split.first | |
puts f+ " - "+count = filenumber | |
total = total + filenumber.to_i | |
end | |
puts "Total lines = #{total}" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Run this file with `RAILS_ENV=production rackup -p 3000 -s thin` | |
# Be sure to have rails and thin installed. | |
require "rubygems" | |
# We are not loading Active Record, nor the Assets Pipeline, etc. | |
# This could also be in your Gemfile. | |
gem "actionpack", "~> 3.2" | |
gem "railties", "~> 3.2" | |
require "rails" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#title { | |
position: absolute; | |
right: 300px; | |
top: 25px; | |
visibility: visible; | |
z-index: 0; | |
text-align: right; | |
font-weight: bold; | |
font-size: 50px; | |
font-family: Helvetica; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#title { | |
position: absolute; | |
right: 300px; | |
top: 25px; | |
visibility: visible; | |
z-index: 0; | |
text-align: right; | |
font-weight: bold; | |
font-size: 50px; | |
font-family: Helvetica; |