mirror of
https://github.com/minoplhy/filters-maker.git
synced 2024-12-22 18:18:13 +00:00
Clear Blank Space after merged file in add_file module
This commit is contained in:
parent
e2ad2d6f63
commit
7c6893cae4
@ -25,6 +25,12 @@ def add_file(incoming,excluded_in):
|
||||
lines = set(f.readlines())
|
||||
with open(incoming, 'w') as f:
|
||||
f.writelines(set(lines))
|
||||
with open(incoming ,'r') as f:
|
||||
lines = f.read().split()
|
||||
with open(incoming ,'w') as f:
|
||||
for line in lines:
|
||||
if line.strip():
|
||||
f.write('\n'.join([line + '\n']))
|
||||
crawler.sort(incoming)
|
||||
os.remove(excluded_in)
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user