我想通過Visual Studio中的軟件包管理器控制檯運行Clean,Build和Rebuild命令,但到目前爲止我還找不到如何。通過軟件包管理器控制檯運行Clean,Build和Rebuild
以下命令獲取我的解決方案中的第一個項目:
$project = Get-Project | select -First 1
當我運行$project | Get-Member
,我可以看到$project
項目的成員。
#Members of the $project ($project | Get-Member)
# TypeName: System.__ComObject#{866311e6-c887-4143-9833-645f5b93f6f1}
#
#Name MemberType Definition
#---- ---------- ----------
#ProjectName CodeProperty System.String ProjectName{get=GetCustomUniqueName;}
#Delete Method void Delete()
#Save Method void Save (string)
#SaveAs Method void SaveAs (string)
#Extender ParameterizedProperty IDispatch Extender (string) {get}
#CodeModel Property CodeModel CodeModel() {get}
#Collection Property Projects Collection() {get}
#ConfigurationManager Property ConfigurationManager ConfigurationManager() {get}
#DTE Property DTE DTE() {get}
#ExtenderCATID Property string ExtenderCATID() {get}
#ExtenderNames Property Variant ExtenderNames() {get}
#FileName Property string FileName() {get}
#FullName Property string FullName() {get}
#Globals Property Globals Globals() {get}
#IsDirty Property bool IsDirty() {get} {set}
#Kind Property string Kind() {get}
#Name Property string Name() {get} {set}
#Object Property IDispatch Object() {get}
#ParentProjectItem Property ProjectItem ParentProjectItem() {get}
#ProjectItems Property ProjectItems ProjectItems() {get}
#Properties Property Properties Properties() {get}
#Saved Property bool Saved() {get} {set}
#UniqueName Property string UniqueName() {get}
#Type ScriptProperty System.Object Type {get=switch ($this.Kind) {...
我不知道如果我能得到的乾淨的構建,並通過$project
項目重建方法,或者我應該我直接針對項目路徑運行的MSBuild。
有什麼想法?
從軟件包管理器控制檯執行此操作的動機是什麼? – manojlds