summaryrefslogtreecommitdiff
path: root/cli/generator.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'cli/generator.cxx')
-rw-r--r--cli/generator.cxx4
1 files changed, 3 insertions, 1 deletions
diff --git a/cli/generator.cxx b/cli/generator.cxx
index 486c793..5964c25 100644
--- a/cli/generator.cxx
+++ b/cli/generator.cxx
@@ -94,12 +94,14 @@ namespace
ifstream ifs;
open (ifs, file);
+ path d (path (file).directory ());
+
// getline() will set the failbit if it failed to extract anything,
// not even the delimiter and eofbit if it reached eof before seeing
// the delimiter.
//
for (string s; getline (ifs, s); )
- os << context::substitute (s, u) << endl;
+ os << context::substitute (s, u, &d) << endl;
}
}
}