Skip to content

Commit 3f5d246

Browse files
committed
Command execution
1 parent 3a0403c commit 3f5d246

File tree

2 files changed

+9
-7
lines changed

2 files changed

+9
-7
lines changed

README.md

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1610,12 +1610,13 @@ os.mkdir(<path>, mode=0o777) # Creates a directory.
16101610
```
16111611

16121612
#### DirEntry:
1613-
```pyton
1614-
<str> = <DirEntry>.name
1615-
<str> = <DirEntry>.path
1613+
```python
1614+
<str> = <DirEntry>.name # Final component of the path.
1615+
<str> = <DirEntry>.path # Path with final component.
16161616
<bool> = <DirEntry>.is_file()
16171617
<bool> = <DirEntry>.is_dir()
1618-
<bool> = <DirEntry>.is_symlink()
1618+
<bool> = <DirEntry>.is_symlink()
1619+
<Path> = Path(<DirEntry>)
16191620
```
16201621

16211622
### Shell Commands

index.html

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1445,11 +1445,12 @@ <h3 id="filesanddirectoriescommands">Files and Directories Commands</h3>
14451445
&lt;iter&gt; = os.scandir(path=<span class="hljs-string">'.'</span>) <span class="hljs-comment"># Returns os.DirEntry objects located at path.</span>
14461446
</code></pre>
14471447
<h4 id="direntry">DirEntry:</h4>
1448-
<pre><code class="pyton language-pyton python">&lt;str&gt; = &lt;DirEntry&gt;.name
1449-
&lt;str&gt; = &lt;DirEntry&gt;.path
1448+
<pre><code class="python language-python hljs">&lt;str&gt; = &lt;DirEntry&gt;.name <span class="hljs-comment"># Final component of the path.</span>
1449+
&lt;str&gt; = &lt;DirEntry&gt;.path <span class="hljs-comment"># Path with final component.</span>
14501450
&lt;bool&gt; = &lt;DirEntry&gt;.is_file()
14511451
&lt;bool&gt; = &lt;DirEntry&gt;.is_dir()
1452-
&lt;bool&gt; = &lt;DirEntry&gt;.is_symlink()
1452+
&lt;bool&gt; = &lt;DirEntry&gt;.is_symlink()
1453+
&lt;Path&gt; = Path(&lt;DirEntry&gt;)
14531454
</code></pre>
14541455
<h3 id="shellcommands">Shell Commands</h3>
14551456
<pre><code class="python language-python hljs"><span class="hljs-keyword">import</span> os

0 commit comments

Comments
 (0)