cs2-web/Program.cs
2026-07-07 20:23:39 +03:00

16 lines
520 B
C#

using CsWeb.Services;
var builder = WebApplication.CreateBuilder(args);
builder.Services.AddRazorPages();
builder.Services.AddSingleton<Fleet>();
builder.Services.AddSingleton<Weapons>();
var app = builder.Build();
app.UseStaticFiles();
app.MapRazorPages();
// Changelog is deliberately not a page: the Forgejo releases feed IS the changelog (one source of truth).
app.MapGet("/changelog", (IConfiguration cfg) =>
Results.Redirect(cfg["Outnumbered:ReleasesUrl"] ?? "/", permanent: false));
await app.RunAsync();