Skip to content

Commit ab0081a

Browse files
committed
Fix PEP8 in snapshot.py
1 parent 58d03ad commit ab0081a

File tree

3 files changed

+161
-137
lines changed

3 files changed

+161
-137
lines changed

src/etc/get-snapshot.py

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,9 +10,13 @@
1010
# option. This file may not be copied, modified, or distributed
1111
# except according to those terms.
1212

13-
import os, tarfile, re, shutil, sys
13+
import os
14+
import tarfile
15+
import shutil
16+
import sys
1417
from snapshot import *
1518

19+
1620
def unpack_snapshot(triple, dl_path):
1721
print("opening snapshot " + dl_path)
1822
tar = tarfile.open(dl_path)
@@ -29,14 +33,14 @@ def unpack_snapshot(triple, dl_path):
2933
os.unlink(os.path.join(root, f))
3034

3135
for p in tar.getnames():
32-
name = p.replace("rust-stage0/", "", 1);
36+
name = p.replace("rust-stage0/", "", 1)
3337

3438
fp = os.path.join(stagep, name)
3539
print("extracting " + p)
3640
tar.extract(p, download_unpack_base)
3741
tp = os.path.join(download_unpack_base, p)
3842
if os.path.isdir(tp) and os.path.exists(fp):
39-
continue
43+
continue
4044
shutil.move(tp, fp)
4145
tar.close()
4246
shutil.rmtree(download_unpack_base)

src/etc/mklldeps.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,6 @@
1111
import os
1212
import sys
1313
import subprocess
14-
import itertools
15-
from os import path
1614

1715
f = open(sys.argv[1], 'wb')
1816

@@ -35,6 +33,7 @@
3533
// take a look at src/etc/mklldeps.py if you're interested
3634
""")
3735

36+
3837
def run(args):
3938
proc = subprocess.Popen(args, stdout=subprocess.PIPE, stderr=subprocess.PIPE)
4039
out, err = proc.communicate()

0 commit comments

Comments
 (0)