简体   繁体   English

如何使用“jf rt upload”将多个单独的文件夹及其内容上传到单个 zip 文件到 JFrog Artifactory。 ( /Alpha, /Beta, /Gamma)

[英]How to upload multiple seperate folders and thier contents to a single zip file to JFrog Artifactory using "jf rt upload". ( /Alpha, /Beta, /Gamma)

Given the following folder structure:"/Alpha,/Beta,/Gamma,/Delta, ..."给定以下文件夹结构:“/Alpha,/Beta,/Gamma,/Delta, ...”

Using JFrog CLI how can I upload only the first two folders and thier entire contents.使用 JFrog CLI 如何只上传前两个文件夹及其全部内容。

Ive tried the following using a regular expression:我使用正则表达式尝试了以下操作:

jf rt upload "Alpha|Beta" My-generic-local/My-rep-folder/target.zip --archive zip --dry-run --regexp

[Error]CreateFile Aplha|Beta: The filename, directory name, or volume label syntax is incorrect. [错误]CreateFile Aplha|Beta:文件名、目录名或卷标语法不正确。

You can try File Specs for this purpose.为此,您可以尝试使用 File Specs。

jf rt upload --spec=filespec.json

filespec.json:文件规范.json:

{
  "files": [
    {
      "pattern": "Alpha/",
      "target": "My-generic-local/My-rep-folder/target.zip",
      "archive": "zip"
    },
    {
      "pattern": "Beta/",
      "target": "My-generic-local/My-rep-folder/target.zip",
      "archive": "zip"
    }
  ]
}

Learn more about JFrog File Specs:了解有关 JFrog 文件规范的更多信息:

  1. JFrog File Specs JFrog 文件规格
  2. Using File Specs in JFrog CLI 在 JFrog CLI 中使用文件规范

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 如何在Jenkins中使用filespec动态创建文件夹并在Jfrog人工制品中上传人工制品? - How to create folders dynamically and upload artifacts in Jfrog artifactory using filespecs in Jenkins? 使用 gradle 将 jar 上传到 JFrog Artifactory - Upload jar to JFrog Artifactory using gradle 如何使用curl将带有元数据的文件上传到jfrog人工制品 - How do I upload a file with metadata to jfrog artifactory with curl 如何使用 Jfrog CLI 将多个工件及其文件夹结构上传到工件 - How to Upload Multiple Artifacts to artifactory along with their folder structure using Jfrog CLI Salt堆栈中是否有文件上传功能,可以将罐子上传到JFrog Artifactory? - Is there a file upload function in salt stack to upload a jar to JFrog Artifactory? curl 命令无法上传文件,如果文件已经存在于 jfrog artifactory - curl command not working to upload file , if file is already present on jfrog artifactory 使用gradle和jfrog工件插件如何将通用工件上传到通用存储库 - Using gradle and the jfrog artifactory plugin how can I upload a generic artifact to a generic repository 使用JFrog CLI上传到具有不同工件名称的Artifactory - Upload to Artifactory with different artifact name, using JFrog CLI Groovy-无法在JFrog Artifactory中上传工件 - Groovy - Unable to upload artifact in JFrog Artifactory “com.jfrog.artifactory-upload”发生了什么? - What happened to “com.jfrog.artifactory-upload”?
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM