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 :db do desc "Backup database to AWS-S3" | |
task :backup => [:environment] do | |
datestamp = Time.now.strftime("%Y-%m-%d_%H-%M-%S") | |
backup_filename = "#{Rails.root.basename}-#{datestamp}.sql" | |
db_config = ActiveRecord::Base.configurations[Rails.env] | |
# process backup | |
`mysqldump -u #{db_config['username']} -p#{db_config['password']} -i -c -q #{db_config['database']} > tmp/#{backup_filename}` | |
`gzip -9 tmp/#{backup_filename}` | |
puts "Created backup: #{backup_filename}" |
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
// ==UserScript== | |
// @name HQLive ad remover | |
// @description Version 1.2 - Remove annoying chat and ad iframes from hqlive | |
// @namespace http://hqlive.net/ | |
// @include http://*hqlive.net/* | |
// @include http://*cricket-365.tv/* | |
// @include http://*cricvid.com/* | |
// @include http://*cricvip.com/* | |
// @include http://*live365.tv/* |
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
कहाँ से तू आती है | |
कहाँ को तू जाती है | |
सपनों को सजाती है | |
अपनों को ले जाती है | |
बाग़ों में जब बहती है | |
कानों में कुछ कहती है | |
आती है नज़र नहीं | |
साँसों में पर रहती है | |
हवा है पवन है | |
वायु है , पुरवाई है |
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
--git a/css/wcs_style.css b/css/wcs_style.css | |
index ad4c85f..ec2d248 100644 | |
--- a/css/wcs_style.css | |
+++ b/css/wcs_style.css | |
@@ -1,6 +1,21 @@ | |
#content .wcs-schedule-table { | |
font-size: 12px; | |
} | |
+ | |
+#content .wcs-upcoming-schedule-table { |
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
javascript:Quix();function Quix() { | |
var e=encodeURIComponent; // shortcut for the function name | |
var t=window.getSelection ? window.getSelection(): | |
(document.getSelection? document.getSelection(): (document.selection ? document.selection.createRange().text:'')); // Get selection or empty string | |
var c=window.prompt('Quix: Type `help` for a list of commands:'); | |
if(t!='') { | |
if(c) { | |
c+=' '+t; // append selection to typed text | |
} | |
else { |
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
javascript:function loadScript(u) { | |
var s = document.createElement('script'); | |
s.setAttribute('src', u); | |
s.onreadystatechange= function () { | |
bmhelper(); | |
}; | |
s.onload = bmhelper; | |
document.getElementsByTagName('body')[0].appendChild(s);} | |
loadScript('http://ajax.googleapis.com/ajax/libs/jquery/1/jquery.min.js'); | |
function bmhelper(){ |
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
diff --git a/git-wiki.rb b/git-wiki.rb | |
index 9f36624..337a5f6 100755 | |
--- a/git-wiki.rb | |
+++ b/git-wiki.rb | |
@@ -20,7 +20,7 @@ end | |
get '/:page/append' do | |
@page = Page.new(params[:page]) | |
- @page.body = @page.raw_body + "\n\n" + params[:text] | |
+ @page.append params[:text] |
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
# = Icebox : Caching for HTTParty | |
# | |
# First stab at implementing caching for HTTParty (http://github.com/jnunemaker/httparty/) | |
# Modeled after Martyn Loughran's APICache (http://github.com/newbamboo/api_cache/) | |
# | |
# = Usage | |
# 1. <tt>include Icebox</tt> in YourPartyAnimalClass | |
# 2. Use <tt>YourPartyAnimalClass.get_cached()</tt> instead of simple <tt>get()</tt> | |
require 'logger' |
NewerOlder