This file contains 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
# add this to your ~/.gitconfig under the alias section to allow things like "git brt" | |
[alias] | |
brt = branch-time |
This file contains 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
1. install thor gem | |
> gem install thor | |
2. add wordpress script to your wordpress install root and chmod it | |
> chmod a+x wordpress | |
3. update wordpress | |
> ./wordpress update | |
4. export wordpress (php must have CLI support) |
This file contains 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
default_run_options[:pty] = true | |
load 'deploy' if respond_to?(:namespace) # cap2 differentiator | |
set :application, 'wordpress' | |
set :deploy_to, "/var/sites/#{application}" | |
set :use_sudo, false | |
set :user, 'server-username' | |
server 'example.com', :web, :app, :db |
This file contains 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
require 'byebug' | |
require 'benchmark' | |
require 'timeout' | |
module Decorator | |
def decorate(method, &block) | |
decorator = Module.new do | |
define_method(method, &block) | |
end |
This file contains 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
Index: ext/mysqli/php_mysqli_structs.h | |
=================================================================== | |
--- ext/mysqli/php_mysqli_structs.h (revision 301474) | |
+++ ext/mysqli/php_mysqli_structs.h (working copy) | |
@@ -54,6 +54,7 @@ | |
#define WE_HAD_MBSTATE_T | |
#endif | |
+#define HAVE_ULONG 1 | |
#include <my_global.h> |
This file contains 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
.clearfix:after { | |
content: "."; | |
display: block; | |
height: 0; | |
font-size: 0; | |
clear: both; | |
visibility: hidden; | |
} | |
.clearfix {display: inline-block;} | |
/* Hides from IE5/Mac \*/ |
This file contains 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
<?php | |
$lawpress_settings = array( | |
'lawpress.web_service_section' => array( | |
'title' => 'Web Service Settings', | |
'description' => 'NOTHING', | |
'settings' => array( | |
'lawpress.default_aop' => array( | |
'name' => 'default_aop', | |
'description' => 'Default AOP ID', |
This file contains 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
use Warden::Manager do |config| | |
config.default_strategies :basic | |
config.failure_app = ErrorsController.action(:unauthenticated) | |
end | |
Warden::Strategies.add :basic, HttpAuthBasicStrategy do |config| | |
config.realm = "Welcome!" | |
config.callback do |env, username, password| | |
return username if username == 'rob' | |
false |
This file contains 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
# /usr/local/lib/ruby/site_ruby/1.9.1/rubygems/source_index.rb:68:in `installed_spec_directories': undefined method `path' for Gem:Module (NoMethodError) | |
# solution | |
sudo rm -rf /usr/local/lib/ruby/site_ruby/1.9.1/*ubygem* | |
# make install again |
This file contains 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
<?php | |
// Using the simple model -- its very similar to active record, but | |
// its basic and simple :) (and not that powerful...) | |
require 'simple_model.php'; | |
// set our environment | |
define('ENVIRONMENT', 'development'); | |
// our db configurations | |
$DatabaseAuths = array( |