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
module.directive('tooltipGroup', [ | |
var popoverRegistry = {}; | |
var suspend = false; // semaphore used to prevent circular calling of hide triggers | |
function(){ | |
return { | |
restrict : 'A', | |
priority : 1, | |
link : { | |
pre : function ($scope, el, attrs, formCtrl) { | |
// $scope.artifactPickerSelectOptions = artifactPicker.getSelectOptions(); |
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 | |
/** | |
* twig.php | |
* | |
* Command-line script to process YAML frontmatter with Twig templates. | |
* Inspired by Mustache <http://github.com/defunkt/mustache>. | |
* | |
* Example template file (test.html): | |
* --- | |
* people: [ {name: scott}, {name: laura} ] |
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
wget http://dag.wieers.com/rpm/packages/rpmforge-release/rpmforge-release-0.3.6-1.el5.rf.i386.rpm | |
rpm --install rpmforge-release-0.3.6-1.el5.rf.i386.rpm | |
yum install --enablerepo=rpmforge memcached | |
memcached -d -m 512 -l 127.0.0.1 -p 11211 -u nobody | |
wget http://pecl.php.net/get/memcache-2.2.5.tgz | |
tar -xvf memcache-2.2.5.tgz | |
cd memcache-2.2.5 | |
phpize && ./configure --enable-memcache && make | |
cp /root/memcache-2.2.5/modules/memcache.so /usr/lib/php/modules/ | |
echo extension=memcache.so >> /etc/php.ini |
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
(function($){ | |
$.fn.redraw = function(){ | |
return $(this).each(function(){ | |
var n = document.createTextNode(' '); | |
$(this).append(n); | |
setTimeout(function(){n.parentNode.removeChild(n)}, 0); | |
}); | |
} | |
})(jQuery) |
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
<html xmlns:o="urn:schemas-microsoft-com:office:office" | |
xmlns:x="urn:schemas-microsoft-com:office:excel" | |
xmlns="http://www.w3.org/TR/REC-html40"> | |
<head> | |
<meta http-equiv="expires" content="Mon, 06 Jan 1999 00:00:01 GMT"> | |
<meta http-equiv=Content-Type content="text/html; charset=UTF-8"> | |
<!--[if gte mso 9]><xml> | |
<x:ExcelWorkbook> | |
<x:ExcelWorksheets> | |
<x:ExcelWorksheet> |
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
--- | |
layout: post | |
title: This is my post title | |
--- | |
{% block content %} | |
# {{title}} | |
This is the long version of my content. Blah blah blah. |
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
class SecurityState(): | |
"""An example class to track persistent state for a | |
specific security. This trivial example just tracks the max | |
price for the security, as well as shares ordered. | |
Modify this class to track individual securities.""" | |
def __init__(self, tick): | |
self.sid = tick.sid | |
self.max_price = tick.price |
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/bin/env bash | |
set -e | |
if [ "$1" = "-h" ] || [ "$1" = "--help" ] ; then | |
echo "usage: git sync [remote-name]" | |
echo | |
echo "Sync's the current repository to another remote host, using git," | |
echo "but not using this repository." | |
echo |
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 | |
/** | |
* Extends Twig with | |
* {{ "my string, whatever" | pre }} --> wraps with <pre> | |
* {{ myBigVar | yaml_dump | pre }} as {{ myBigVar | ydump }} or {{ myBigVar | dumpy }} | |
* {{ myBigVar | var_dump | pre }} as {{ myBigVar | dump }} | |
* | |
* You may control the depth of recursion with a parameter, say foo = array('a'=>array('b'=>array('c','d'))) | |
* |
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 'rubygems' | |
require 'bundler/setup' | |
require 'time' | |
require 'date' | |
require 'twitter' | |
require 'fb_graph' | |
require 'pp' | |
require 'json' | |
OlderNewer