From 26d28ad47544a81cf873e621e6e925eff1b421b2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jure=20=C5=A0orn?= Date: Mon, 25 Feb 2019 20:18:52 +0100 Subject: [PATCH] Pathlib --- README.md | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/README.md b/README.md index 8efdb6d..f3c5662 100644 --- a/README.md +++ b/README.md @@ -1006,11 +1006,7 @@ from os import path, listdir ['1.gif', 'card.gif'] ``` - -Pathlib -------- -**This module offers classes representing filesystem paths with semantics appropriate for different operating systems.** - +### Pathlib ```python from pathlib import Path cwd = Path() @@ -1042,7 +1038,6 @@ cwd = Path() Command Line Arguments ---------------------- -### Basic ```python import sys script_name = sys.argv[0] @@ -1072,7 +1067,7 @@ import os = os.popen().read() ``` -#### Or: +### Subprocess ```python >>> import subprocess >>> a = subprocess.run(['ls', '-a'], stdout=subprocess.PIPE)