<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<oembed>
  <author_name>posturan</author_name>
  <author_url>https://blog.hatena.ne.jp/posturan/</author_url>
  <blog_title>Oboe吹きプログラマの黙示録</blog_title>
  <blog_url>https://oboe2uran.hatenablog.com/</blog_url>
  <categories>
    <anon>Python</anon>
  </categories>
  <description>ディレクトリ内のファイルリストは、最も安易な方法は、glob を使うことであるが、 再帰的に全てのファイルリストを得るには、recursive=True が必要である。 import glob files = glob.glob(&quot;/var/tmp/**&quot;, recursive=True) for f in files: print(f) 再帰的に全てのファイルリストで、尚且つディレクトリではなくファイルに限定するならば、 pathlib の Path から、glob を使うのが良い。 is_file() で、ファイルに限定できる。 is_dir() なら、ディレクトリに限定 from pat…</description>
  <height>190</height>
  <html>&lt;iframe src=&quot;https://hatenablog-parts.com/embed?url=https%3A%2F%2Foboe2uran.hatenablog.com%2Fentry%2F2021%2F07%2F06%2F003000&quot; title=&quot;ディレクトリ内のファイルリストを取得 - Oboe吹きプログラマの黙示録&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>2021-07-06 00:30:00</published>
  <title>ディレクトリ内のファイルリストを取得</title>
  <type>rich</type>
  <url>https://oboe2uran.hatenablog.com/entry/2021/07/06/003000</url>
  <version>1.0</version>
  <width>100%</width>
</oembed>
