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
package { | |
import flare.scale.ScaleType; | |
import flare.util.Shapes; | |
import flare.vis.Visualization; | |
import flare.vis.data.Data; | |
import flare.vis.data.DataSprite; | |
import flare.vis.operator.OperatorList; | |
import flare.vis.operator.encoder.ColorEncoder; | |
import flare.vis.operator.encoder.PropertyEncoder; | |
import flare.vis.operator.layout.AxisLayout; |
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
package | |
{ | |
import flare.scale.ScaleType; | |
import flare.util.palette.Palette; | |
import flare.util.palette.SizePalette; | |
import flare.vis.data.Data; | |
import flare.vis.operator.encoder.Encoder; | |
/** | |
* Encodes a data field into size values, using a scale transform and a |
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
alias ls="ls -FG" | |
# Change the window title of X terminals | |
case $TERM in | |
xterm*|rxvt|Eterm|eterm) | |
PROMPT_COMMAND='echo -ne "\033]0;${USER}@${HOSTNAME%%.*}:${PWD/$HOME/~}\007"' | |
;; | |
screen) | |
PROMPT_COMMAND='echo -ne "\033_${USER}@${HOSTNAME%%.*}:${PWD/$HOME/~}\033\\"' | |
;; |
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
#!/bin/bash | |
tmsupportpath="/Library/Application Support/TextMate" | |
bundlepath="$tmsupportpath/Bundles" | |
if [ ! -d "$bundlepath" ] | |
then | |
echo "First time, eh? Making $bundlepath..." | |
mkdir -p "$bundlepath" | |
fi | |
if [ ! -d "$tmsupportpath/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
class NotificationWorker < Workling::Base | |
def deliver_notification(options) | |
if options[:comment_id] | |
comment = Comment.find_by_id(options[:comment_id]) | |
Emailer.deliver_comment_notification(comment) | |
elsif options[:identification_id] | |
identification = Identification.find_by_id(options[:identification_id]) | |
Emailer.deliver_identification_notification(identification) | |
end | |
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
# By Henrik Nyh <http://henrik.nyh.se> 2008-01-30. | |
# Free to modify and redistribute with credit. | |
# modified by Dave Nolan <http://textgoeshere.org.uk> 2008-02-06 | |
# Ellipsis appended to text of last HTML node | |
# Ellipsis inserted after final word break | |
# modified by Mark Dickson <mark@sitesteaders.com> 2008-12-18 | |
# Option to truncate to last full word | |
# Option to include a 'more' link |
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
scope = YourModel.scoped({}) | |
scope = scope.some_named_scope() | |
puts scope.full_proxied_options[:joins] |
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 syncPhoto(photo, options) { | |
var options = options || {}; | |
var credentials = Ti.App.Properties.getString('currentUserCredentials'); | |
var observation = photo.getObservation(); | |
var f = photo.getFile(); | |
var xhr = Titanium.Network.createHTTPClient({ | |
onerror: function(e) { | |
Ti.API.info("ERROR " + e.error); | |
if (e.error.match(/timed out/)) { |
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
{ scopeName = 'text.plain'; | |
foldingStartMarker = '/\*\*|\{\s*$'; | |
foldingStopMarker = '\*\*/|^\s*\}'; | |
patterns = ( | |
{ name = 'markup.bold'; | |
match = '^\s*(\*\s.*)$\n?'; | |
}, | |
{ name = 'comment'; | |
match = '^\s*(x\s.*)$\n?'; | |
}, |
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
/* | |
d3.phylogram.js | |
Wrapper around a d3-based phylogram (tree where branch lengths are scaled) | |
Also includes a radial dendrogram visualization (branch lengths not scaled) | |
along with some helper methods for building angled-branch trees. | |
Copyright (c) 2013, Ken-ichi Ueda | |
All rights reserved. |
OlderNewer