<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<oembed>
  <author_name>hirosaji</author_name>
  <author_url>https://blog.hatena.ne.jp/hirosaji/</author_url>
  <blog_title>Hirosaji Tech Blog 🍙</blog_title>
  <blog_url>https://hirosaji.hatenablog.com/</blog_url>
  <categories>
    <anon>shell</anon>
  </categories>
  <description>Bash（UNIX系のシェル）を実行する際、 $ set -o pipefail $ set +o pipefail というコマンドがおまじない的に使われているのをよく見ます。 今回は、担当することになったプロダクトのCIにこのコマンドが含まれていたこともあり、処理の詳細を調べました。 その覚書もかねて、解説記事を残します。 TL;DR set ±o pipefail は、パイプラインを用いるコマンドの終了ステータスに影響する。 set -o pipefail を使うと、パイプライン内のいずれかのコマンドが失敗した場合、その失敗したコマンドの終了ステータスがパイプライン全体の終了ステータスとな…</description>
  <height>190</height>
  <html>&lt;iframe src=&quot;https://hatenablog-parts.com/embed?url=https%3A%2F%2Fhirosaji.hatenablog.com%2Fentry%2F2022%2F07%2F05%2F210045&quot; title=&quot;ネコでもわかる set ±o pipefail - Hirosaji Tech Blog 🍙&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>2022-07-05 21:00:45</published>
  <title>ネコでもわかる set ±o pipefail</title>
  <type>rich</type>
  <url>https://hirosaji.hatenablog.com/entry/2022/07/05/210045</url>
  <version>1.0</version>
  <width>100%</width>
</oembed>
