mirror of
https://github.com/StevenBlack/hosts.git
synced 2026-11-19 00:30:19 +00:00
Merge pull request #34 from qutorial/myhosts
Update to include preamble handling
This commit is contained in:
commit
90ad37d6fc
3 files changed
+7
No files matched your search
@@ -0,0 +1 @@
|
||||
myhosts
|
||||
@@ -277,6 +277,12 @@ def writeOpeningHeader(finalFile):
|
||||
writeData(finalFile, '\n')
|
||||
writeData(finalFile, '127.0.0.1 localhost\n')
|
||||
writeData(finalFile, '\n')
|
||||
|
||||
preamble = os.path.join(BASEDIR_PATH, "myhosts");
|
||||
if os.path.isfile(preamble):
|
||||
with open(preamble, "r") as f:
|
||||
writeData(finalFile, f.read());
|
||||
|
||||
finalFile.write(fileContents)
|
||||
|
||||
def updateReadme(numberOfRules):
|
||||
|
||||
Reference in new issue
Block a user