Use the command line to package nuget and the command line to package nuget

Source: Internet
Author: User

Use the command line to package nuget and the command line to package nuget
We recommend that you use nuget Package Explorer to create Nuget packages that are not intended to be so complex. For the use of this graphic nuget package management software, you can search for related articles in the blog.

 

Well, back to the question. But we all know that the biggest problem with graphics isLow Automation.

% ~ Dp0nuget.exe pack % ~ Dp0Package. nuspec-OutputDirectory % ~ Dp0

% ~ Dp0 is the directory where the bat file is being executed is obtained.

In the end, it becomes like this:

Note: Once released, the packages on nuget cannot be deleted !! It can only be hidden. Therefore, make sure that the release is correct.

 

Here is the split line:

In the last step, we have already used batch processing, so there are more patterns to play with, for example, using PowerShell to automate the version of the package. There is an AssemblyVersion Attribute in AssemblyInfo. cs of the Project. Then we can use PowerShell to read the version number first, modify the version node in the nuspec file, and generate the package. As a matter of fact, I have already done so. Since I have never learned PowerShell, I will not lose face to that piece of code. You can think differently and expect to see the bag released by yuanyou on nuget.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.