そこそこの規模のプロジェクトにおいてコードやプロダクトの責任者(全てを知っている人)を明確化する
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
use common::sense; | |
use Test::PostgreSQL; | |
use Path::Class; | |
# おそらくOSとかによってTest::PostgreSQLの期待するpostgersql.confの設定と違うため | |
# 環境によって起動がクソ遅くなる | |
# configを弄った方がいいのでauto_startはoff | |
my $psql = Test::PostgreSQL->new( auto_start => 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
use common::sense; | |
use Furl; | |
use JSON::XS; | |
my $FFPROBE = `which ffprobe`; | |
chomp $FFPROBE; | |
say encode_json( parse_all( shift ) ); |
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
// ==UserScript== | |
// @name ZAC Emphasize | |
// @version 0.1 | |
// @copyright nagata-hiroaki@kayac.com | |
// @namespace http://handlena.me | |
// @description This script bring little better ZAC to you. | |
// @include https://asp19.jp.oro.com/kayac/Shinsei/Nippou.asp* | |
// ==/UserScript== | |
document.getElementsByXPath = function(expression, parentElement) { |
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
### これはOK | |
local $HTTP::Request::Common::DYNAMIC_FILE_UPLOAD = 1; | |
my $uri = URI->new( 'https://exapmpe.com/post'); | |
my $request = POST $uri, | |
Content_Type => 'multipart/form-data', | |
Content => [ | |
file1 => [ 'file1.mp4' ], | |
file2 => [ 'file2.jpg' ], |
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
use common::sense; | |
use Benchmark qw(:all); | |
use Sub::Rate::NoMaxRate; | |
use List::MoreUtils qw(none any); | |
my @putturn1; | |
push @putturn1, [ 100000, "a100000-1" ]; | |
push @putturn1, map { [ 5, "a5-$_" ] } (1..50); | |
push @putturn1, map { [ 3, "a3-$_" ] } (1..100); | |
push @putturn1, map { [ 1, "a1-$_" ] } (1..1000); |
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
use common::sense; | |
use Benchmark qw(:all); | |
my @words = ( | |
' ほげ ', | |
'ほげ ', | |
' ぶう', | |
'ぶう', | |
'あいうえおかきくけっこ ', | |
' あいうえおかきくけっこ', |
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 upper_and_length($item) | |
{ | |
global $maxlength; | |
$item = strtoupper(preg_replace('/([a-z0-9])([A-Z])/', '$1_$2', $item)); | |
if ($maxlength < strlen($item)) | |
$maxlength = strlen($item); | |
return $item; | |
} |
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 IS_DEV = true; | |
// logger | |
var console = window.console; | |
if (IS_DEV === false || !console) { | |
console = { | |
log: function(){}, | |
debug: function(){}, | |
info: function(){}, | |
warn: function(){}, |
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/env sh | |
dir=$1 | |
echo "target > $dir" | |
pattern="^No*" | |
files=`find $dir -name '*.php'` | |
for file in $files | |
do |
OlderNewer