设置PSake

dag*_*da1 12 powershell psake

有没有人知道或有链接到我如何设置psake运行PowerShell?

我完全不知道,我什么都找不到.

Kei*_*ill 10

这里下载.以下是一些使用示例:

http://ayende.com/Blog/archive/2009/08/30/on-psake.aspx http://www.jameskovacs.com/blog/IntroducingPsake.aspx

2.0版PSake是PowerShell模块,需要PowerShell 2.0.将PSake ZIP的内容解压缩到$ env:Home\Documents\WindowsPowerShell\Modules\PSake.然后你这样导入它:

Import-Module PSake
Run Code Online (Sandbox Code Playgroud)

定义"属性"哈希表,然后在构建脚本中开始使用其导出的命令,如Task.

  • Import-Module是一种方式.http://www.jameskovacs.com/blog/CategoryView.aspx?category=PowerShell描述了这种方式:您可以将psake.psm1复制到名为psake的文件夹中,放入配置文件目录中的"Modules"文件夹中(您可能需要创建它,如果它不存在)或您的​​机器范围"模块"目录:即配置文件目录:C:\ Users\Jorge\Documents\WindowsPowerShell\Modules\psake ie Machine-wide Modules文件夹:C:\ Windows\System32\WindowsPowerShell\1.0 \模块\ psake (4认同)