From 6b07b08027d597f0164c933911a2d13454472268 Mon Sep 17 00:00:00 2001 From: Kooimanc Date: Tue, 12 Oct 2021 10:16:20 +0200 Subject: [PATCH] Use titleCase appname as solutionname And remove Class1 from wiring. --- kickstart.ps1 | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/kickstart.ps1 b/kickstart.ps1 index 4a8d1e6..b6aea41 100644 --- a/kickstart.ps1 +++ b/kickstart.ps1 @@ -1,8 +1,9 @@ $AppName = Read-Host -Prompt 'Input your project (folder) name' $TargetFolder="../$AppName" +$AppNameTitleCase = (Get-Culture).TextInfo.ToTitleCase($AppName) #$path = Get-Location #$newPath = Join-Path -Path $path -ChildPath $TargetFolder -Write-Host "Creating a new project '$AppName' in '$TargetFolder'" +Write-Host "Creating a new project '$AppNameTitleCase' in '$TargetFolder'" $confirmation = Read-Host "Are you sure you want to proceed? [y/N]" if ($confirmation -ne 'y') { Write-Host "Closing.." @@ -13,7 +14,7 @@ New-Item -ItemType Directory -Force -Path $TargetFolder Push-Location $TargetFolder git init # solution -dotnet new sln -n Solution +dotnet new sln -n $AppNameTitleCase dotnet new gitignore dotnet new globaljson dotnet new nugetconfig @@ -59,6 +60,7 @@ Copy-Item -Path "files/Wiring.cs" -Destination "$TargetFolder/Wiring" Remove-Item "$TargetFolder/Domain/Class1.cs" -ErrorAction Ignore Remove-Item "$TargetFolder/Domain.Tests/Class1.cs" -ErrorAction Ignore Remove-Item "$TargetFolder/Adapters/Class1.cs" -ErrorAction Ignore +Remove-Item "$TargetFolder/Wiring/Class1.cs" -ErrorAction Ignore #if (Test-Path $FileName) #{