Skip to content
This repository was archived by the owner on Dec 5, 2024. It is now read-only.

Commit 4ed7ac1

Browse files
Temporarily hard coding the startup log path
1 parent 5f2d932 commit 4ed7ac1

File tree

2 files changed

+13
-2
lines changed

2 files changed

+13
-2
lines changed

src/GitHub.Api/DefaultEnvironment.cs

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,17 @@ public static NPath LogPath
1818
}
1919
}
2020

21+
private const string startupLogFile = "github-unity-startup.log";
22+
public static NPath StartupLogPath
23+
{
24+
get
25+
{
26+
return Environment.GetFolderPath(Environment.SpecialFolder.LocalApplicationData)
27+
.ToNPath()
28+
.Combine(ApplicationInfo.ApplicationName, startupLogFile);
29+
}
30+
}
31+
2132
public string GetSpecialFolder(Environment.SpecialFolder folder)
2233
{
2334
return Environment.GetFolderPath(folder);

src/UnityExtension/Assets/Editor/GitHub.Unity/EntryPoint.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,9 +23,9 @@ static EntryPoint()
2323
return;
2424
}
2525

26-
var logPath = DefaultEnvironment.LogPath;
26+
var startupLogPath = DefaultEnvironment.StartupLogPath;
2727

28-
Logging.LoggerFactory = s => new FileLogAdapter(logPath.FileNameWithoutExtension + "-startup" + logPath.ExtensionWithDot, s);
28+
Logging.LoggerFactory = s => new FileLogAdapter(startupLogPath, s);
2929

3030
ServicePointManager.ServerCertificateValidationCallback = ServerCertificateValidationCallback;
3131
EditorApplication.update += Initialize;

0 commit comments

Comments
 (0)