This guide assumes you are on Centos or a Redhat / Fedora system.
sudo yum remove java
sudo yum install java-1.7.0-openjdk
sudo yum install java-1.7.0-openjdk-devel
# download Solr
cd ~/
function countCSSRules() { | |
var results = '', | |
log = ''; | |
if (!document.styleSheets) { | |
return; | |
} | |
for (var i = 0; i < document.styleSheets.length; i++) { | |
countSheet(document.styleSheets[i]); | |
} | |
function countSheet(sheet) { |
# Mac OS X Lion introduced a new, iOS-like context menu when you press and hold a key | |
# that enables you to choose a character from a menu of options. If you are on Lion | |
# try it by pressing and holding down 'e' in any app that uses the default NSTextField | |
# for input. | |
# | |
# It's a nice feature and continues the blending of Mac OS X and iOS features. However, | |
# it's a nightmare to deal with in Sublime Text if you're running Vintage (Vim) mode, | |
# as it means you cannot press and hold h/j/k/l to move through your file. You have | |
# to repeatedly press the keys to navigate. |
<?php | |
/** | |
* Set global/skip_process_modules_updates to '1' in app/etc/local.xml and | |
* then use this script to apply updates and refresh the config cache without | |
* causing a stampede on the config cache. | |
* | |
* @author Colin Mollenhour | |
*/ | |
umask(0); | |
ini_set('memory_limit','512M'); |
// jQuery fix for Webkit SVG height bug. | |
// Documented here: https://bugs.webkit.org/show_bug.cgi?id=82489 & http://www.brichards.co.uk/blog/webkit-svg-height-bug-workaround | |
// Found via: http://stackoverflow.com/questions/7570917/svg-height-incorrectly-calculated-in-webkit-browsers | |
function fixWebkitHeightBug(){ | |
var svgW = 658; | |
var svgH = 500; | |
var curSVGW = $('#svg-container').width(); | |
var newSVGH = heightInRatio(svgH,svgW,curSVGW); |
#!/usr/bin/env bash | |
apt-get update | |
echo mysql-server-5.5 mysql-server/root_password password PASSWORD | debconf-set-selections | |
echo mysql-server-5.5 mysql-server/root_password_again password PASSWORD | debconf-set-selections | |
apt-get install -y mysql-common mysql-server mysql-client | |
apt-get install -y apache2 |
#!/bin/bash | |
# | |
# Monitor MySQL queries | |
# @author Colin Mollenhour | |
set -e | |
mysql="mysql" | |
test="test" | |
bash="bash" |
/* Solarized Dark | |
For use with Jekyll and Pygments | |
http://ethanschoonover.com/solarized | |
SOLARIZED HEX ROLE | |
--------- -------- ------------------------------------------ | |
base03 #002b36 background | |
base01 #586e75 comments / secondary content |
<?php | |
// Extended tester from ezimuel (https://gist.github.com/ezimuel/9135151) | |
// The libxml entity loader is disabled by default | |
// even setting the libxml_disable_entity_loader to false doesn't works! | |
// | |
// @see http://uk3.php.net/manual/en/function.libxml-disable-entity-loader.php | |
// @see http://stackoverflow.com/a/10213239 | |
// @see https://stackoverflow.com/questions/24117700 | |
$dir = __DIR__; |
{ | |
"blocks":{ | |
"sales_order_grid":110, | |
"sales_order_view":67, | |
"html_head":55, | |
"comment":51, | |
"catalog_product_grid":38, | |
"product_view":34, | |
"onepage":32, | |
"onepage_payment_methods":30, |