CI / Go Backend (push) Canceled after 0s
初始化 monorepo: Go后端(7微服务) + Unity客户端(9模块) + 启动器 HTML5原型: Three.js 3D体素世界, Perlin噪声地形, 原版材质, 22种方块 Minecraft创造模式背包: 双栏布局, 拖拽移动物品, 方向性元件引脚 AI助搭策划文档 + 客户端/服务端骨架 + Docker Compose + CI
44 lines
1.6 KiB
C#
44 lines
1.6 KiB
C#
using PCL.Core.Utils.Exts;
|
|
using PCL.Core.Utils.OS;
|
|
|
|
namespace PCL.Core.App;
|
|
|
|
// ReSharper disable InconsistentNaming
|
|
public static class Secrets
|
|
{
|
|
/// <summary>
|
|
/// 微软 OAuth 的 Client ID
|
|
/// </summary>
|
|
public static string MSOAuthClientId { get; } = EnvironmentInterop.GetSecret("MS_CLIENT_ID", readEnvDebugOnly: true).ReplaceNullOrEmpty();
|
|
|
|
/// <summary>
|
|
/// CurseForge API 的 Client ID
|
|
/// </summary>
|
|
public static string CurseForgeAPIKey { get; } = EnvironmentInterop.GetSecret("CURSEFORGE_API_KEY", readEnvDebugOnly: true).ReplaceNullOrEmpty();
|
|
|
|
/// <summary>
|
|
/// 遥测密钥
|
|
/// </summary>
|
|
public static string TelemetryKey { get; } = EnvironmentInterop.GetSecret("TELEMETRY_KEY", readEnvDebugOnly: true).ReplaceNullOrEmpty();
|
|
|
|
/// <summary>
|
|
/// Natayark ID OAuth 的 Client ID
|
|
/// </summary>
|
|
public static string NatayarkClientId { get; } = EnvironmentInterop.GetSecret("NAID_CLIENT_ID", readEnvDebugOnly: true).ReplaceNullOrEmpty();
|
|
|
|
/// <summary>
|
|
/// Natayark ID OAuth 的 Client ID
|
|
/// </summary>
|
|
public static string NatayarkClientSecret { get; } = EnvironmentInterop.GetSecret("NAID_CLIENT_SECRET", readEnvDebugOnly: true).ReplaceNullOrEmpty();
|
|
|
|
/// <summary>
|
|
/// 联机根服务器
|
|
/// </summary>
|
|
public static string[] LinkServers { get; } = EnvironmentInterop.GetSecret("LINK_SERVER_ROOT", readEnvDebugOnly: true).ReplaceNullOrEmpty().Split("|");
|
|
|
|
/// <summary>
|
|
/// 当前版本的 Git 提交 SHA
|
|
/// </summary>
|
|
public static string CommitHash { get; } = EnvironmentInterop.GetSecret("GITHUB_SHA", readEnvDebugOnly: true).ReplaceNullOrEmpty();
|
|
}
|