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
<?php | |
$urls=<<<EOF | |
https://tleague.jp/match/?season=2018&month=201810 | |
https://tleague.jp/match/?season=2018&month=201811 | |
https://tleague.jp/match/?season=2018&month=201812 | |
https://tleague.jp/match/?season=2018&month=201901 | |
https://tleague.jp/match/?season=2018&month=201902 | |
https://tleague.jp/match/?season=2018&month=201903 | |
https://tleague.jp/match/?season=2019&month=201910 | |
https://tleague.jp/match/?season=2019&month=201911 |
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
<?php | |
$lines = file('mail.log'); | |
$logs = []; | |
$mails = []; | |
foreach ($lines as $k => $line){ | |
$line = trim($line); | |
$cell = explode(" ", $line); | |
$status = $to = $from = ''; | |
$size = 0; |
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
ARCHIVE_INFO_FILE=archive_info.txt | |
DELETE_FILES_INFO=deleted_files.txt | |
T_TIME=`date "+%Y%m%d_%H%M%S"` | |
T_DAY=`date "+%Y%m%d"` | |
# $1に新しい方、$2に古い方のハッシュ | |
if [ $# -ne 2 ]; then | |
echo "引数が不正です。コミットは2つ指定してください。" >&2 | |
exit 1 | |
fi |
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
const fs = require('fs'); | |
const path = require('path'); | |
const glob = require('glob'); | |
const slash = require('slash'); | |
var minimist = require("minimist"); | |
var nowString = ()=> { | |
var d = new Date(), | |
month = '' + (d.getMonth() + 1), | |
day = '' + d.getDate(), |
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
AJS.$((function($){ | |
return function(){ | |
// 添付ファイルのコメント欄を偽装する comment = "url|+|http://www.example.com<:>title|+|about this url" | |
var attachCommentDelimiter = '<:>'; | |
var propertyDelimiter = '|+|'; | |
var extraAttachComments = { | |
title: '使用論文名', | |
comment: 'コメント', | |
url: '論文URL' | |
}; |
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
<?php | |
use \FeedWriter\ATOM ; | |
date_default_timezone_set( "Asia/Tokyo" ) ; | |
require_once dirname(__FILE__)."/FeedWriter/Item.php" ; | |
require_once dirname(__FILE__)."/FeedWriter/Feed.php" ; | |
require_once dirname(__FILE__)."/FeedWriter/ATOM.php" ; | |
class AtlasFeed |
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
<?php | |
function pathinfo($f) | |
{ | |
$ret = pathinfo($f); | |
if (!isset($ret['filename'])){ | |
$filename = substr($f, strrpos($f, '/') + 1); | |
$filename = substr($filename, 0, strrpos($filename, '.'.$ret['extension'])); | |
$ret['filename'] = $filename; | |
} |
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
<?php | |
function array_merge_recursive(&$origin, $extend) | |
{ | |
foreach ($extend as $e_key=>$e_value){ | |
if (!array_key_exists($e_key, $origin)){ | |
$origin[$e_key] = $e_value; | |
} | |
else { | |
if (!is_array($e_value)){ | |
$origin[$e_key] = $e_value; |
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
<?php | |
function pascalize($string){ | |
$string = strtolower($string); | |
$string = str_replace('_', ' ', $string); | |
$string = ucwords($string); | |
$string = str_replace(' ', '', $string); | |
return $string; | |
} | |
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
<?php | |
function getFileList($dir, $list=array('dir'=> array(), 'file' => array())) | |
{ | |
if (is_dir($dir) == false) { | |
return $list; | |
} | |
$dh = opendir($dir); | |
if ($dh) { |
NewerOlder