DEV Community

Sugumar
Sugumar

Posted on

day 1 project

0) Preparation – tools you need

  1. Install .NET 10 SDK (or ask: “Which .NET SDK version should I use?”).
  2. Install Git.
  3. Install an editor (VS Code or Visual Studio).
  4. Create a GitHub account (if repo will be pushed).

Ask: “Which IDE do you prefer I use? (VS Code / Visual Studio)”
Expected: .NET works (dotnet --version returns a number like 7.x or 8.x or 10.x).


1) Create main folder for the solution

Do:

mkdir AccountingSuite
cd AccountingSuite
mkdir src tests
Enter fullscreen mode Exit fullscreen mode

What you should see: folders src/ and tests/.
Ask if unsure: “Do we keep tests now or add later?” or “Where should I save the repo on my PC?”


2) Create the projects (copy-paste commands)

In AccountingSuite/src run:

cd src

dotnet new webapi -n Accounting.API
dotnet new blazorwasm -n Accounting.UI
dotnet new classlib -n Accounting.Domain
dotnet new classlib -n Accounting.Infrastructure
dotnet new classlib -n Accounting.Shared
Enter fullscreen mode Exit fullscreen mode

What you should see: each project folder created with files (e.g. Accounting.API/Program.cs).
Ask: “Do we want Blazor WASM or Blazor Hybrid?” (developer will tell which UI type for the company).


3) Create the solution file and add projects

Do:

cd ..
dotnet new sln -n AccountingSuite
dotnet sln AccountingSuite.sln add src/Accounting.API/Accounting.API.csproj
dotnet sln AccountingSuite.sln add src/Accounting.UI/Accounting.UI.csproj
dotnet sln AccountingSuite.sln add src/Accounting.Domain/Accounting.Domain.csproj
dotnet sln AccountingSuite.sln add src/Accounting.Infrastructure/Accounting.Infrastructure.csproj
dotnet sln AccountingSuite.sln add src/Accounting.Shared/Accounting.Shared.csproj
Enter fullscreen mode Exit fullscreen mode

What you should see: solution file AccountingSuite.sln with projects added.
Ask: “Do we use one solution or multiple solutions?” (some teams split service solutions).


4) Add project references (connect projects)

In src:

cd src

dotnet add Accounting.API/Accounting.API.csproj reference Accounting.Domain/Accounting.Domain.csproj
dotnet add Accounting.API/Accounting.API.csproj reference Accounting.Infrastructure/Accounting.Infrastructure.csproj
dotnet add Accounting.API/Accounting.API.csproj reference Accounting.Shared/Accounting.Shared.csproj

dotnet add Accounting.Infrastructure/Accounting.Infrastructure.csproj reference Accounting.Domain/Accounting.Domain.csproj
dotnet add Accounting.Infrastructure/Accounting.Infrastructure.csproj reference Accounting.Shared/Accounting.Shared.csproj

dotnet add Accounting.UI/Accounting.UI.csproj reference Accounting.Shared/Accounting.Shared.csproj
Enter fullscreen mode Exit fullscreen mode

What you should see: no errors; each command finishes quickly.
Ask: “Should domain have DTOs or only entities?” or “Where will common DTOs live?” (team decides Shared vs API).


5) Add base folders inside each project (create structure)

Create folders (you can create with Explorer or terminal). Example:

src/Accounting.Domain/Entities
src/Accounting.Domain/Enums
src/Accounting.Domain/Interfaces

src/Accounting.Infrastructure/Data
src/Accounting.Infrastructure/Repositories
src/Accounting.Infrastructure/Migrations

src/Accounting.API/Controllers
src/Accounting.API/Services
src/Accounting.API/Helpers
src/Accounting.API/Middlewares

src/Accounting.Shared/DTOs
src/Accounting.Shared/Responses
src/Accounting.Shared/Constants
Enter fullscreen mode Exit fullscreen mode

What you should see: folders appear in the project.
Ask: “Any naming conventions for folders/classes?” (companies often have standards).


6) Open solution in IDE and build

Do:

