This file contains hidden or 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
import Control.Concurrent | |
import Control.Monad | |
import Reactive.Banana | |
import System.IO | |
timer sec = do | |
(addHandler, runHandlers) <- liftIO newAddHandler | |
liftIO $ forkIO $ forever $ threadDelay (sec * 10 ^ 6) >> liftIO (runHandlers ()) | |
fromAddHandler addHandler |
This file contains hidden or 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
diff --git a/System/Glib/UTFString.hs b/System/Glib/UTFString.hs | |
index de54d16..1758414 100644 | |
--- a/System/Glib/UTFString.hs | |
+++ b/System/Glib/UTFString.hs | |
@@ -1,3 +1,4 @@ | |
+{-# LANGUAGE CPP #-} | |
-- GIMP Toolkit (GTK) UTF aware string marshalling | |
-- | |
-- Author : Axel Simon | |
@@ -55,46 +56,78 @@ import System.Glib.FFI |
This file contains hidden or 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/sh | |
function main | |
{ | |
local dest=. | |
while getopts 'd:' OPT | |
do | |
case $OPT in | |
'd') dest="$OPTARG" ;; |
This file contains hidden or 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 gosh | |
; Version: 0.00 | |
; Copyright (C) 2011 emonkak <[email protected]> | |
; License: MIT license {{{ | |
; Permission is hereby granted, free of charge, to any person obtaining | |
; a copy of this software and associated documentation files (the | |
; "Software"), to deal in the Software without restriction, including | |
; without limitation the rights to use, copy, modify, merge, publish, | |
; distribute, sublicense, and/or sell copies of the Software, and to | |
; permit persons to whom the Software is furnished to do so, subject to |
This file contains hidden or 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/perl | |
use strict; | |
use warnings; | |
use File::Path; | |
use LWP::UserAgent; | |
use HTTP::Request; | |
use HTTP::Headers; | |
my $LOGDIR = "$ENV{'HOME'}/.jd"; |
This file contains hidden or 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/ruby | |
require 'optparse' | |
require 'pathname' | |
require 'yaml/store' | |
require 'yaml_waml' | |
DATABASE = ENV['HOME'] + '/Documents/dvd-database.yml' | |
def get_entries(path) |
This file contains hidden or 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
0x20 0x0020 # SPACE | |
0x21 0x0021 # EXCLAMATION MARK | |
0x22 0x0022 # QUOTATION MARK | |
0x23 0x0023 # NUMBER SIGN | |
0x24 0x0024 # DOLLAR SIGN | |
0x25 0x0025 # PERCENT SIGN | |
0x26 0x0026 # AMPERSAND | |
0x27 0x0027 # APOSTROPHE | |
0x28 0x0028 # LEFT PARENTHESIS | |
0x29 0x0029 # RIGHT PARENTHESIS |
This file contains hidden or 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
{ +filter{sweetnote-board-filter} } | |
www.sweetnote.com/board | |
{ +filter{sweetnote-site-filter} } | |
www.sweetnote.com/site |
This file contains hidden or 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
// ==UserScript== | |
// @name ldr-reload-image-without-referer | |
// @include http://reader.livedoor.com/reader/ | |
// @include http://fastladder.com/reader/ | |
// ==/UserScript== | |
(function() { | |
function initPool() { | |
var origin = location.protocol + '//' + location.host; | |
var html = document.implementation.createHTMLDocument(''); |
This file contains hidden or 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
for file in split(glob('index-*.html'), '\n') | |
let _ = [] | |
for line in readfile(file) | |
let str = matchstr(line, '^<dt><span class="strong"><a\s.\{-}>\zs[A-Za-z0-9._]\+') | |
if str != '' | |
call add(_, str) | |
endif | |
endfor | |
call writefile(_, file . '.tmp') | |
endfor |