PublishPipelineArtifact@0 - 发布管道项目 v0 任务

使用此任务可将本地目录或文件发布为当前管道的命名项目。

此任务有较新版本。 有关详细信息,请参阅 PublishPipelineArtifact@1

使用此任务可将本地目录或文件发布为当前管道的命名项目。

重要

仅 Azure DevOps Services 支持此任务。 如果在 Azure DevOps Server 上使用它,则如果使用 Azure DevOps Server 或 TFS 2018,则会收到类似于 Pipeline Artifact Task is not supported in on-premises. Please use Build Artifact Task instead. 使用 发布生成项目 的错误消息。

语法

# Publish Pipeline Artifacts v0
# Publish a local directory or file as a named artifact for the current pipeline.
- task: PublishPipelineArtifact@0
  inputs:
    artifactName: 'drop' # string. Required. The name of this artifact. Default: drop.
    targetPath: # string. Required. Path to publish. 
    #properties: # string. Custom properties.
# Publish Pipeline Artifacts v0
# Publish a local directory or file as a named artifact for the current pipeline.
- task: PublishPipelineArtifact@0
  inputs:
    artifactName: 'drop' # string. Required. The name of this artifact. Default: drop.
    targetPath: # string. Required. Path to publish.

输入

artifactName - 此项目的名称
string。 必填。 默认值:drop

指定项目的名称。


用于发布targetPath - 路径
string。 必填。

指定要发布的文件夹或文件路径。 这可以是完全限定的路径,也可以是相对于存储库根路径的路径。 不支持通配符。 支持 变量


properties - 自定义属性
string

指定要与项目关联的自定义属性。 在所有键上使用前缀 user- 的有效 JSON 字符串。


任务控制选项

除任务输入之外,所有任务都具有控制选项。 有关详细信息,请参阅 控件选项和常见任务属性

输出变量

没有。

此任务有较新版本。 有关详细信息,请参阅 PublishPipelineArtifact@1

重要

仅 Azure DevOps Services 支持此任务。 如果在 Azure DevOps Server 上使用它,则如果使用 Azure DevOps Server 或 TFS 2018,则会收到类似于 Pipeline Artifact Task is not supported in on-premises. Please use Build Artifact Task instead. 使用 发布生成项目 的错误消息。

要求

要求 说明
管道类型 YAML,经典版本,经典版本
运行时间 代理,DeploymentGroup
需求 没有
功能 此任务不满足作业中后续任务的任何要求。
命令限制 任何
Settable 变量 任何
代理版本 2.199.0 或更高版本
任务类别 效用
要求 说明
管道类型 YAML,经典版本,经典版本
运行时间 代理,DeploymentGroup
需求 没有
功能 此任务不满足作业中后续任务的任何要求。
命令限制 任何
Settable 变量 任何
代理版本 2.199 或更高版本
任务类别 效用
要求 说明
管道类型 YAML,经典版本,经典版本
运行时间 代理,DeploymentGroup
需求 没有
功能 此任务不满足作业中后续任务的任何要求。
命令限制 任何
Settable 变量 任何
代理版本 2.155.1 或更高版本
任务类别 效用