<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<oembed>
  <author_name>progd</author_name>
  <author_url>https://blog.hatena.ne.jp/progd/</author_url>
  <blog_title>progd</blog_title>
  <blog_url>https://progd.hatenadiary.org/</blog_url>
  <categories>
    <anon>shellscript</anon>
    <anon>unix</anon>
    <anon>linux</anon>
  </categories>
  <description>シェルスクリプト書くときだいたいいつも必要になるけど、たまにしか書かないので忘れがちなやつをメモ。随時更新予定。 なお、全てMac OS Xの/bin/shを想定している。 絶対パスを得る fullpath=$(cd $(dirname $0) &amp;&amp; pwd) $0はシェルスクリプト自身を表すので、シェルスクリプトファイルの相対パスが得られる。 そのディレクトリでpwdすると、絶対パスが得られる。 $0のかわりに相対パスを与えると、そのファイルの絶対パスが得られる。 なお、括弧の中でcdしているが、その後の処理には影響しない。 配列 配列を作成 arr=(a b c) echo ${arr[0…</description>
  <height>190</height>
  <html>&lt;iframe src=&quot;https://hatenablog-parts.com/embed?url=https%3A%2F%2Fprogd.hatenadiary.org%2Fentry%2F20110618%2Fshellscript&quot; title=&quot;よく使うシェルスクリプト基本構文とサンプル - progd&quot; class=&quot;embed-card embed-blogcard&quot; scrolling=&quot;no&quot; frameborder=&quot;0&quot; style=&quot;display: block; width: 100%; height: 190px; max-width: 500px; margin: 10px 0px;&quot;&gt;&lt;/iframe&gt;</html>
  <image_url></image_url>
  <provider_name>Hatena Blog</provider_name>
  <provider_url>https://hatena.blog</provider_url>
  <published>2011-06-18 00:00:00</published>
  <title>よく使うシェルスクリプト基本構文とサンプル</title>
  <type>rich</type>
  <url>https://progd.hatenadiary.org/entry/20110618/shellscript</url>
  <version>1.0</version>
  <width>100%</width>
</oembed>
