Skip to content

Instantly share code, notes, and snippets.

;; git-tools.el --- Some handy git-related commands
;; Copyright 2009 Eric Kidd
;; Author: Eric Kidd <http://www.randomhacks.net/>
;; Keywords: git
;; This file is free software; you can redistribute it and/or modify
;; it under the terms of the GNU General Public License as published by
;; the Free Software Foundation; either version 2, or (at your option)
;; any later version.
# Move all origin/* refs to the top level and remove the remote.
# Basic idea by Johannes Schindelin, some tweaks by me.
git_make_origin_refs_local() {
git for-each-ref refs/remotes/origin/ > .git/origin-refs &&
while read sha1 type ref; do
test "$ref" != refs/remotes/origin/HEAD || continue
git update-ref "refs/heads/${ref#refs/remotes/origin/}" "$ref"
done < .git/origin-refs &&
rm .git/origin-refs &&
git remote rm origin
# -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:ft=tcl:et:sw=4:ts=4:sts=4
# $Id$
PortSystem 1.0
name log4cplus
version 1.0.3-rc9
categories devel
maintainers randomhacks.net:macports
description Logging library for C++
;; Insert somewhere in test/scripts/features.ss to test.
(card /features/http (%standard-test-card% :title "HTTP")
(edit-box result
((inset-rect $screen-rect 50)
""
:multiline? #t
:font-size 12))
(run
(with-values [[tcp-in tcp-out]
(tcp-connect "iml.dartmouth.edu" 80)]
title: My big essay
comments: enabled
This is my big essay.
<!--more-->
This is the rest.
# Demonstration script for http://github.com/emk/blogitr
require 'rubygems'
require 'sinatra'
require 'blogitr'
$blog = Blogitr::Blog.new(File.dirname(__FILE__))
helpers do
def article_url article
dir = article.date_time.strftime("/%Y/%m/%d")
@emk
emk / link_to.rb
Created April 20, 2009 01:21
A link_to helper method for Sinatra
@emk
emk / compass-example.html
Created April 22, 2009 16:40
Compass and Sass make CSS easier
<html>
<head>
<title>My blog</title>
</head>
<body>
<div class='container'>
<div class='header'>
<h1>My blog</h1>
</div>
<div class='content'>
@emk
emk / form_steps.rb
Created April 29, 2009 23:08
Fill in multiline forms with Cucumber and Webrat
# Fill in multiple form fields using a table. Use it as follows:
#
# When I fill in the fields
# | Field 1 | Value 1 |
# | Field 2 | Value 2 |
When /^I fill in the fields$/ do |table|
table.rows_hash.each {|field, value| fill_in field, :with => value }
end
diff --git a/src/stc/scintilla/src/LexLisp.cxx b/src/stc/scintilla/src/LexLisp.cxx
index 1072e13..8784e38 100644
--- a/src/stc/scintilla/src/LexLisp.cxx
+++ b/src/stc/scintilla/src/LexLisp.cxx
@@ -100,6 +100,9 @@ static void ColouriseLispDoc(unsigned int startPos, int length, int initStyle, W
styler.ColourTo(i - 1, state);
radix = -1;
state = SCE_LISP_MACRO_DISPATCH;
+ } else if (ch == ':' && isLispwordstart(chNext)) {
+ styler.ColourTo(i - 1, state);