{"id":655,"date":"2012-11-30T16:01:26","date_gmt":"2012-11-30T07:01:26","guid":{"rendered":"http:\/\/ts-engine.net\/?p=655"},"modified":"2012-11-30T16:01:26","modified_gmt":"2012-11-30T07:01:26","slug":"%e3%83%87%e3%82%a3%e3%83%ac%e3%82%af%e3%83%88%e3%83%aa%e9%85%8d%e4%b8%8b%e3%81%ae%e3%83%95%e3%82%a1%e3%82%a4%e3%83%ab%e5%90%8d%e3%82%92%e7%bd%ae%e6%8f%9b%e3%81%99%e3%82%8bperl%e3%82%b9%e3%82%af","status":"publish","type":"post","link":"http:\/\/ts-engine.net\/?p=655","title":{"rendered":"\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u914d\u4e0b\u306e\u30d5\u30a1\u30a4\u30eb\u540d\u3092\u7f6e\u63db\u3059\u308bperl\u30b9\u30af\u30ea\u30d7\u30c8"},"content":{"rendered":"<p>MAC\u304b\u3089ubuntu\u306bzip\u30d5\u30a1\u30a4\u30eb\u3092\u30a2\u30c3\u30d7\u30ed\u30fc\u30c9\u3057\u305f\u3002\u305d\u306ezip\u30d5\u30a1\u30a4\u30eb\u3092ubuntu\u4e0a\u3067\u3001unzip\u3057\u305f\u3068\u3053\u308d\u3001<br \/>\n__MACOS\u3068\u3044\u3046\u30d5\u30a9\u30eb\u30c0\u304c\u4f5c\u6210\u3055\u308c\u305f\u3002\u305d\u3057\u3066\u3001\u305d\u306e\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u914d\u4e0b\u306b\u3001\u30d5\u30a1\u30a4\u30eb\u304c\u3042\u308b\u306e\u3060\u304c\u3001\u306a\u305c\u304b\u3001\u30d5\u30a1\u30a4\u30eb\u540d\u306e\u3042\u305f\u307e\u306b\u3001&#8221;._&#8221;\u304c\u4ed8\u4e0e\u3055\u308c\u3001\u300c._\u30d5\u30a1\u30a4\u30eb\u540d\u300d\u3068\u3044\u3046\u30d5\u30a1\u30a4\u30eb\u540d\u306b\u306a\u3063\u3066\u3044\u305f\u3002<\/p>\n<p>\u30a2\u30c3\u30d7\u30ed\u30fc\u30c9\u3057\u305f\u30d5\u30a1\u30a4\u30eb\u540d\u306f\u3001\u5408\u8a08\u3067\u3001200\u8fd1\u304f\u3042\u3063\u305f\u306e\u3067\u3001mv\u30b3\u30de\u30f3\u30c9\u3067\u4e00\u3064\u4e00\u3064\u30d5\u30a1\u30a4\u30eb\u540d\u3092\u76f4\u3059\u306e\u306f\u9762\u5012\u3068\u601d\u3044\u3001\u4e45\u3057\u3076\u308a\u306bperl\u306e\u30b9\u30af\u30ea\u30d7\u30c8\u3092\u304b\u304f\u3053\u3068\u306b\u3057\u305f\u3002\u4ee5\u4e0b\u5185\u5bb9\u3092\u30e1\u30e2\u3002\n<\/p>\n<p><!--more--><\/p>\n<h2>\n\u76ee\u6a19\u306f\u3001\u201d._aaaa\u201d\u3068\u306a\u3063\u3066\u3044\u308b\u30d5\u30a1\u30a4\u30eb\u540d\u3092\u201daaaa\u201d\u306e\u30d5\u30a1\u30a4\u30eb\u540d\u306b\u7f6e\u63db<br \/>\n<\/h2>\n<p>\n\u30b3\u30fc\u30c9\u306f\u4ee5\u4e0b\u306e\u3068\u304a\u308a\u3001\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u3068\u3001\u30d5\u30a1\u30a4\u30eb\u306eglob\u306e\u30de\u30c3\u30c1\u306e\u66f8\u304d\u65b9\u306f\u81ea\u5206\u306e\u74b0\u5883\u306b\u3042\u308f\u305b\u3066\u4fee\u6b63\u304c\u5fc5\u8981\u3002\n<\/p>\n<p>[perl]<br \/>\n#!\/usr\/bin\/perl<\/p>\n<p>use strict;<br \/>\nuse warnings;<\/p>\n<p>my $dir = &quot;\/***\/***\/&quot;;<br \/>\n#\uff08\u30d5\u30a1\u30a4\u30eb\u540d\u3092\u5909\u66f4\u3057\u305f\u3044\u30d5\u30a1\u30a4\u30eb\u306e\u3042\u308b\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u3092\u6307\u5b9a\uff09<\/p>\n<p>chdir $dir or die &quot;\u5931\u6557* $!&quot;;<br \/>\nmy @all_files = glob &quot;._*&quot;;<br \/>\n#\u4eca\u56de\u306f._\u304b\u3089\u306f\u3058\u3081\u308b\u30d5\u30a1\u30a4\u30eb\u540d\u3092\u5909\u66f4\u3057\u305f\u3044\u306e\u3067\u3001glob\u306e\u30d5\u30a1\u30a4\u30eb\u30de\u30c3\u30c1\u3092\u4e0a\u8a18\u306e\u901a\u308a\u8a18\u8f09\u3002<\/p>\n<p>my $item;<br \/>\nforeach $item (@all_files){<br \/>\n\t my $oldfile = $item;<br \/>\n         $item =~ s\/\\._\/\/g;<br \/>\n         my $newfile = $item;<br \/>\n\t rename ($oldfile,$newfile);<br \/>\n}<br \/>\n[\/perl]<br \/>\n\u30d5\u30a1\u30a4\u30eb\u540d\u306fhenko.pl\u3068\u3057\u3066\u3001\u5f8c\u306f\u30b7\u30a7\u30eb\u3067\u3001\u4ee5\u4e0b\u3092\u53e9\u3051\u3070\u5b8c\u4e86\u3002<br \/>\n[bash]<br \/>\n$perl henko.pl<br \/>\n[\/bash]<\/p>\n","protected":false},"excerpt":{"rendered":"<p>MAC\u304b\u3089ubuntu\u306bzip\u30d5\u30a1\u30a4\u30eb\u3092\u30a2\u30c3\u30d7\u30ed\u30fc\u30c9\u3057\u305f\u3002\u305d\u306ezip\u30d5\u30a1\u30a4\u30eb\u3092ubuntu\u4e0a\u3067\u3001unzip\u3057\u305f\u3068\u3053\u308d\u3001 __MACOS\u3068\u3044\u3046\u30d5\u30a9\u30eb\u30c0\u304c\u4f5c\u6210\u3055\u308c\u305f\u3002\u305d\u3057\u3066\u3001\u305d\u306e\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u914d\u4e0b\u306b\u3001\u30d5\u30a1\u30a4\u30eb\u304c\u3042\u308b\u306e\u3060\u304c\u3001\u306a\u305c\u304b\u3001\u30d5\u30a1\u30a4\u30eb\u540d\u306e\u3042\u305f\u307e\u306b\u3001&#8221;._&#8221;\u304c\u4ed8\u4e0e\u3055\u308c\u3001\u300c._\u30d5\u30a1\u30a4\u30eb\u540d\u300d\u3068\u3044\u3046\u30d5\u30a1\u30a4\u30eb\u540d\u306b\u306a\u3063\u3066\u3044\u305f\u3002 \u30a2\u30c3\u30d7\u30ed\u30fc\u30c9\u3057\u305f\u30d5\u30a1\u30a4\u30eb\u540d\u306f\u3001\u5408\u8a08\u3067\u3001200\u8fd1\u304f\u3042\u3063\u305f\u306e\u3067\u3001mv\u30b3\u30de\u30f3\u30c9\u3067\u4e00\u3064\u4e00\u3064\u30d5\u30a1\u30a4\u30eb\u540d\u3092\u76f4\u3059\u306e\u306f\u9762\u5012\u3068\u601d\u3044\u3001\u4e45\u3057\u3076\u308a\u306bperl\u306e\u30b9\u30af\u30ea\u30d7\u30c8\u3092\u304b\u304f\u3053\u3068\u306b\u3057\u305f\u3002\u4ee5\u4e0b\u5185\u5bb9\u3092\u30e1\u30e2\u3002<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[19,20,6,7],"tags":[28],"class_list":["post-655","post","type-post","status-publish","format-standard","hentry","category-perl","category-20","category-6","category-7","tag-perl"],"_links":{"self":[{"href":"http:\/\/ts-engine.net\/index.php?rest_route=\/wp\/v2\/posts\/655","targetHints":{"allow":["GET"]}}],"collection":[{"href":"http:\/\/ts-engine.net\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/ts-engine.net\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/ts-engine.net\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/ts-engine.net\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=655"}],"version-history":[{"count":0,"href":"http:\/\/ts-engine.net\/index.php?rest_route=\/wp\/v2\/posts\/655\/revisions"}],"wp:attachment":[{"href":"http:\/\/ts-engine.net\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=655"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/ts-engine.net\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=655"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/ts-engine.net\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=655"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}