开发者

Running powershell script from solution explorer inside Nuget Package Manager Console

I have a few powershell scripts inside my c# project. I added them to a solution folder. Would it be possible to make VS2010 run them inside the nuget powershell console by o开发者_JS百科ne of these methods :

  • double clicking on the file
  • right click / open with
  • custom action on the context menu


Since the previous answer was posted this very simple package came about which does exactly what is needed:

  • http://lostechies.com/matthinze/2012/01/05/solutionscripts-little-scripts-for-the-nuget-console/
  • https://bitbucket.org/mhinze/solutionscripts/src/d3651b843e3d/tools/init.ps1
  • http://nuget.org/packages/solutionscripts

In short, install the package and place those scripts in a folder called SolutionScripts.


We followed up on this question at http://nuget.codeplex.com/Thread/View.aspx?ThreadId=239161.

To summarize, try using an init.ps1 file. Look at the MvcScaffold package for a good example of this.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