Index: ensure_dependencies.py |
diff --git a/ensure_dependencies.py b/ensure_dependencies.py |
index c1c71456560ec3ef06bde7ab45d6b925fa1cecfa..c03069d6a3c99aaf80df95444d0a8757a42a7e1b 100755 |
--- a/ensure_dependencies.py |
+++ b/ensure_dependencies.py |
@@ -355,6 +355,7 @@ def resolve_deps(repodir, level=0, self_update=True, overrideroots=None, skipdep |
def _ensure_line_exists(path, pattern): |
with open(path, 'a+') as f: |
+ f.seek(0, os.SEEK_SET) |
file_content = [l.strip() for l in f.readlines()] |
if not pattern in file_content: |
file_content.append(pattern) |