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
{ | |
"auto_complete": false, | |
"binary_file_patterns": | |
[ | |
"*.jpg", | |
"*.jpeg", | |
"*.png", | |
"*.gif", | |
"*.ttf", | |
"*.tga", |
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
% Facts | |
parent(dirce, gislene). | |
parent(dirce, irair). | |
parent(valdemar, gislene). | |
parent(valdemar, irair). | |
parent(gislene, alexandre). | |
parent(gislene, fakebrother). | |
parent(irair, fernando). | |
% Rules |
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
yaml = YAML.load_file("#{Rails.root}/config/shopping.yml") | |
yaml.each do |tab, products| | |
products.each do |a, values| | |
tab_name = tab.gsub ' ', '_' | |
name = values.first.gsub ' ', '' | |
link = values.last | |
puts "#{tab_name}: #{name}" | |
puts "http://clicklogger.rm.uol.com.br/shopping/?prd=239&grp=skin:clickjogos;src:14;size:19;chn:102;pos:4;thm:#{tab_name};creative:#{name}&msr=Cliques%20de%20Origem:1&oper=11&redir=#{ link }" | |
puts |
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
RewriteCond %{HTTP_USER_AGENT} ^Fly [NC,OR] | |
RewriteCond %{HTTP_USER_AGENT} ^htc [NC,OR] | |
RewriteCond %{HTTP_USER_AGENT} ^HTC [NC,OR] | |
RewriteCond %{HTTP_USER_AGENT} ^Huawei [NC,OR] | |
RewriteCond %{HTTP_USER_AGENT} ^HUAWEI [NC,OR] | |
RewriteCond %{HTTP_USER_AGENT} ^INQ [NC,OR] | |
RewriteCond %{HTTP_USER_AGENT} ^LENOVO [NC,OR] | |
RewriteCond %{HTTP_USER_AGENT} ^LG [NC,OR] | |
RewriteCond %{HTTP_USER_AGENT} ^MAUI [NC,OR] | |
RewriteCond %{HTTP_USER_AGENT} ^mot- [NC,OR] |
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
# m.clickjogos | |
if ($http_user_agent ~ (^Fly|^htc|^HTC|^Huawei|^HUAWEI|^INQ|^LENOVO|^LG|^MAUI|^mot-|^MOT|^nokia|^NOKIA|^NEC|^Openwave| | |
^OPENWAVE|^samsung|^SEC|^sgh|^SPH-|^SIE|^Xda|^ZTE|ACS-NF|Amoi|Android|Alcatel|BenQ|BENQ|BlackBerry| | |
Cellphone|DoCoMo|ericsson|Ericsson|HTC|Hutchison|imode|iPAQ|iPhone|LGE|Maemo|Maui\ Browser|MAUI\ WAP| | |
MIDP|Mitsu|Mobi|mobile|Mobile|Motorola|NetFront|Netfront|Nintendo\ DSi|nokia|Nokia|Obigo|Palm| | |
Panasonic|PHILIPS|Phone|PlayStation\ Portable|portalmmm|SAGEM|SAMSUNG|Samsung|SANYO|Sanyo|SCH\-|Sendo| | |
SHARP|Smartphone|SmartPhone|Symbian\ OS|SymbianOS|Teleca|Toshiba|UP\.Browser|Vodafone|webOS|wap|WAP|Windows\ CE) ) { | |
rewrite ^(.*) http://m.clickjogos.uol.com.br/ permanent; | |
} |
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
find ./ -type f | grep .DS_Store | xargs rm |
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
# http://blog.philippklaus.de/2011/07/sshfs-on-mac-os-x-10-6-8-with-fuse4x/ | |
# http://www.unityisplural.com/2011/11/getting-fuse4x-installed-on-osx-lion.html | |
xcode-select --switch /Applications/Xcode.app | |
brew install fuse4x sshfs | |
sudo cp -rfX /usr/local/Cellar/fuse4x-kext/0.10.0/Library/Extensions/fuse4x.kext /Library/Extensions | |
sudo chmod +s /Library/Extensions/fuse4x.kext/Support/load_fuse4x |
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
pt-BR: | |
activemodel: | |
attributes: | |
pag_seguro/order: | |
abandon_url: | |
address: Endereço | |
address_city: Cidade | |
address_complement: Complemento | |
address_district: Bairro | |
address_number: Número |
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 index | |
client = TwitterOAuth::Client.new( :consumer_key => 'key', :consumer_secret => 'key') | |
if session['token'].blank? | |
session['token'] = client.request_token(:oauth_callback => 'http://127.0.0.1:8000') | |
end | |
request_token = session['token'] | |
if params['oauth_token'].blank? | |
redirect_to request_token.authorize_url |
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
namespace :backup do | |
task :set_name do | |
set :backup_folder, "/tmp" | |
set :backup_name, "#{application}-#{DateTime.now.strftime('%Y-%m-%d_%H-%M-%S')}" | |
set :backup_path, "#{backup_folder}/#{backup_name}" | |
end | |
task :db do | |
yml = YAML.load_file("#{repository}/config/database.yml") |