From 3931c20de482ff02bbcbf3be35cfe6a49cf08d8b Mon Sep 17 00:00:00 2001 From: "H. S. Teoh" Date: Fri, 8 Aug 2014 14:36:19 -0700 Subject: [PATCH] Replace deprecated getenv(X) with environment[X]. --- terminal.d | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/terminal.d b/terminal.d index 42438e3..7cf641d 100644 --- a/terminal.d +++ b/terminal.d @@ -303,7 +303,7 @@ struct Terminal { bool terminalInFamily(string[] terms...) { import std.process; import std.string; - auto term = getenv("TERM"); + auto term = environment["TERM"]; foreach(t; terms) if(indexOf(term, t) != -1) return true; @@ -393,9 +393,9 @@ struct Terminal { import std.string; import std.array; - string termcapData = getenv("TERMCAP"); + string termcapData = environment["TERMCAP"]; if(termcapData.length == 0) { - termcapData = getTermcapDatabase(getenv("TERM")); + termcapData = getTermcapDatabase(environment["TERM"]); } auto e = replace(termcapData, "\\\n", "\n");