# from repo root
code .   # opens VS Code (or open in Visual Studio)
dotnet build
Enter fullscreen mode Exit fullscreen mode

What you should see: Build success. If errors, copy the first error message.
Ask: “When I build, I get X error — what is the recommended fix?” (paste error to team).


7) Add Swagger and CORS to API (quick test)

Edit Program.cs in Accounting.API:

Add these lines in builder setup (copy to appropriate places):

// register
builder.Services.AddEndpointsApiExplorer();
builder.Services.AddSwaggerGen();

builder.Services.AddCors(options =>
{
    options.AddPolicy("AllowAll", p => p.AllowAnyOrigin().AllowAnyHeader().AllowAnyMethod());
});
Enter fullscreen mode Exit fullscreen mode

Then in app pipeline:

app.UseCors("AllowAll");
app.UseSwagger();
app.UseSwaggerUI();
Enter fullscreen mode Exit fullscreen mode

Run:

cd src/Accounting.API
dotnet run
Enter fullscreen mode Exit fullscreen mode

Open browser: https://localhost:5001/swagger (or the URL shown).
What you should see: Swagger UI listing endpoints (initially only default weather or none).
Ask: “On my machine Swagger URL is different — which URL should I use?” or “Do we need HTTPS in dev?”


8) Initialize Git and first commit

Do:

git init
git add .
git commit -m "Day1 - initial clean architecture setup"
Enter fullscreen mode Exit fullscreen mode

If pushing to GitHub (you can use GitHub CLI):

gh repo create AccountingSuite --public --source=. --remote=origin
git push -u origin main
Enter fullscreen mode Exit fullscreen mode

What you should see: repo created and code pushed.
Ask: “Which branch naming do we use? (main / develop)”, “Where is remote origin URL?” or “Do we add a CODEOWNERS file?”


9) Small tests & sanity checks

  • Open Accounting.API in browser and see Swagger.
  • In IDE, create a simple Controller to check compile:

Example Controllers/HealthController.cs:

[ApiController]
[Route("api/[controller]")]
public class HealthController : ControllerBase
{
    [HttpGet]
    public IActionResult Get() => Ok(new { status = "up" });
}
Enter fullscreen mode Exit fullscreen mode

Call GET /api/health in Swagger or Postman. Expect {"status":"up"}.
Ask: “Should I add logging format or use company logging library?”


10) What to ask at each step — short checklist (copy to your notes)

  • Tools: “Which .NET version, IDE, and code style do we use?”
  • Projects: “Is this project structure correct?”
  • References: “Where should shared DTOs live?”
  • Namespaces: “Project naming convention?”
  • Git: “Repo visibility (public/private)? Branch strategy?”
  • Dev URLs: “Local ports to use, HTTPS on/off?”
  • CI: “Do we set up CI (GitHub Actions) now or later?”
  • Database: “Which DB (SQL Server)? connection string, seeding rules?”
  • Secrets: “How to store secrets? (user secrets / Azure Key Vault?)”

11) Common beginner errors & quick fixes

  • dotnet: command not found → .NET not installed or PATH issue. Ask: “Where to download .NET SDK?”
  • No project was found when running dotnet ef → run from project folder or add --project option.
  • Build errors because namespaces mismatch → open file and correct namespace to match folder/project.
  • Git push permission error → ensure SSH key or GitHub CLI authenticated.

12) Final Day-1 checklist (tick them off)

  • [ ] Folder structure created
  • [ ] Projects created with dotnet new
  • [ ] Solution file created and projects added
  • [ ] Project references wired
  • [ ] Base folders in each project created
  • [ ] Build runs without errors
  • [ ] Swagger + CORS tested (Health endpoint OK)
  • [ ] Git repo initialized + first commit (pushed to remote)
  • [ ] Opened PR or sent message to team: “Day 1 done — can you review?”

Ask the team: “Please review structure and confirm before I start Day 2 (DB design).”


If you want, I can now:

  • produce the exact HealthController file and Program.cs snippet ready to paste,
  • OR produce a Day 1 checklist file (README.md) content that you can copy into the repo.

Which one do you want me to give you now? (I’ll paste the code / README directly.)

Top comments (0)