feat: 新增yi-abp nuget脚手架,待正式版上传

This commit is contained in:
橙子
2024-06-01 21:45:20 +08:00
parent a2d9326826
commit 0d6b62c8e7
6 changed files with 108 additions and 0 deletions

View File

@@ -0,0 +1,45 @@
using System.Reflection;
using Microsoft.Extensions.DependencyInjection;
using Microsoft.Extensions.Hosting;
using Yi.Abp.Tool;
class Program
{
static void Main(string[] args)
{
try
{
IHost host = Host.CreateDefaultBuilder()
.ConfigureServices(async (host, service) =>
{
await service.AddApplicationAsync<YiAbpToolModule>();
})
.UseAutofac()
.Build();
}
catch (Exception ex)
{
Console.WriteLine(ex.Message);
Console.WriteLine(ex.StackTrace);
}
if (args.Contains("-v"))
{
var version = Assembly.GetEntryAssembly().GetCustomAttribute<AssemblyInformationalVersionAttribute>().InformationalVersion;
Console.WriteLine($"Yi-ABP CLI {version}");
}
else
{
Console.WriteLine("""
Usage:
yi-abp <command> <target> [options]
Command List:
""");
}
}
}

View File

@@ -0,0 +1,31 @@
<Project Sdk="Microsoft.NET.Sdk">
<Import Project="..\..\common.props" />
<PropertyGroup>
<OutputType>Exe</OutputType>
<TargetFramework>net8.0</TargetFramework>
<ImplicitUsings>enable</ImplicitUsings>
<Nullable>enable</Nullable>
<Version>0.1.0</Version>
<Authors>橙子老哥</Authors>
<Description>yi-framework框架配套工具</Description>
<PackageProjectUrl>https://ccnetcore.com</PackageProjectUrl>
<RepositoryType>git</RepositoryType>
<RepositoryUrl>https://gitee.com/ccnetcore/Yi</RepositoryUrl>
<PackageTags>abp;yi</PackageTags>
<PackAsTool>True</PackAsTool>
<ToolCommandName>yi-abp</ToolCommandName>
<PackageOutputPath>./nupkg</PackageOutputPath>
<PackageIcon>logo.png</PackageIcon>
</PropertyGroup>
<ItemGroup>
<None Include="..\..\logo.png">
<Pack>True</Pack>
<PackagePath>\</PackagePath>
</None>
</ItemGroup>
<ItemGroup>
<PackageReference Include="Volo.Abp.Autofac" Version="$(AbpVersion)" />
</ItemGroup>
</Project>

View File

@@ -0,0 +1,12 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace Yi.Abp.Tool
{
public class YiAbpToolModule : AbpModule
{
}
}