Tuesday 12 April 2016

Visual Studio Nuget package manager console short cut


List of question related to nuget package manager.


1. Short cut key to get name of the command.
Ans. If you want to find any command using package manager console just press Tab button and you can see the list.

2. How to open package manager console?
Ans. Go to the package console manager using right click on the project in the solution explore and click on “Manage NuGet Packages” or from the “Tool” menu select “NuGet Package Manager” or “Library Package Manager” and then click “Package manager console”.

3. How to find package using console?
Ans. Using Get-Package and name of the package,
You can also search –ListAvailable to get the list of packages from NuGet.

4. How to install package using console?
Ans. Using Install-Package and name of the package, you got message to console “Successfully installed ‘EntityFramework 6.1.1” and “Successfully added ‘EntityFramework 6.1.1 to YourApplication”.

5. How to update installed packages?
Ans. First type Get-Package –Updates command to check whether any newer version is available for any installed packages.
Now if there are any packages to available for updates “Update-Package and name of the package.

6. How to Uninstall package?
Ans. If you don’t already know the name of package you want to remove.
Type “Get-Package”, at prompt without any flag to see a list of all installed packages.
To remove a package, use Uninstall –Package command with the name of package.



For more option or information you can type get –help command to get list of commands.

No comments:

Post a Comment