Skip to content

Commit a4bade2

Browse files
committed
Use temporary directory for logs if not specified
1 parent 1b824f1 commit a4bade2

File tree

1 file changed

+1
-4
lines changed

1 file changed

+1
-4
lines changed

src/PowerShellEditorServices.Hosting/Commands/StartEditorServicesCommand.cs

+1-4
Original file line numberDiff line numberDiff line change
@@ -301,13 +301,10 @@ private string GetLogDirPath()
301301
string logDir = Path.GetDirectoryName(LogPath);
302302
if (string.IsNullOrEmpty(logDir))
303303
{
304-
logDir = Directory.GetCurrentDirectory();
305-
// Path.GetDirectoryName(Path.GetDirectoryName(Assembly.GetExecutingAssembly().Location));
304+
logDir = Path.Combine(Path.GetTempPath(), "PowerShellEditorServices");
306305
}
307306

308-
// Ensure logDir exists
309307
Directory.CreateDirectory(logDir);
310-
311308
return logDir;
312309
}
313310

0 commit comments

Comments
 (0)