Skip to content

Instantly share code, notes, and snippets.

View zmack's full-sized avatar
👓
Bungles

Andrei Bocan zmack

👓
Bungles
View GitHub Profile
[zmack@cartofior randomista (master)]$ gco -b foo
Switched to a new branch 'foo'
[zmack@cartofior randomista (foo)]$ gst
# On branch foo
nothing to commit (working directory clean)
[zmack@cartofior randomista (foo)]$ echo "moloz" > foo
[zmack@cartofior randomista (foo)]$ gst
# On branch foo
# Untracked files:
# (use "git add <file>..." to include in what will be committed)
function relative_time(C) {
var A = Date.parse(C);
var D = (arguments.length > 1) ? arguments[1] : new Date;
var E = parseInt((D.getTime() - A) / 1000);
//E = E + D.getTimezoneOffset() * 60;
if (E < 60) {
return "less than a minute ago";
} else {
if (E < 120) {
return "about a minute ago";
77926866331
[zmack@voltron symbolya (master)]$ git branch -a
error: refs/remotes/braid/vendor/plugins/thinking-sphinx/HEAD points nowhere!
error: refs/remotes/braid/vendor/plugins/haml/HEAD points nowhere!
error: refs/remotes/braid/vendor/plugins/will-paginate/HEAD points nowhere!
error: refs/remotes/braid/thinking-sphinx/HEAD points nowhere!
* master
nobraid
braid/vendor/plugins/HEAD
braid/vendor/plugins/master
origin/HEAD
#!/bin/sh
KEY="$HOME/.ssh/id_dsa.pub"
if [ ! -f $KEY ];then
echo "private key not found at $KEY"
echo "please create it with \"ssh-keygen -t dsa\""
exit
fi
<?xml version="1.0"?>
<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
<!-- /etc/fonts/local.conf file to configure system font access -->
<fontconfig>
<!-- Use the Autohinter -->
<match target="font">
<edit name="autohint" mode="assign"><bool>true</bool></edit>
</match>
$('li span.content').each( function(index,element) { z = element.innerHTML.match(/http:\/\/([^/]+)[^ ]+/); if ( z!= null) { console.log(element.innerHTML); element.innerHTML = element.innerHTML.replace(z[0], '<a href="'+z[0]+'">'+z[1]+'</a>') } })
,previewCenter: function() {
var tile = this.getMostPopulatedTile();
if ( tile == null ) {
return { span: null, coords: null, params: null }
}
var map_projection = this.gmap.getCurrentMapType().getProjection();
var x = tile.x * 256 + 128;
1. document=2, weight=3, created_at=Sat Nov 8 17:52:15 2008, id=1, sphinx_internal_id=1, class_crc=3557893116, subclass_crcs=(680131769,3557893116), sphinx_deleted=0
id=1
title=a moo
description=a moo in the wild
tags=moo, wild, nature
owner_id=2
active=1
image_file_name=184x180.jpg
image_content_type=image/png
image_file_size=50316
ParseTree (3.0.1, 2.2.0, 2.1.1)
RedCloth (4.1.0, 4.0.4, 4.0.3, 3.0.4)
RubyInline (3.8.1, 3.7.0, 3.6.7, 3.6.6)
ZenTest (3.11.0, 3.10.0, 3.9.2, 3.9.1)
abstract (1.0.0)
actionmailer (2.1.2, 2.1.1, 2.1.0, 2.0.2)
actionpack (2.1.2, 2.1.1, 2.1.0, 2.0.2)
activerecord (2.1.2, 2.1.1, 2.1.0, 2.0.2)
activeresource (2.1.2, 2.1.1, 2.1.0, 2.0.2)
activesupport (2.1.2, 2.1.1, 2.1.0, 2.0.2)