Skip to content

Commit e8fb2a9

Browse files
committed
Command execution
1 parent b2fdaa7 commit e8fb2a9

File tree

2 files changed

+10
-12
lines changed

2 files changed

+10
-12
lines changed

README.md

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1619,15 +1619,14 @@ os.mkdir(<path>, mode=0o777) # Creates a directory.
16191619

16201620
#### DirEntry:
16211621
```python
1622-
<str> = <DirEntry>.name # Final component of the path.
1623-
<str> = <DirEntry>.path # Path with final component.
1624-
<Path> = Path(<DirEntry>) # Path object.
1622+
<bool> = <DirEntry>.is_file()
1623+
<bool> = <DirEntry>.is_dir()
16251624
```
16261625

16271626
```python
1628-
<bool> = <DirEntry>.is_file()
1629-
<bool> = <DirEntry>.is_dir()
1630-
<bool> = <DirEntry>.is_symlink()
1627+
<str> = <DirEntry>.name # Final component of the path.
1628+
<str> = <DirEntry>.path # Path with final component.
1629+
<Path> = Path(<DirEntry>) # Path object.
16311630
```
16321631

16331632
### Shell Commands

index.html

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1459,14 +1459,13 @@
14591459
<pre><code class="python language-python hljs">os.mkdir(&lt;path&gt;, mode=<span class="hljs-number">0o777</span>) <span class="hljs-comment"># Creates a directory.</span>
14601460
&lt;iter&gt; = os.scandir(path=<span class="hljs-string">'.'</span>) <span class="hljs-comment"># Returns os.DirEntry objects located at path.</span>
14611461
</code></pre>
1462-
<div><h4 id="direntry">DirEntry:</h4><pre><code class="python language-python hljs">&lt;str&gt; = &lt;DirEntry&gt;.name <span class="hljs-comment"># Final component of the path.</span>
1463-
&lt;str&gt; = &lt;DirEntry&gt;.path <span class="hljs-comment"># Path with final component.</span>
1464-
&lt;Path&gt; = Path(&lt;DirEntry&gt;) <span class="hljs-comment"># Path object.</span>
1462+
<div><h4 id="direntry">DirEntry:</h4><pre><code class="python language-python hljs">&lt;bool&gt; = &lt;DirEntry&gt;.is_file()
1463+
&lt;bool&gt; = &lt;DirEntry&gt;.is_dir()
14651464
</code></pre></div>
14661465

1467-
<pre><code class="python language-python hljs">&lt;bool&gt; = &lt;DirEntry&gt;.is_file()
1468-
&lt;bool&gt; = &lt;DirEntry&gt;.is_dir()
1469-
&lt;bool&gt; = &lt;DirEntry&gt;.is_symlink()
1466+
<pre><code class="python language-python hljs">&lt;str&gt; = &lt;DirEntry&gt;.name <span class="hljs-comment"># Final component of the path.</span>
1467+
&lt;str&gt; = &lt;DirEntry&gt;.path <span class="hljs-comment"># Path with final component.</span>
1468+
&lt;Path&gt; = Path(&lt;DirEntry&gt;) <span class="hljs-comment"># Path object.</span>
14701469
</code></pre>
14711470
<div><h3 id="shellcommands">Shell Commands</h3><pre><code class="python language-python hljs"><span class="hljs-keyword">import</span> os
14721471
&lt;str&gt; = os.popen(<span class="hljs-string">'&lt;shell_command&gt;'</span>).read()

0 commit comments

Comments
 (0)