git.99rst.org
/
stevenblack-hosts.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
| inline |
side by side
(parent:
be64c93
)
Issue #77: fix bug with emitting comments.
author
Steven Black
<redacted>
Fri, 25 Mar 2016 03:34:28 +0000
(23:34 -0400)
committer
Steven Black
<redacted>
Fri, 25 Mar 2016 03:34:28 +0000
(23:34 -0400)
updateHostsFile.py
patch
|
blob
|
history
diff --git
a/updateHostsFile.py
b/updateHostsFile.py
index a6133cf616f0e6efb9ce69cbb7c60f958d6be190..20432e09fa4dd82677b23cc148d654c7fa555bec 100644
(file)
--- a/
updateHostsFile.py
+++ b/
updateHostsFile.py
@@
-320,9
+320,7
@@
def removeDupsAndExcl(mergeFile):
# replace tabs with space
line = line.replace('\t+', ' ')
# Trim trailing whitespace
- line = line.rstrip()
- if not line:
- continue
+ line = line.rstrip() + "\n"
# Testing the first character doesn't require startswith
if line[0] == '#' or re.match(r'^\s*$', line[0]):
# Cross-python write
git clone https://git.99rst.org/PROJECT