mirror of
https://github.com/Megghy/MegghysAPI.git
synced 2025-12-06 14:16:56 +08:00
添加项目文件。
This commit is contained in:
26
Datas.cs
Normal file
26
Datas.cs
Normal file
@@ -0,0 +1,26 @@
|
||||
using MegghysAPI.Attributes;
|
||||
|
||||
namespace MegghysAPI
|
||||
{
|
||||
public static class Datas
|
||||
{
|
||||
#if DEBUG
|
||||
public const bool IsDebug = true;
|
||||
#else
|
||||
public const bool IsDebug = false;
|
||||
#endif
|
||||
public const string HIBI_URL = "https://hibi.suki.club/";
|
||||
|
||||
public static string DataPath => Path.Combine(Environment.CurrentDirectory, "Data");
|
||||
public static string TempFilePath => Path.Combine(DataPath, "Temp");
|
||||
|
||||
[AutoInit]
|
||||
public static void Init()
|
||||
{
|
||||
if (!Directory.Exists(DataPath))
|
||||
Directory.CreateDirectory(DataPath);
|
||||
if (!Directory.Exists(TempFilePath))
|
||||
Directory.CreateDirectory(TempFilePath);
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user