NeuCharFramework (NCF)
  • NCF - NeuCharFramework
  • Projects

    • Preparation
    • Basic Library Source Code Analysis
    • DynamicWebApiEngine
    • Deployment
  • Help

    • Online Resources
    • Q&A Community
    • QQ Group (147054579)
    • Senparc WeChat SDK
  • Gitee
  • GitHub
  • English
  • 简体中文
GitHub
  • NCF - NeuCharFramework
  • Projects

    • Preparation
    • Basic Library Source Code Analysis
    • DynamicWebApiEngine
    • Deployment
  • Help

    • Online Resources
    • Q&A Community
    • QQ Group (147054579)
    • Senparc WeChat SDK
  • Gitee
  • GitHub
  • English
  • 简体中文
GitHub
  • NCF Overview

    • NCF - NeuCharFramework
    • About NCF
    • Environment Requirements
    • Frontend and Backend Separation Mode
    • Introduction to Xncf Modules
  • Prepare Development

    • Get NCF Template Source Code
    • Using Visual Studio to Run NCF
    • Running NCF Using CLI
    • Installation
    • Admin Login
    • Admin Backend
    • appsettings.json Configuration
    • Module Management
    • Accessing Documentation
  • Configuration

    • Entry File
    • Database Settings
    • appsettings.json Configuration
    • Docker
    • Dapr
    • Configure Multi-Tenant
    • Redis Cache
  • Modular Development

    • NCF Modular Development Concept
    • Composition of Xncf
    • Create the First Xncf Module
    • Xncf Module Sample Detailed Explanation
    • Implement Your Own Business Logic
    • Update Xncf Module
    • How to Call Between Modules
    • Publish Xncf Module to nuget.org
    • Update Base Library
    • Xncf Module Development
    • Embedding Static Resource Files into NCF
    • Publish Local Nuget Package
    • Advanced
  • Database

    • Database Settings
    • Multi-Database Support
    • Specify Database
    • Update database migration files for the Senparc.Service project (Migrations)
    • Multi-Database Principle
    • DatabasePlant
    • Tarmac Operation Database Migration and Update
  • Unit Testing

    • NCF Unit Test Introduction
    • Start Development
    • Advanced
    • Appendix
  • Q&A

    • NCF Terminology
    • NCF FAQ
  • Release

    • New Features
    • Upgrade Guide
    • Logs

Publish Local Nuget Package

  1. Open project properties

Image text

  1. Set project package release options, check the option to create nuget file on build

Image text

  1. Edit project file

Image text

  1. Edit the conditions and necessary parameters for generating the Nuget file
    <Project Sdk="Microsoft.NET.Sdk">
      <PropertyGroup>
        <TargetFramework>netcoreapp3.1</TargetFramework>
        <Version>1.0</Version>
        <AssemblyName>Senparc.Xncf.Application</AssemblyName>
        <RootNamespace>Senparc.Xncf.Application</RootNamespace>
        <GeneratePackageOnBuild Condition=" '$(Configuration)' == 'Release' ">true</GeneratePackageOnBuild>
        <Description>Application module</Description>
        <Copyright>Senparc</Copyright>
        <PackageTags>Senparc,NeuCharFramework,NCF,Senparc.Xncf.Application</PackageTags>
        <Authors>Senparc</Authors>
        <Owners>Senparc</Owners>
        <!-- <PackageLicenseUrl>https://github.com/NeuCharFramework/NcfPackageSources/blob/master/LICENSE</PackageLicenseUrl> -->
        <Title>.Application module</Title>
        <!--<ProjectUrl> https://github.com/NeuCharFramework/NCF</ProjectUrl>
        <PackageProjectUrl>https://github.com/NeuCharFramework/NcfPackageSources</PackageProjectUrl>
        <PackageIconUrl>http://sdk.weixin.senparc.com/Images/logo-square-ncf.jpg</PackageIconUrl>-->
        <PackageReleaseNotes>
          v1.0 Genesis
        </PackageReleaseNotes>
        <RepositoryUrl> https://github.com/NeuCharFramework/NcfPackageSources</RepositoryUrl>
        <Configurations>Debug;Release;Test</Configurations>
      </PropertyGroup>
      <PropertyGroup Condition=" '$(Configuration)' == 'Release' ">
        <OutputPath>..\..\..\BuildOutPut</OutputPath>
        <DocumentationFile>..\..\..\BuildOutPut\Senparc.Xncf.Application.XML</DocumentationFile>
        <DefineConstants>$(DefineConstants);RELEASE</DefineConstants>
        <Optimize>true</Optimize>
        <DebugType>pdbonly</DebugType>
        <ErrorReport>prompt</ErrorReport>
        <CodeAnalysisRuleSet>MinimumRecommendedRules.ruleset</CodeAnalysisRuleSet>
      </PropertyGroup>
      <ItemGroup>
        <PackageReference Include="Senparc.Ncf.XncfBase" Version="0.3.500-beta1" />
        <ProjectReference Include="..\Senparc.Core\Senparc.Core.csproj" />
        <ProjectReference Include="..\Senparc.Service\Senparc.Service.csproj" />
      </ItemGroup>

        <ItemGroup>
        <PackageReference Include="Microsoft.EntityFrameworkCore.SqlServer" Version="3.1.6" />
        <PackageReference Include="Microsoft.EntityFrameworkCore.SqlServer.Design" Version="2.0.0-preview1-final" />
        <PackageReference Include="Microsoft.EntityFrameworkCore.Tools" Version="3.1.6">
          <PrivateAssets>all</PrivateAssets>
          <IncludeAssets>runtime; build; native; contentfiles; analyzers</IncludeAssets>
        </PackageReference>
    </ItemGroup>

    </Project>
  1. Rebuild the project

Image text

  1. Find the generated Nuget package (here using the Debug environment, so it is generated in the Debug directory)

Image text

  1. Copy the local Nuget package to the specified file directory (for easy reference)

Image text

Referencing Local Nuget Source

  1. There are two ways to enter the source settings

1-1. Click the toolbar Tools->Options->Nuget Package Manager

Image text

1-2. Right-click the project

Image text

Image text

Image text

  1. Add nuget source

Image text

Image text

  1. Select the local nuget source

Image text

  1. Import the local nuget source

Image text

Image text

  1. Rebuild the project
  1. Effect display

Image text

Image text

Image text

Image text

Edit this page on GitHub
Last Updated:
Contributors: Jeffrey Su
Prev
Embedding Static Resource Files into NCF
Next
Advanced