]> git.lyx.org Git - lyx.git/blob - src/support/getUserName.C
change to use ostreams instead of string when writing files. fiddling with insettext...
[lyx.git] / src / support / getUserName.C
1 #include <config.h>
2
3 #include "support/lyxlib.h"
4 #include "support/filetools.h"
5 #include "gettext.h"
6
7 string lyx::getUserName()
8 {
9         string userName(GetEnv("LOGNAME"));
10         if (userName.empty())
11                 userName = GetEnv("USER");
12         if (userName.empty())
13                 userName = _("unknown");
14         return userName;
15 }