Browse Source

[file_utils] fix python shebang & run prospector

prospector is still complaining about bare excepts in unln.py.
master
Matteo Cypriani 1 year ago
parent
commit
9ba0a794aa
2 changed files with 5 additions and 5 deletions
  1. 3
    3
      file_utils/dirpacker.py
  2. 2
    2
      file_utils/unln.py

+ 3
- 3
file_utils/dirpacker.py View File

@@ -1,4 +1,4 @@
#!/usr/bin/python3
#!/usr/bin/env python3
#
# dirpacker.py, Copyright © 2014 Matteo Cypriani <mcy@lm7.fr>
#
@@ -119,7 +119,7 @@ def create_bin(binnumber):
files[sizes[size].pop()] = size
# Delete the size from the dictionary if its last file name was just
# popped:
if not len(sizes[size]):
if not sizes[size]:
del sizes[size]

binsize = newbinsize
@@ -194,7 +194,7 @@ if options.verbose:
bins = []
binnumber = options.first_bin_number
binscreated = 0
while len(sizes):
while sizes:
bins.append(create_bin(binnumber))
binnumber += 1
binscreated += 1

+ 2
- 2
file_utils/unln.py View File

@@ -1,4 +1,4 @@
#!/usr/bin/python3
#!/usr/bin/env python3
#
# unln.py, Copyright © 2013 Matteo Cypriani <mcy@lm7.fr>
#
@@ -177,6 +177,6 @@ for filename in options.filenames:


# Display the list of files in error
if len(error_filenames):
if error_filenames:
warn("The following regular files still have more than one hard link:")
print(*error_filenames, sep="\n", file=sys.stderr)

Loading…
Cancel
Save