Use the graphical interface to package your own class library

Source: Internet
Author: User

Use the graphical interface to package your own class library

NuGet can use NuGet.exe to package the class library at the command line, or it can be packaged using a graphical interface, and it's estimated that many of my friends are just as familiar with the unfamiliar command line as I am, so this is just about using the graphical interface for Class library packaging.

1. First download the Package Manager Nugetpackageexplorer, as the name implies, the package Manager can be used to create a new class library package, you can also browse the already created class library package

2. Once the download is complete, double-click the nugetpackageexplorer.application to install, and the installation will generate a NuGet package Explorer shortcut on the desktop

3. Double click on the NuGet Package Explorer to start the interface and select Create a new packages (CTRL + N)

4. Select Menu Editor > Edit Package Metadata (or CTRL + K)

Here you can edit the class library package information and add Class libraries, assembly references to explain the next few more important fields

ID: The unique identifier used to locate the class library package, such as executing install-package at the command line mypackage the mypackage here is the ID value of the package.

Version: The build number of the class library, where it is recommended to match the actual version number of the assembly to avoid confusion

Dependencies: This kind of library depends on the assembly, according to the actual situation to add the dependency class Library ID and version number, if there is no empty, it is important to note that the Dependent class library must be found on the NuGet server, or cannot complete the automatic reference add

Framework assemblies: Dependent framework assemblies, which can be selected according to actual needs, generally without setting

In addition to the above four other properties modified according to the actual situation, if you do not modify the same, but for the convenience of use or recommend the class library description (Description) fill in the

5. After editing the package information, add the DLL to the package

You can choose right-click-->add existinng File ... Select the DLL to add, or you can drag the DLL directly to the Package Contents window, this example select the drag-and-drop method

Drag the DLL directly to the window, you will see the prompt: whether to put the Winista.HtmlParser.dll in the Lib folder, the general we choose to be

6. After the DLL is added, the shortcut key CTRL + K to modify the package information ID is winista.htmlparser and the version number is 1.8.0

7. Once the information has been modified and the DLLs have been added, select File--save (or CTRL + S) to save the files, and the default file name is ID + version number. nupkg

8. After completing the save, if need to publish to the net, choose File--> Publish ... (or CTRL + P)

The default publishing address is the official website, release key to the official website to register an account, and then you can get, here is not retelling, if you do not need to publish a direct shutdown can

PS: Here does not tell how to package the project file, in general we will compile the project file into a DLL and then use the graphical interface packaging to meet the needs, if the actual work requires a high degree of integration of fully automated operation can be self-study under the official document http://docs.nuget.org/

Adding a DLL By default adds a Lib folder, The additional menu also has many. Net Folders, src and other folders, these folders just a physical partition on the file, just to help us do a good job of classifying files, no other use, DLL files can be placed casually, but in order to standardize or recommend to follow the usual habits to place.

Transferred from: http://kb.cnblogs.com/page/143191/

Use the graphical interface to package your own class library

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.