DPR-blocked-sites/scripts/z_remove_duplicates.py

7 lines
179 B
Python
Raw Normal View History

2022-08-26 13:02:52 +03:00
inp = open('ips.txt', 'r')
uniqlines = list(dict.fromkeys(inp.readlines()))
inp.close()
out = open('ips.txt', 'w')
out.writelines(uniqlines)
out.truncate(out.tell()-1)
out.close()