FnPack.MSBuild
1.0.3
dotnet add package FnPack.MSBuild --version 1.0.3
NuGet\Install-Package FnPack.MSBuild -Version 1.0.3
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="FnPack.MSBuild" Version="1.0.3" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="FnPack.MSBuild" Version="1.0.3" />
<PackageReference Include="FnPack.MSBuild" />
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add FnPack.MSBuild --version 1.0.3
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
#r "nuget: FnPack.MSBuild, 1.0.3"
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package FnPack.MSBuild@1.0.3
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=FnPack.MSBuild&version=1.0.3
#tool nuget:?package=FnPack.MSBuild&version=1.0.3
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
FnPack.MSBuild
将 .NET 发布产物自动打包为飞牛应用的 MSBuild 任务。安装后在 Publish 之后自动把发布产物打包成 .fpk。
快速开始
准备飞牛应用目录(含
manifest、cmd、config等)。在项目文件中指定应用目录和版本号:
<PropertyGroup> <PackageVersion>1.0.0</PackageVersion> <FnPackAppDir>$(MSBuildProjectDirectory)/fpk</FnPackAppDir> </PropertyGroup> <ItemGroup> <PackageReference Include="FnPack.MSBuild" Version="1.0.0" PrivateAssets="all" /> </ItemGroup>正常发布即可:
dotnet publish -c Release发布成功后在 publish 目录下自动生成
<appname>-x86.fpk或<appname>-arm.fpk(仅linux-x64/linux-arm64发布时打包)。
属性
| 属性 | 必填 | 说明 |
|---|---|---|
FnPackAppDir |
是 | 飞牛应用模板目录,包含 manifest、cmd、config 等 |
FnPackServerDir |
否 | 发布产物填充目录,默认 $(PublishDir)fnpack/app/server |
FnPackOutputDir |
否 | 飞牛应用输出目录,默认 $(PublishDir) |
FnPackSkipBuild |
否 | 设为 true 时跳过 PackFpk,不复制发布产物也不生成 fpk |
PackageVersion |
否 | 写入 manifest 的 version 字段,默认 1.0.0 |
支持平台
支持 win-x64、linux-x64、linux-arm64、osx-x64、osx-arm64。
相关链接
完整说明见 GitHub 仓库。
There are no supported framework assets in this package.
Learn more about Target Frameworks and .NET Standard.
This package has no dependencies.
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.