we are using the following piece of serilog code which writes events to console and file, the file and console logging works fine on my machine, but in the other developers machine console logging works but the file logging does not work and to add to the weirdness the"logs" folder gets created though. Is there any extra setup that needs to be done ?
public static void SetupLogger()
{
//var outputTemplate = "[{Timestamp:HH:mm:ss} {Level:u3}] {Message:lj}{NewLine}{Exception}";
var outputTemplate = "[{Level:u3}] {Message:lj}{NewLine}{Exception}";
// Logger
//var outputTemplate = "{Timestamp:yyyy-MM-dd HH:mm:ss.fff} [{Level:u4}] | {Message:l}{NewLine}{Exception}";
Log.Logger = new LoggerConfiguration()
.MinimumLevel.Verbose()
.WriteTo.Console(outputTemplate: outputTemplate, theme:SystemConsoleTheme.Literate,restrictedToMinimumLevel:LogEventLevel.Information)
.WriteTo.File($"logs/log-{DateTime.Now:yyyy-MM-dd_HH:mm:ss.fff}.log")
.CreateLogger();
}