Skip to content

Instantly share code, notes, and snippets.

const Name = 'shorten-url',
Shorteners = [{
text: 'tinyurl.com',
data: function(lu, cb)({
url: 'http://tinyurl.com/api-create.php',
type: 'post',
data: {url: lu},
success: cb,
}),
logo: <h1 style={(
@Yasushi
Yasushi / kwartz_handler.rb
Created June 14, 2009 10:52
Kwartz template handler for Rails 2.3
require 'kwartz'
require 'kwartz/binding/rails'
class KwartzHandler < ActionView::TemplateHandler
include ActionView::TemplateHandlers::Compilable
def compile(template)
load_path = template.load_path
plogic_path = template.plogic_path
pdata_path = template.pdata_path
plogic_filename = template.plogic_filename
/**
* Favotter Viewer.
* Respect
* http://jsgt.org/mt/01/
* http://d.hatena.ne.jp/murky-satyr/
*
* TODO:HTTP 503のときに起こってる悲しい事態を何とかする。
*/
+function($j, urls){
CmdUtils.CreateCommand({
--- mixi-gnus.el.orig 2009-07-03 12:06:55.241538802 +0900
+++ mixi-gnus.el 2009-07-03 12:03:56.417466727 +0900
@@ -59,9 +59,9 @@
;; Avoid matching with message-mail-p.
(with-current-buffer mailbuf
(goto-char (point-min))
- (unless (search-forward "\nMixi-To: " nil t)
- (when (search-forward "\nTo: " nil t)
- (replace-match "\nMixi-To: "))))
+ (unless (re-search-forward "^Mixi-To: " nil t)
;;; toggle-scala.el --- Toggle between test and implementation files.
;; Author: MIZUNO Hiroki<mzp.ppp_at_gmail.com>
;; Keywords: tools
;;; Usage:
;; Insert into your .emacs file the following line, (and eval it for
;; immediate usage:
;;
;; (require 'toggle-scala)
CmdUtils.makeSearchCommand({
name: "goodic",
url: "http://dictionary.goo.ne.jp/srch/all/{QUERY}/m0u/",
parser: {
title: "li.entry",
preview: "li.meanings",
maxResults: 10,
},
});
package bootstrap.liftweb
import net.liftweb.http.{Req, LiftRules}
class LiftFilter extends net.liftweb.http.LiftFilter {
override def isLiftRequest_?(session: Req): Boolean = {
!session.request.getRequestURI.startsWith("/_ah/") && super.isLiftRequest_?(session)
}
}
#! /bin/sh /usr/share/dpatch/dpatch-run
## 19_rdpc101.dpatch by <yasushi.abe@gmail.com>
##
## All lines beginning with `## DP:' are a description of the patch.
## DP: No description.
@DPATCH@
diff -urNad xawtv-3.95.dfsg.1~/console/radio.c xawtv-3.95.dfsg.1/console/radio.c
--- xawtv-3.95.dfsg.1~/console/radio.c 2009-08-17 20:46:28.000000000 +0900
+++ xawtv-3.95.dfsg.1/console/radio.c 2009-08-17 20:51:25.618334265 +0900
const Aliases = {
t: {
help: 'title',
get text() info().title,
},
u: {
help: 'URL',
get text() info().url,
},
a: {
// Sketch of an immutable domain model in Scala
// We used this scheme together with this JPA module:
// http://github.com/jboner/skalman/blob/d1e03a85be3964b9012f9e79dd726b0546342b2b/core/src/main/scala/JPA.scala
// ...and this GenericRepository:
// http://github.com/jboner/skalman/blob/d1e03a85be3964b9012f9e79dd726b0546342b2b/core/src/main/scala/GenericRepository.scala
abstract class Entity[T](val id: Int)
object User {