Skip to content

Instantly share code, notes, and snippets.

Avatar
💭
> 突然の死 <

SATOH Fumiyasu (TSUCHIDA Fumiyasu) fumiyas

💭
> 突然の死 <
View GitHub Profile
@fumiyas
fumiyas / interlace.bash
Created Jul 16, 2011
UPS友の会: シェルスクリプト大喜利第二回: 第2問: interlace コマンド
View interlace.bash
#!/bin/bash
#!/bin/ksh でも可 (ただし制限あり)
##
## UPS友の会: シェルスクリプト大喜利第二回
##
## [第2問] 本誌6ページに出てきたinterlaceコマンドをシェルスクリプトで
## 書いてください。8つのストリームを重畳する専用で構いません。
## ======================================================================
## これはそこそこ歯ごたえあるお題だと思います。投稿したら段位をたくさん進
## 呈する可能性が高いです、たぶん。(歯ごたえあると思いますので、全然解答が
@fumiyas
fumiyas / ups-mail2csv.ksh
Created Jul 16, 2011
UPS友の会: シェルスクリプト大喜利第二回: 第3問: 会員登録メール内の会員情報を CSV 登録
View ups-mail2csv.ksh
#!/bin/ksh
#!/bin/zsh でも可
##
## [第3問] USP友の会に会員登録すると事務局に次のメールが自動送信されるそう
## です(先頭の"> "は付きません)。これをname, email,place,howの順
## 番で/home/usp/members.csvにCSVで追記出力する1行野郎スクリプトを
## 作ってください。なるべく短い記述で!
##
## > タイトル:USP友の会ご入会ありがとうございます。
## > 本文:
@fumiyas
fumiyas / vfs_sharemodes_aix.c
Created Sep 15, 2011
Samba VFS module to map Windows share modes to AIX open(2) flags (work in progress)
View vfs_sharemodes_aix.c
/*
* Samba VFS module to map Windows share modes to AIX open(2) flags
*
* Copyright (C) SATOH Fumiyasu @ OSS Technology, Inc., Japan, 2011
*
* This program 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 of the License, or
* (at your option) any later version.
*
@fumiyas
fumiyas / fix-jis-shorttail.pl
Created Sep 30, 2011
JIS 長音省略表記を修正するスクリプト (UTF-8 限定)
View fix-jis-shorttail.pl
#!/usr/bin/perl -pi.orig
##
## JIS 長音省略表記を修正するスクリプト (UTF-8 限定)
##
## Author: さとうふみやす
## URL: https://gist.github.com/1254298
## Copying: GNU GPLv3
## Usage:
## find /targetdir -type f -name "*.html" -exec perl fix-jis-shorttail.pl {} +
##
@fumiyas
fumiyas / solaris-11.0-x86-pkg-list.txt
Created Nov 10, 2011
Solaris 11.0 x86 `pkg list`
View solaris-11.0-x86-pkg-list.txt
NAME (PUBLISHER) VERSION IFO
archiver/gnu-tar 1.26-0.175.0.0.0.2.537 i--
compress/bzip2 1.0.6-0.175.0.0.0.2.537 i--
compress/gzip 1.3.5-0.175.0.0.0.2.537 i--
compress/p7zip 9.20.1-0.175.0.0.0.2.537 i--
compress/unzip 6.0-0.175.0.0.0.2.537 i--
compress/zip 3.0-0.175.0.0.0.2.537 i--
consolidation/SunVTS/SunVTS-incorporation 0.5.11-0.172.0.0.0.0.0 i--
consolidation/X/X-incorporation 0.5.11-0.175.0.0.0.0.1215 i--
consolidation/admin/admin-incorporation 0.5.11-0.175.0.0.0.2.0 i--
@fumiyas
fumiyas / named.conf
Created Dec 9, 2011
Initial "options" clause in /etc/named.conf from CentOS 4
View named.conf
options {
directory "/var/named";
dump-file "/var/named/data/cache_dump.db";
statistics-file "/var/named/data/named_stats.txt";
/*
* If there is a firewall between you and nameservers you want
* to talk to, you might need to uncomment the query-source
* directive below. Previous versions of BIND always asked
* questions using port 53, but BIND 8.1 uses an unprivileged
* port by default.
@fumiyas
fumiyas / named.caching-nameserver.conf
Created Dec 9, 2011
Initial "options" clause in /etc/named.caching-nameserver.conf from CentOS 5
View named.caching-nameserver.conf
options {
listen-on port 53 { 127.0.0.1; };
listen-on-v6 port 53 { ::1; };
directory "/var/named";
dump-file "/var/named/data/cache_dump.db";
statistics-file "/var/named/data/named_stats.txt";
memstatistics-file "/var/named/data/named_mem_stats.txt";
// Those options should be used carefully because they disable port
// randomization
@fumiyas
fumiyas / dhcpd-isc2solaris.ksh
Created Jan 23, 2012
Convert ISC DHCP dhcpd.conf into Solaris in.dhcpd(1M) command-lines
View dhcpd-isc2solaris.ksh
#!/bin/ksh
##
## Convert ISC DHCP dhcpd.conf into Solaris in.dhcpd(1M)
## Copyright (c) 2011 SATOH Fumiyasu @ OSS Technology, Inc.
##
## License: GNU General Public License version 3 or later
## Date: 2011-12-01, since 2011-12-01
##
## See also:
## dhcpconfig(1M), dhtadm(1M), pntadm(1M), dhcp_inittab(4),
@fumiyas
fumiyas / rsync-3.0.9-iconv-nkf-hack.patch
Created Feb 29, 2012
rsync: [PATCH] NKF (Network Kanji Filter) support for --iconv option
View rsync-3.0.9-iconv-nkf-hack.patch
From 1cffdb3dab34c2fc1115a4417464afa8bc56ff37 Mon Sep 17 00:00:00 2001
From: SATOH Fumiyasu <fumiyas@osstech.co.jp>
Date: Sat, 25 Feb 2012 03:29:09 +0900
Subject: [PATCH] NKF (Network Kanji Filter) support for --iconv option
---
Makefile.in | 2 +-
nkf/config.h | 51 +
nkf/nkf.c | 6717 +++++++++++++++++++++++++++++++++++++++++++
nkf/nkf.h | 181 ++
@fumiyas
fumiyas / cyrus-sasl-2.1.25-static-plugin.patch
Created May 1, 2012
Cyrus SASL 2.1.25 configure --enable-staticplugin patch
View cyrus-sasl-2.1.25-static-plugin.patch
Based on the following articles:
http://developer.cybozu.co.jp/oss/2010/01/build-with-stat.html
http://lists.andrew.cmu.edu/pipermail/cyrus-sasl/2009-December/001929.html
diff -upr cyrus-sasl-2.1.25/config/plain.m4 cyrus-sasl-2.1.25-static-plugin/config/plain.m4
--- cyrus-sasl-2.1.25/config/plain.m4 2009-12-04 04:07:01.000000000 +0900
+++ cyrus-sasl-2.1.25-static-plugin/config/plain.m4 2012-03-15 16:42:47.141186907 +0900
@@ -21,7 +21,7 @@ dnl PLAIN
if test "$plain" != no; then
AC_MSG_RESULT(enabled)