简体   繁体   English

列出程序包管理器控制台中的可用CmdLets

[英]List available CmdLets in Package Manager Console

In the package manager console, is it possible to get a list of available cmdlets? 在包管理器控制台中,是否可以获取可用cmdlet的列表?

For example, I installed the Entity Framework package and I want to play around with migrations. 例如,我安装了Entity Framework包,我想玩游戏。 I know the commands Enable-Migrations , Add-Migration , and Update-Database , however I want to play with rollbacks but I didn't know the cmdlet to call. 我知道命令Enable-MigrationsAdd-MigrationUpdate-Database ,但我想使用回滚但我不知道要调用的cmdlet。

I just want a way to list all available cmdlets in the current context, and if possible a short description of what each does. 我只想要一种方法来列出当前上下文中的所有可用cmdlet,如果可能的话,还可以简要描述每个cmdlet的功能。

edit: 编辑:

I know how to do a rollback, it was just a story to explain why getting a list of cmdlets would be useful. 我知道如何进行回滚,这只是一个故事,可以解释为什么获取cmdlet列表会很有用。

Get-Command -CommandType Cmdlet

You can use: 您可以使用:

Get-Command -CommandType Cmdlet | Get-Help | select name,synopsis | fl

to get your description of what the cmdlet does .However, piping to Get-Help seems very slow. 获取有关cmdlet功能的描述。但是,Get-Help的管道似乎非常慢。 There might be a better way of getting the synopsis than calling Get-Help. 获取概要可能比调用Get-Help更好。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM