共用方式為


NuGetPublisher@0 - NuGet 發行者 v0 工作

NuGetPublisher@0已被取代。 請改用 「NuGet」 工作。 它適用於新的工具安裝程序架構,因此您可以輕鬆地使用新版本的 NuGet,而不需等候工作更新、提供此組織/集合外已驗證摘要的更佳支援,並預設使用 NuGet 4。

Syntax

# NuGet publisher v0
# Deprecated: use the “NuGet” task instead. It works with the new Tool Installer framework so you can easily use new versions of NuGet without waiting for a task update, provides better support for authenticated feeds outside this organization/collection, and uses NuGet 4 by default.
- task: NuGetPublisher@0
  inputs:
    searchPattern: '**/*.nupkg;-:**/packages/**/*.nupkg;-:**/*.symbols.nupkg' # string. Required. Path/Pattern to nupkg. Default: **/*.nupkg;-:**/packages/**/*.nupkg;-:**/*.symbols.nupkg.
    nuGetFeedType: 'external' # 'external' | 'internal'. Required. Feed type. Default: external.
    connectedServiceName: # string. Required when nuGetFeedType = external. NuGet Service Connection. 
    #feedName: # string. Required when nuGetFeedType = internal. Internal Feed URL. 
  # Advanced
    #nuGetAdditionalArgs: # string. NuGet Arguments. 
    #verbosity: '-' # '-' | 'Quiet' | 'Normal' | 'Detailed'. Verbosity. Default: -.
    nuGetVersion: '3.3.0' # '3.3.0' | '3.5.0.1829' | '4.0.0.2283' | 'custom'. Required. NuGet Version. Default: 3.3.0.
    #nuGetPath: # string. Path to NuGet.exe. 
    #continueOnEmptyNupkgMatch: false # boolean. Continue if no packages match the "Path/Pattern to nupkg". Default: false.
# NuGet Publisher v0
# Deprecated: use the “NuGet” task instead. It works with the new Tool Installer framework so you can easily use new versions of NuGet without waiting for a task update, provides better support for authenticated feeds outside this account/collection, and uses NuGet 4 by default.
- task: NuGetPublisher@0
  inputs:
    searchPattern: '**/*.nupkg;-:**/packages/**/*.nupkg;-:**/*.symbols.nupkg' # string. Required. Path/Pattern to nupkg. Default: **/*.nupkg;-:**/packages/**/*.nupkg;-:**/*.symbols.nupkg.
    nuGetFeedType: 'external' # 'external' | 'internal'. Required. Feed type. Default: external.
    connectedServiceName: # string. Required when nuGetFeedType = external. NuGet Service Connection. 
    #feedName: # string. Required when nuGetFeedType = internal. Internal Feed URL. 
  # Advanced
    #nuGetAdditionalArgs: # string. NuGet Arguments. 
    #verbosity: '-' # '-' | 'Quiet' | 'Normal' | 'Detailed'. Verbosity. Default: -.
    nuGetVersion: '3.3.0' # '3.3.0' | '3.5.0.1829' | '4.0.0.2283' | 'custom'. Required. NuGet Version. Default: 3.3.0.
    #nuGetPath: # string. Path to NuGet.exe. 
    #continueOnEmptyNupkgMatch: false # boolean. Continue if no packages match the "Path/Pattern to nupkg". Default: false.

輸入

searchPattern - nupkg 的路徑/模式
string. 必要。 預設值:**/*.nupkg;-:**/packages/**/*.nupkg;-:**/*.symbols.nupkg

工作用來比對或要上傳之 nupkg 檔案路徑的模式。 多個模式可以以分號分隔。


nuGetFeedType - 摘要類型
string. 必要。 允許的值: external (外部 NuGet 摘要) , internal (內部 NuGet 摘要) 。 預設值:external

指定目標摘要是內部摘要/集合還是外部 NuGet 伺服器。


connectedServiceName - NuGet 服務連線
string. 當 nuGetFeedType = external 時為必要。

指定 NuGet 伺服器一般服務連線。 將金鑰 Password/Token Key 欄位設定為 NuGet API 金鑰。


feedName - 內部摘要 URL
string. 當 nuGetFeedType = internal 時為必要。

指定此帳戶中裝載之 NuGet 摘要的 URL。


nuGetAdditionalArgs - NuGet 自變數
string.

傳遞至 NuGet.exe push的其他自變數。 深入瞭解 NuGet CLI 中的推送命令


verbosity - 冗長
string. 允許的值:-、、、QuietNormalDetailed 預設值:-

指定輸出中顯示的詳細數據量。


nuGetVersion - NuGet 版本
string. 必要。 允許的值: 3.3.03.5.0.1829 (3.5.0) 、 4.0.0.2283 (4.0.0) 、 custom。 預設值:3.3.0

指定要使用的 NuGet 版本或自訂版本。


nuGetPath - NuGet.exe的路徑
string.

選擇性。 提供的路徑 NuGet.exe。 將會覆寫版本選取專案。


continueOnEmptyNupkgMatch - 如果沒有套件符合 「Path/Pattern to nupkg」,請繼續
boolean. 預設值:false

如果沒有任何套件符合 searchPattern 字串,請繼續工作,而不是讓工作失敗。


工作控制選項

除了工作輸入之外,所有工作都有控制選項。 如需詳細資訊,請參閱 控件選項和一般工作屬性

輸出變數

無。

規格需求

需求 描述
管線類型 YAML、傳統組建、傳統版本
執行於 Agent、DeploymentGroup
要求 自我裝載代理程式必須具備符合下列需求的功能,才能執行使用此工作的作業:Cmd
Capabilities 此工作不符合作業中後續工作的任何需求。
命令限制 任何
Settable 變數 任何
代理程式版本 2.144.0 或更新版本
工作類別 套件
需求 描述
管線類型 YAML、傳統組建、傳統版本
執行於 Agent、DeploymentGroup
要求 自我裝載代理程式必須具備符合下列需求的功能,才能執行使用此工作的作業:Cmd
Capabilities 此工作不符合作業中後續工作的任何需求。
命令限制 任何
Settable 變數 任何
代理程式版本 2.115.0 或更新版本
工作類別 套件
需求 描述
管線類型 YAML、傳統組建、傳統版本
執行於 Agent、DeploymentGroup
要求 自我裝載代理程式必須具備符合下列需求的功能,才能執行使用此工作的作業:Cmd
Capabilities 此工作不符合作業中後續工作的任何需求。
命令限制 任何
可設定變數 任何
代理程式版本 1.83.0 或更新版本
工作類別 套件