Skip to content

Commit 60d12f7

Browse files
committed
Pathlib
1 parent e8fb2a9 commit 60d12f7

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1571,8 +1571,8 @@ cwd = Path()
15711571
```
15721572

15731573
```python
1574-
<iter> = <Path>.iterdir() # Iterator of filenames located at path.
1575-
<iter> = <Path>.glob('<pattern>') # Filenames matching the wildcard pattern.
1574+
<iter> = <Path>.iterdir() # Returns dir contents as Path objects.
1575+
<iter> = <Path>.glob('<pattern>') # Paths matching the wildcard pattern.
15761576
```
15771577

15781578
```python

index.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1427,8 +1427,8 @@
14271427
&lt;bool&gt; = &lt;Path&gt;.is_file()
14281428
&lt;bool&gt; = &lt;Path&gt;.is_dir()
14291429
</code></pre>
1430-
<pre><code class="python language-python hljs">&lt;iter&gt; = &lt;Path&gt;.iterdir() <span class="hljs-comment"># Iterator of filenames located at path.</span>
1431-
&lt;iter&gt; = &lt;Path&gt;.glob(<span class="hljs-string">'&lt;pattern&gt;'</span>) <span class="hljs-comment"># Filenames matching the wildcard pattern.</span>
1430+
<pre><code class="python language-python hljs">&lt;iter&gt; = &lt;Path&gt;.iterdir() <span class="hljs-comment"># Returns dir contents as Path objects.</span>
1431+
&lt;iter&gt; = &lt;Path&gt;.glob(<span class="hljs-string">'&lt;pattern&gt;'</span>) <span class="hljs-comment"># Paths matching the wildcard pattern.</span>
14321432
</code></pre>
14331433
<pre><code class="python language-python hljs">&lt;str&gt; = str(&lt;Path&gt;) <span class="hljs-comment"># Returns path as a string.</span>
14341434
&lt;tup.&gt; = &lt;Path&gt;.parts <span class="hljs-comment"># Returns all components as strings.</span>

0 commit comments

Comments
 (0)