personal-finance / rules
Cursor rule1 starsChanged todayMITView on GitHub
Personal Finance backend: read-only brokers, decimal money, module boundaries, migrations, and where this repo differs from the csharp pack rules
In this repository84 other files it gives its agents.
- AGENTS.mdAGENTS.md
- CLAUDE.mdCLAUDE.md
- .cursor/rules/angular-coding-style.mdcCursor rule
- .cursor/rules/angular-patterns.mdcCursor rule
- .cursor/rules/angular-security.mdcCursor rule
- .cursor/rules/angular-testing.mdcCursor rule
- .cursor/rules/common-code-review.mdcCursor rule
- .cursor/rules/common-coding-style.mdcCursor rule
- .cursor/rules/common-development-workflow.mdcCursor rule
- .cursor/rules/common-security.mdcCursor rule
- .cursor/rules/common-testing.mdcCursor rule
- .cursor/rules/csharp-coding-style.mdcCursor rule
- .cursor/rules/csharp-data-access.mdcCursor rule
- .cursor/rules/csharp-patterns.mdcCursor rule
- .cursor/rules/csharp-security.mdcCursor rule
- .cursor/rules/csharp-testing.mdcCursor rule
- .cursor/rules/design-design-system.mdcCursor rule
- .cursor/rules/project-security.mdcCursor rule
- .cursor/rules/project-testing.mdcCursor rule
- .cursor/rules/project-web.mdcCursor rule
- .cursor/rules/typescript-coding-style.mdcCursor rule
- .cursor/rules/typescript-patterns.mdcCursor rule
- .cursor/rules/typescript-security.mdcCursor rule
- .cursor/rules/typescript-testing.mdcCursor rule
- angular-guideSkill
- break-uiSkill
- dotnet-create-command-querySkill
- dotnet-create-entitySkill
- dotnet-create-moduleSkill
- dotnet-ef-migrationSkill
- emil-design-engSkill
- frontend-designSkill
- impeccableSkill
- review-animationsSkill
- speckit-analyzeSkill
- speckit-checklistSkill
- speckit-clarifySkill
- speckit-constitutionSkill
- speckit-convergeSkill
- speckit-implementSkill
- speckit-planSkill
- speckit-specifySkill
- speckit-tasksSkill
- ui-ux-pro-maxSkill
- angular-guideSkill
- break-uiSkill
- dotnet-create-command-querySkill
- dotnet-create-entitySkill
- dotnet-create-moduleSkill
- dotnet-ef-migrationSkill
- emil-design-engSkill
- frontend-designSkill
- impeccableSkill
- review-animationsSkill
- speckit-analyzeSkill
- speckit-checklistSkill
- speckit-clarifySkill
- speckit-constitutionSkill
- speckit-convergeSkill
- speckit-implementSkill
- The first 60 shown.
The file
Files
--- description: "Personal Finance backend: read-only brokers, decimal money, module boundaries, migrations, and where this repo differs from the csharp pack rules" globs: backend/**/*.cs,backend/**/*.csproj,backend/**/appsettings*.json,backend/Directory.*.props alwaysApply: false --- <!-- Generated by armature from .claude/rules/project/backend.md. Edit the source rule, not this file. --> # Backend (project rules) Binding source: [.specify/memory/constitution.md](../../.specify/memory/constitution.md), then [docs/architecture.md](../../docs/architecture.md) and the ADRs in `docs/adr/`. These rules win over the generic `csharp/` pack rules. A reviewer reports any break below as **CRITICAL**. ## Non-negotiable - **Read-only brokers** ([ADR-0005](../../docs/adr/0005-read-only-broker-integrations.md), [ADR-0009](../../docs/adr/0009-binance-read-only-key.md)). No code places orders, moves money or withdraws. Broker access goes only through `IInvestmentProvider` and the allow-list `DelegatingHandler` of read endpoints; a new endpoint is added to the allow-list, never around it. No method is named like a trading or money-movement operation (`PlaceOrder`, `Buy`, `Sell`, `Transfer`, `Withdraw`, `Deposit`, ...): `Architecture.Tests` fails the build. - **Money is `decimal`**, never `double`/`float`. The backend computes every figure; the web app only displays. - **Reporting never writes**: no `SaveChanges` in `Reporting`. - **No raw SQL** (`FromSqlRaw`, `ExecuteSqlRaw`, ...) in application code. - **Module boundaries** as in `docs/architecture.md`: `Finance.Domain` depends only on `SharedKernel`; application layers never reference Npgsql, infrastructure projects or a host. `Host.Mcp` references only the AI contracts, never the database. - **Schema change → EF Core migration** in the same change (`dotnet ef migrations add ...`). ## Where this repo differs from the csharp pack - **Feature slices, no mediator.** `*.Application` holds feature folders with request DTOs, validators, minimal-API endpoints (`*Endpoints.cs`) and queries that use the module's DbContext interface (e.g. `IFinanceDb`) directly. There is no MediatR/`ISender` and no `<Verb><Entity>Command`/`Query` naming requirement: follow the slice the change sits in. - **`var`** follows `.editorconfig` (`csharp_style_var_for_built_in_types = true`): `var` is fine for built-in types; match the surrounding code. - `Result`/`Error`, `YearMonth`, `Currency` and `DataSource` come from `SharedKernel`; reuse them. ## Commands ```bash cd backend && dotnet build cd backend && dotnet format --verify-no-changes --include <files you changed> # the whole solution is not clean yet cd backend && dotnet test --project tests/<Module>.Tests # Integration.Tests need Docker ```
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

