امکان ساخت قالب برای پروژههای NET Core.
نویسنده: وحید نصیری
تاریخ: ۱۳۹۶/۰۵/۱۶ ۱۳:۳۵
آدرس: www.dntips.ir
| مطالب | ۳۶۹۴ |
| نویسندگان | ۲۷۶ |
| گروههای مطالب | ۱۰۲۴ |
| نقشههای راه | ۱۱۹ |
| دورهها | ۱۴ |
| اشتراکها | ۱۷۹۱۴ |
{
"author": "VahidN <https://www.dntips.ir/>",
"classifications": [ "MVC", ".NET Core", "ASP.NET Core" ],
"name": "Empty DNT.Identity project",
"identity": "DNT.Identity",
"shortName": "dntidentity",
"tags": {
"language": "C#"
},
"sourceName": "ASPNETCoreIdentitySample"
} dotnet new -i %~dp0
dotnet new --list
Templates Short Name Language Tags --------------------------------------------------------------------------------------------------------------- Console Application console [C#], F#, VB Common/Console Class library classlib [C#], F#, VB Common/Library Empty DNT.Identity project dntidentity [C#] MVC/.NET Core/ASP.NET Core
dotnet new dntidentity -n MyNewProj
و سوال بعدی که خدمتتون داشتم این بود که آیا میتونیم همین پروژه تمپلیتمون رو به صورت مستقیم با خود ویژوال استادیو اضافه کنیم با new project
dotnet new -i %~dp0
C:\Projects\DNTIdentity-master>dotnet new -i %~dp0 Restoring packages for C:\Users\Marjani\.templateengine\dotnetcli\v2.1.300\scratch\restore.csproj... C:\Users\Marjani\.templateengine\dotnetcli\v2.1.300\scratch\restore.csproj : error NU1101: Unable to find package %~dp0. No packages exist with this id in source(s): C:\Program Files\dotnet\sdk\NuGetFallbackFolder, Microsoft Visual Studio Offline Packages, nuget.org Generating MSBuild file C:\Users\Marjani\.templateengine\dotnetcli\v2.1.300\scratch\obj\restore.csproj.nuget.g.props. Generating MSBuild file C:\Users\Marjani\.templateengine\dotnetcli\v2.1.300\scratch\obj\restore.csproj.nuget.g.targets. Restore failed in 1.95 sec for C:\Users\Marjani\.templateengine\dotnetcli\v2.1.300\scratch\restore.csproj.
dotnet new -i C:\Projects\DNTIdentity-master
dotnet new -u <NUGET_PACKAGE_ID> dotnet new -u <ABSOLUTE_Path to template.config folder>
با سلام پس از نصب قالب و اجرای دستور dotnet new dntidentity -n StodioHAFT اروری که در عکس میبینید رو مشاهده میکنم
این تصویر که با دایره قرمز هم مشخص شده،
dotnet new somename --framework net5.0
{
"author": "Firstname and lastname",
"classifications": [ ".Net core", "AspNetCore" ],
"name": "Base project",
"identity": "BaseProject",
"shortName": "baseproject",
"tags": {
"language": "C#"
},
"sourceName": "DotnetCoreSample",
"preferNameDirectory": true // Here
}