1 Create and Publish NuGet Package
Wade Wegner редактировал(а) эту страницу 2015-08-25 20:21:33 -07:00

This article describes how to build and publish the NuGet package.

  1. Increment the build numbers in the scripts\assets\*.nuspec files.

  2. Ensure that dependencies listed in *.nuspec files are consistent with NuGet packages used within the solution. Look at the packages.config files in each project.

  3. Run scripts\build.cmd and ensure everything builds properly.

  4. Run scripts\runtests.cmd and ensure all tests pass.

  5. Run scripts\package.cmd and ensure you have four *.nupkg files in \artifacts.

  6. Set your NuGet API key. You only need to do this once.

    • Browse to https://www.nuget.org/

    • Sign-in with your credentials.

    • Browse to your account.

    • Copy your API key to the clipboard.

    • Run this command in the command-line: nuget.exe setApiKey YOURAPIKEY

  7. Update publish-chatter.cmd and publish-force.cmd to use the latest NuGet packages.

  8. Run publish-chatter.cmd. Ensure that the packages are pushed to both the NuGet Gallery and the symbol server.

    $ publish-chatter.cmd
    Pushing DeveloperForce.Chatter 1.1.0 to the NuGet gallery (https://www.nuget.org)...
    Your package was pushed.
    Pushing DeveloperForce.Chatter 1.1.0 to the symbol server (http://nuget.gw.symbolsource.org/Public/NuGet)...
    Your package was pushed.
    Pushing DeveloperForce.Chatter 1.1.0 to the symbol server (http://nuget.gw.symbolsource.org/Public/NuGet)...
    Your package was pushed.
    
  9. Run publish-force.cmd. Ensure that the packages are pushed to both the NuGet Gallery and the symbol server.

    $ publish-force.cmd
    Pushing DeveloperForce.Force 1.1.0 to the NuGet gallery (https://www.nuget.org)...
    Your package was pushed.
    Pushing DeveloperForce.Force 1.1.0 to the symbol server (http://nuget.gw.symbolsource.org/Public/NuGet)...
    Your package was pushed.
    Pushing DeveloperForce.Force 1.1.0 to the symbol server (http://nuget.gw.symbolsource.org/Public/NuGet)...
    Your package was pushed.
    
  10. Check and ensure the latest NuGets have been published.

  11. Ideally test and make sure the latest NuGet packages work. ;-)

You're done!