mirror of
https://github.com/StevenBlack/hosts.git
synced 2026-10-04 22:05:39 +01:00
Merge pull request #651 from funilrys/issue.644
Introduction of `Start xx` and `End xxx`
This commit is contained in:
+5
-1
@@ -632,8 +632,12 @@ def create_initial_file():
|
||||
# spin the sources for the base file
|
||||
for source in recursive_glob(settings["datapath"],
|
||||
settings["hostfilename"]):
|
||||
|
||||
start = "# Start {}\n".format(os.path.basename(os.path.dirname(source)))
|
||||
end = "# End {}\n".format(os.path.basename(os.path.dirname(source)))
|
||||
|
||||
with open(source, "r") as curFile:
|
||||
write_data(merge_file, curFile.read())
|
||||
write_data(merge_file, start + curFile.read() + end)
|
||||
|
||||
# spin the sources for extensions to the base file
|
||||
for source in settings["extensions"]:
|
||||
|
||||
Reference in New Issue
Block a user