{"id":11796,"date":"2013-08-16T10:58:44","date_gmt":"2013-08-16T01:58:44","guid":{"rendered":"http:\/\/www.softantenna.com\/wp\/?p=11796"},"modified":"2013-08-16T10:58:44","modified_gmt":"2013-08-16T01:58:44","slug":"matrix-style-shell-script","status":"publish","type":"post","link":"https:\/\/softantenna.com\/blog\/matrix-style-shell-script\/","title":{"rendered":"Matrix\u30b9\u30bf\u30a4\u30eb\u3067\u30bf\u30fc\u30df\u30ca\u30eb\u3092\u697d\u3057\u3080Tips"},"content":{"rendered":"<p><img decoding=\"async\" src=\"https:\/\/softantenna.com\/blog\/wp-content\/uploads\/2013\/08\/blogmatrix.png\" alt=\"Matrix\" title=\"matrix.png\" border=\"0\" width=\"560\" height=\"408\" \/><\/p>\n<p>SF\u6620\u753bMatrix\u3068\u3044\u3048\u3070\u9ed2\u30d0\u30c3\u30af\u306b\u6d41\u308c\u308b\u8b0e\u306e\u7dd1\u306e\u6587\u5b57\u306e\u30b7\u30fc\u30f3\u304c\u6709\u540d\u3067\u3059\u3002\u3053\u308c\u3092\u30bf\u30fc\u30df\u30ca\u30eb\u3067\u7c21\u5358\u306b\u518d\u73fe\u3059\u308b\u30b7\u30a7\u30eb\u30b9\u30af\u30ea\u30d7\u30c8\u306e\u5c0f\u6280\u304c\u7d39\u4ecb\u3055\u308c\u3066\u3044\u307e\u3057\u305f(<a href=\"http:\/\/osxdaily.com\/2013\/08\/15\/turn-the-terminal-into-a-matrix-style-scrolling-screen-of-binary-or-gibberish\/\">OS X Daily<\/a>\u3001<a href=\"http:\/\/www.commandlinefu.com\/commands\/view\/2542\/matrix-style\">\u5143\u30cd\u30bf\u306eCommandLineFu<\/a>)\u3002<\/p>\n<p>\u4e00\u5fdcMac\u306e\u30bf\u30fc\u30df\u30ca\u30eb(Terminal)\u3067\u5b9f\u884c\u3059\u308b\u65b9\u6cd5\u3092\u8aac\u660e\u3057\u307e\u3059\u304c\u3001Linux\u306a\u3093\u304b\u3067\u3082\u540c\u3058\u69d8\u306b\u5b9f\u884c\u3067\u304d\u308b\u306f\u305a\u3002<\/p>\n<p><!--more--><\/p>\n<h3>\u30b9\u30bf\u30a4\u30eb\u306e\u5909\u66f4<\/h3>\n<p><img decoding=\"async\" src=\"https:\/\/softantenna.com\/blog\/wp-content\/uploads\/2013\/08\/4bd23751439ecbf6fbfaaf25fda4c8e9.png\" alt=\"\u8a2d\u5b9a 1\" title=\"\u8a2d\u5b9a-1.png\" border=\"0\" width=\"560\" height=\"469\" \/><br \/>\n\u74b0\u5883\u8a2d\u5b9a\u3067\u3001\u9ed2\u80cc\u666f\u3067\u3001\u7dd1\u6587\u5b57\u306e\u300c<strong>Homebrew<\/strong>\u300d\u3092\u9078\u3093\u3067\u304a\u304d\u307e\u3057\u3087\u3046\u3002<\/p>\n<h3>\u30b9\u30bf\u30a4\u30eb1: \u30e9\u30f3\u30c0\u30e0\u30ca\u30f3\u30d0\u30fc<\/h3>\n<pre>\nLC_ALL=C tr -c \"[:digit:]\" \" \" < \/dev\/urandom | dd cbs=$COLUMNS conv=unblock | GREP_COLOR=\"1;32\" grep --color \"[^ ]\"\n<\/pre>\n<p>\u3053\u308c\u3092\u30bf\u30fc\u30df\u30ca\u30eb\u306b\u8cbc\u308a\u4ed8\u3051\u3066\u5b9f\u884c\u3002<\/p>\n<p><img decoding=\"async\" src=\"https:\/\/softantenna.com\/blog\/wp-content\/uploads\/2013\/08\/blogterminal1.png\" alt=\"Terminal1\" title=\"terminal1.png\" border=\"0\" width=\"560\" height=\"257\" \/><\/p>\n<p>\u6570\u5b57\u304c\u30e9\u30f3\u30c0\u30e0\u306b\u8868\u793a\u3055\u308c\u307e\u3059\u3002\u6b62\u3081\u305f\u3044\u3068\u304d\u306fCTRL-C\u3067\u3002<\/p>\n<h3>\u30b9\u30bf\u30a4\u30eb2: \u30b9\u30af\u30ed\u30fc\u30eb<\/h3>\n<pre>\necho -e \"1\"; while $t; do for i in `seq 1 30`;do r=\"$[($RANDOM % 2)]\";h=\"$[($RANDOM % 4)]\";if [ $h -eq 1 ]; then v=\"0 $r\";else v=\"1 $r\";fi;v2=\"$v2 $v\";done;echo -e $v2;v2=\"\";done;\n<\/pre>\n<p><img decoding=\"async\" src=\"https:\/\/softantenna.com\/blog\/wp-content\/uploads\/2013\/08\/blogterminal2.png\" alt=\"Terminal2\" title=\"terminal2.png\" border=\"0\" width=\"560\" height=\"257\" \/><\/p>\n<p>alias matrix=\"...\"\u3057\u3068\u3051\u3070\u3044\u3064\u3067\u3082\u547c\u3073\u51fa\u305b\u307e\u3059\u304c\u3001\u305d\u3053\u307e\u3067\u3057\u306a\u304f\u3066\u3082\u3044\u3044\u304b\u3082\uff57<\/p>\n","protected":false},"excerpt":{"rendered":"<p>SF\u6620\u753bMatrix\u3068\u3044\u3048\u3070\u9ed2\u30d0\u30c3\u30af\u306b\u6d41\u308c\u308b\u8b0e\u306e\u7dd1\u306e\u6587\u5b57\u306e\u30b7\u30fc\u30f3\u304c\u6709\u540d\u3067\u3059\u3002\u3053\u308c\u3092\u30bf\u30fc\u30df\u30ca\u30eb\u3067\u7c21\u5358\u306b\u518d\u73fe\u3059\u308b\u30b7\u30a7\u30eb\u30b9\u30af\u30ea\u30d7\u30c8\u306e\u5c0f\u6280\u304c\u7d39\u4ecb\u3055\u308c\u3066\u3044\u307e\u3057\u305f(OS X Daily\u3001\u5143\u30cd\u30bf\u306eCommandLineFu)\u3002 \u4e00\u5fdcM [&hellip;]<\/p>\n","protected":false},"author":2,"featured_media":11791,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"swell_btn_cv_data":"","footnotes":""},"categories":[75,13],"tags":[654,1383],"class_list":["post-11796","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-software","category-etc","tag-matrix","tag-shell"],"_links":{"self":[{"href":"https:\/\/softantenna.com\/blog\/wp-json\/wp\/v2\/posts\/11796","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/softantenna.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/softantenna.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/softantenna.com\/blog\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/softantenna.com\/blog\/wp-json\/wp\/v2\/comments?post=11796"}],"version-history":[{"count":0,"href":"https:\/\/softantenna.com\/blog\/wp-json\/wp\/v2\/posts\/11796\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/softantenna.com\/blog\/wp-json\/wp\/v2\/media\/11791"}],"wp:attachment":[{"href":"https:\/\/softantenna.com\/blog\/wp-json\/wp\/v2\/media?parent=11796"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/softantenna.com\/blog\/wp-json\/wp\/v2\/categories?post=11796"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/softantenna.com\/blog\/wp-json\/wp\/v2\/tags?post=11796"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}