Skip to content

Instantly share code, notes, and snippets.

Avatar

Jun Morimoto mrmt

View GitHub Profile
View wordle.pl
#!/usr/bin/env perl
# start with ARISE or ARIES
use strict;
use warnings;
use feature 'say';
my @dict;
{
open DICT, '<', '/usr/share/dict/words' || die;
View wiliki-trampoline-patch.diff
diff -urN lib-/wiliki/format.scm lib/wiliki/format.scm
--- lib-/wiliki/format.scm 2004-09-09 00:42:14.000000000 +0900
+++ lib/wiliki/format.scm 2004-09-09 00:33:01.000000000 +0900
@@ -226,14 +226,16 @@
(path (match 4))
(openp (match 1))
(name (match 8))
+ (wlki (wiliki))
+ (trampoline #`",(cgi-name-of wlki)?c=j&url=")
(url (if server #`",|scheme|:,|server|,|path|" path)))
@mrmt
mrmt / gist:1464ac88fe4dd0b61fef52872a727899
Last active Jun 17, 2020 — forked from t-yamamoto-mercury-inc/gist:b58969dcc58bb13ee4b7e2c1fc316501
Googleドライブのパスをクリップボードにコピーするブックマークレット
View gist:1464ac88fe4dd0b61fef52872a727899
javascript:(function(){
var pre = 'Googleドライブの「';
var xpath = '//*[@guidedhelpid="folder_path"]';
document.getElementsByXPath = function(expression, parentElement) {
var r = [];
var x = document.evaluate(expression, parentElement || document, null, XPathResult.ORDERED_NODE_SNAPSHOT_TYPE, null);
for (var i = 0, l = x.snapshotLength; i < l; i++) {
r.push(x.snapshotItem(i));
} return r;
@mrmt
mrmt / gist:1523121
Created Dec 27, 2011
/etc/postfix/helo_checks
View gist:1523121
# $Id: helo_checks,v 1.1 2008-07-26 04:09:08 morimoto Exp $
# $Source: /var/cvs/postfix-conf/helo_checks,v $
DH.vicp.net REJECT
MY-TOMATO.vicp.net REJECT
arkmx0.rmail.ne.jp REJECT
changqing10.vicp.net REJECT
compuserve.com REJECT
dianxin1.vicp.net REJECT
dianxin_05.vicp.net REJECT
dragon01.vicp.net REJECT
@mrmt
mrmt / insert-japanese-day-of-the-week.el
Last active Mar 25, 2020
insert japanese day of the week
View insert-japanese-day-of-the-week.el
;; Copyright 2019 Jun Morimoto
;; 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 3, or (at your option)
;; any later version.
;; This file is distributed in the hope that it will be useful,
;; but WITHOUT ANY WARRANTY; without even the implied warranty of
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
@mrmt
mrmt / omnioutliner-opml2html
Created Nov 19, 2011
convert opml (generated via OmniOutliner) to html
View omnioutliner-opml2html
#!/usr/bin/perl -w
#
# omnioutliner-opml2html
# morimoto@xantia.citroen.org
# $Id: omnioutliner-opml2html,v 1.1 2004/02/04 12:39:38 morimoto Exp $
# Based on opml2html.pl, shown below;
#
# opml2html.pl, (c) Jeremy Zawodny -- http://jerermy.zawodny.com/blog/
#
# Updated by Michael Radwin (http://www.radwin.org/michael/blog/)
View gist:b09f93ca113abd9195f4a09c8a1d14bc
% IANA WHOIS server
% for more information on IANA, visit http://www.iana.org
% This query returned 1 object
refer: whois.pir.org
domain: ORG
organisation: Public Interest Registry (PIR)
address: 1775 Wiehle Avenue
@mrmt
mrmt / KeySetting_Default.plist
Last active Feb 2, 2018
Yosemite:/System/Library/Input Methods/JapaneseIM.app/Contents/Resources/KeySetting_Default.plist
View KeySetting_Default.plist
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>version</key>
<integer>1</integer>
<key>keys</key>
<dict>
<key>before_typing</key>
<dict>
View criminal_jc.uml
participant "誤認逮捕された専門学校生" as Senmon
participant "犯罪中学生" as Criminal
participant "女子高生ら2人" as JK_2
participant "チケット販売サイト" as TicketShop
participant "落札者" as Rakusatsu
Senmon -> Criminal : チケット8万円で売ります
Criminal -> Senmon : 買います
Senmon -> Criminal : 「誤認逮捕された専門学校生」の口座を教える
Criminal -> JK_2 : チケット4万円で売ります
View slack2html.php
<?
/////////////////////
// slack2html
// by @levelsio
/////////////////////
//
/////////////////////
// WHAT DOES THIS DO?
/////////////////////
//