This file contains 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/php | |
<?php | |
// base64encode.php by M.Hotta | |
// a filter to conver the result of ldapsearch command | |
// | |
function output($attr, $value, $encoded) { | |
if ($encoded) { | |
print $attr . ':: ' . base64_decode($value) . "\n"; | |
} else { | |
print $attr . ':' . $value . "\n"; |
This file contains 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/php | |
<?php | |
if ($argc == 1) { | |
printf("Retrieve JSON data from specified URl and then decode.\n"); | |
printf("Usage: %s URL_that_returns_JSON\n", $argv[0]); | |
exit(0); | |
} | |
$a = file_get_contents($argv[1]); | |
$a = preg_replace('/^[\r\n\(]*/', '', $a); | |
$a = preg_replace('/\)$/', '', $a); |
This file contains 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
/********************************************************************************* | |
* Mailman からのリスト移行サンプル using Google Apps Script | |
* 2015.09.07 M.Hotta | |
* | |
* Mailman における情報取得方法 | |
* リスト一覧の取得 mailman:/usr/lib/mailman/bin$ sudo ./list_lists | nkf -w | |
* (文字化けする場合は管理画面から取得) | |
* 購読者一覧の取得 mailman:/usr/lib/mailman/bin$ sudo ./list_members リスト名 | |
* 管理者一覧の取得 mailman:/usr/lib/mailman/bin$ sudo ./list_owners リスト名 | |
* |
This file contains 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
<!-- /var/www/http503/custom_503.html --> | |
<html> | |
<body> | |
<h1>custom_503.html</h1> | |
<img src='images/job_it_dokata.png' alt='IT Dokata'> | |
</body> | |
</html> |
This file contains 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/php | |
<?php | |
//--------------------------------------------------------------------- | |
// Display data encoded as UTF-8 strings | |
// | |
// Usage: tail -f log-files-etc | cvtlog.php | |
//--------------------------------------------------------------------- | |
function pack_func($matches) // $matches[] = array('\xXX', '\xXX'); | |
{ | |
$tmp = sscanf('0' . substr($matches[0], 1), "%x"); |
This file contains 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/bash | |
cat $1 | \ | |
nkf -Sw -Lu -Z4 -X | \ | |
sed -e '1,5d' | \ | |
head -n -2 | \ | |
sed -e 's/","/\t/g' | |
-e 's/"//g' \ | |
-e 's/フリカエ/振替/g' \ | |
-e 's/コクミンネンキン/国民年金/g' \ | |
-e 's/ホケンリヨウ/保険料/g' \ |
This file contains 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
// Gradle QuickStart - 7.2. 基本的なJavaプロジェクト | |
// cf. http://gradle.monochromeroad.com/docs/userguide/userguide.html | |
// Gradle が使用する JRE | |
// システムの JDK/JRE。デフォルト以外の JDK を使用したい場合は | |
// JAVA_HOME 環境変数を調整する。 | |
// Gradle が使用する Groovy | |
// Gradle 同梱の Groovy。システムの Groovy は参照されない。 |
This file contains 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
# -*- mode: ruby -*- | |
# vi: set ft=ruby : | |
Vagrant.configure("2") do |config| | |
config.vm.box = "centos/7" | |
config.vm.network "private_network", ip: "192.168.56.13" | |
config.vm.network "private_network", ip: "172.16.32.4" | |
config.vm.network "private_network", ip: "172.16.0.7" | |
config.vm.hostname = "db2" | |
config.vm.synced_folder ".", "/vagrant", disabled: true |
This file contains 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/bash | |
MAILTO=mhotta@example.com | |
_INITDIR=~/.pgpool-check/init/ | |
_CHECKDIR=~/.pgpool-check/current/ | |
function _die { | |
echo $1 | |
exit 1 | |
} |
OlderNewer