mirror of
https://github.com/ookangzheng/blahdns.git
synced 2025-12-15 21:55:36 +07:00
add gitignore
This commit is contained in:
4
hosts/.gitignore
vendored
Normal file
4
hosts/.gitignore
vendored
Normal file
@@ -0,0 +1,4 @@
|
|||||||
|
adsblock.txt
|
||||||
|
rpz.txt
|
||||||
|
gravity.list
|
||||||
|
convert.py
|
||||||
@@ -1,10 +1,10 @@
|
|||||||
import os
|
import os
|
||||||
|
|
||||||
inputFile = "gravity.list"
|
inputFile = "gravity.list"
|
||||||
outputFile = "rpz.blacklist"
|
outputFile = "rpz.txt"
|
||||||
|
|
||||||
with open(inputFile, 'r') as f: # load file
|
with open(inputFile, 'r') as f: # load file
|
||||||
lines = f.read().splitlines() # read lines
|
lines = f.read().splitlines() # read lines
|
||||||
os.remove("rpz.blacklist")
|
os.remove("rpz.txt")
|
||||||
with open(outputFile, 'w') as f:
|
with open(outputFile, 'w') as f:
|
||||||
f.write('\n'.join([line + ' CNAME .' for line in lines]))
|
f.write('\n'.join([line + ' CNAME .' for line in lines]))
|
||||||
|
|||||||
Reference in New Issue
Block a user