Dotnet CLI Komutları
  • Giriş
  • Genel Komutlar
    • dotnet
    • dotnet help
    • dotnet sdk check
  • Yüklü Proje Şablonları ile Proje Oluşturma Komutları
    • dotnet new sln
    • dotnet new classlib
    • dotnet new console
    • dotnet new web
    • dotnet new mvc
    • dotnet new webapi
    • dotnet new react
    • dotnet new angular
    • dotnet new grpc
    • dotnet new nunit
    • dotnet new xunit
    • dotnet new mstest
    • dotnet new gitignore
    • dotnet new globaljson
  • Proje Şablon İşlemleri için Komutlar
    • dotnet new list
    • dotnet new search
    • dotnet new install
    • dotnet new uninstall
    • dotnet new update
  • Proje Genel İşlemler için Komutlar
    • dotnet build
    • dotnet clean
    • dotnet publish
    • dotnet run
  • Çözüm (Solution) İşlemleri için Komutlar
    • dotnet sln add
    • dotnet sln remove
    • dotnet sln list
  • Proje Paket İşlemleri Komutları
    • dotnet add package
    • dotnet remove package
    • dotnet list package
  • Projeler Arası Referans Tanımlama Komutları
    • dotnet add reference
    • dotnet remove reference
    • dotnet list reference
  • Proje Sertifika Komutları
    • dotnet dev-certs https
  • Proje Test Komutları
    • dotnet test
  • Dotnet Araçları Genel Komutları
    • dotnet tool list
    • dotnet tool run
    • dotnet tool search
    • dotnet tool install
    • dotnet tool uninstall
    • dotnet tool update
  • Dotnet Code Generator Komutları
    • dotnet aspnet-codegenerator area
    • dotnet aspnet-codegenerator controller
    • dotnet aspnet-codegenerator view
  • Entity Framework Core Migrasyon Komutları
    • dotnet ef migrations add
    • dotnet ef migrations bundle
    • dotnet ef migrations list
    • dotnet ef migrations remove
    • dotnet ef migrations script
  • Entity Framework Core Veritabanı Komutları
    • dotnet ef database update
    • dotnet ef database drop
  • Entity Framework Core DbContext Komutları
    • dotnet ef dbcontext info
    • dotnet ef dbcontext list
    • dotnet ef dbcontext optimize
    • dotnet ef dbcontext scaffold
    • dotnet ef dbcontext script
Powered by GitBook
On this page
  • dotnet aspnet-codegenerator view --help
  • dotnet aspnet-codegenerator view <view_name> <view_template_name> --relativeFolderPath <output_folder_path> --useDefaultLayout
  1. Dotnet Code Generator Komutları

dotnet aspnet-codegenerator view

dotnet aspnet-codegenerator view --help

eg@debian:/media/eg/data/DotnetCliExamples/ExampleSolution/ExampleSolution.Mvc1$ dotnet aspnet-codegenerator view --help


Usage: aspnet-codegenerator [arguments] [options]

Arguments:
  generator  Name of the generator. Check available generators below.

Options:
  -p|--project             Path to .csproj file in the project.
  -n|--nuget-package-dir   
  -c|--configuration       Configuration for the project (Possible values: Debug/ Release)
  -tfm|--target-framework  Target Framework to use. (Short folder name of the tfm. eg. net46)
  -b|--build-base-path     
  --no-build               

Selected Code Generator: view

Generator Arguments:
  viewName     : Name of the view
  templateName : The view template to use, supported view templates: 'Empty|Create|Edit|Delete|Details|List'

Generator Options:
  --model|-m                          : Model class to use
  --dataContext|-dc                   : DbContext class to use
  --referenceScriptLibraries|-scripts : Switch to specify whether to reference script libraries in the generated views
  --layout|-l                         : Custom Layout page to use
  --useDefaultLayout|-udl             : Switch to specify that default layout should be used for the views
  --force|-f                          : Use this option to overwrite existing files
  --relativeFolderPath|-outDir        : Specify the relative output folder path from project where the file needs to be generated, if not specified, file will be generated in the project folder
  --controllerNamespace|-namespace    : Specify the name of the namespace to use for the generated controller
  --partialView|-partial              : Generate a partial view, other layout options (-l and -udl) are ignored if this is specified
  --databaseProvider|-dbProvider      : Database provider to use. Options include 'sqlserver' (default), 'sqlite', 'cosmos', 'postgres'.
  --useSqLite|-sqlite                 : Flag to specify if DbContext should use SQLite instead of SQL Server.


RunTime 00:00:00.97

dotnet aspnet-codegenerator view <view_name> <view_template_name> --relativeFolderPath <output_folder_path> --useDefaultLayout

eg@debian:/media/eg/data/DotnetCliExamples/ExampleSolution/ExampleSolution.Mvc1$ dotnet aspnet-codegenerator view Index Empty --relativeFolderPath Views/User --useDefaultLayout
Building project ...
Finding the generator 'view'...
Running the generator 'view'...
Added View : /Views/User/Index.cshtml
RunTime 00:00:03.36
Previousdotnet aspnet-codegenerator controllerNextEntity Framework Core Migrasyon Komutları

Last updated 1 year ago