Browse Source

OS commands

pull/52/head
Jure Šorn 5 years ago
parent
commit
cedb06a048
3 changed files with 3 additions and 3 deletions
  1. 2
      README.md
  2. 2
      index.html
  3. 2
      parse.js

2
README.md

@ -1679,7 +1679,7 @@ shutil.copytree(from, to) # Copies the directory.
```
```python
os.rename(from, to) # Renames the file or directory.
os.rename(from, to) # Renames or moves the file or directory.
os.replace(from, to) # Same, but overwrites 'to' if it exists.
```

2
index.html

@ -1525,7 +1525,7 @@ os.mkdir(&lt;path&gt;, mode=<span class="hljs-number">0o777</span>) <span
<pre><code class="python language-python hljs">shutil.copy(from, to) <span class="hljs-comment"># Copies the file.</span>
shutil.copytree(from, to) <span class="hljs-comment"># Copies the directory.</span>
</code></pre>
<pre><code class="python language-python hljs">os.rename(from, to) <span class="hljs-comment"># Renames the file or directory.</span>
<pre><code class="python language-python hljs">os.rename(from, to) <span class="hljs-comment"># Renames or moves the file or directory.</span>
os.replace(from, to) <span class="hljs-comment"># Same, but overwrites 'to' if it exists.</span>
</code></pre>
<pre><code class="python language-python hljs">os.remove(&lt;path&gt;) <span class="hljs-comment"># Deletes the file.</span>

2
parse.js

@ -34,7 +34,7 @@ const TOC =
'</code></pre>\n';
const OS_RENAME =
'os.rename(from, to) <span class="hljs-comment"># Renames the file or directory.</span>\n' +
'os.rename(from, to) <span class="hljs-comment"># Renames or moves the file or directory.</span>\n' +
'os.replace(from, to) <span class="hljs-comment"># Same, but overwrites \'to\' if it exists.</span>\n';
const SHUTIL_COPY =

Loading…
Cancel
Save