Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-65965

copyArtifacts 'filter' parameter does not allow whitespace

    • Icon: Bug Bug
    • Resolution: Cannot Reproduce
    • Icon: Major Major
    • copyartifact-plugin
    • None

      In pipeline step documentation, reading about copyArtifact 'filter'  (https://www.jenkins.io/doc/pipeline/steps/copyartifact/):

      > Can use wildcards like module/dist/*/.zip, and use comma (followed by optional whitespace) to separate multiple entries.

       

      Turns out using space after comma no longer works and terminates the filter.

       

      Example (whitespaced):

      copyArtifacts fingerprintArtifacts: true, flatten: true, projectName: 'foo', selector: lastSuccessful(stable: true), target: '.', filter: '**/module*.json, **/group*.json'
      sh('ls')

      Result:

      module_1.json 
      module_2.json 
      module_3.json 
      module_4.json
      

      Example 2 (no witespace):

      copyArtifacts fingerprintArtifacts: true, flatten: true, projectName: 'foo', selector: lastSuccessful(stable: true), target: '.', filter: '**/module*.json,**/group*.json'
      sh('ls')

      Result 2:

      module_1.json
      module_2.json
      module_3.json
      module_4.json
      group_1.json
      group_2.json
      group_3.json
      

       

      Version observed: copyartifact-1.46.1

          [JENKINS-65965] copyArtifacts 'filter' parameter does not allow whitespace

          Filip Daca created issue -
          Filip Daca made changes -
          Priority Original: Minor [ 4 ] New: Major [ 3 ]
          ikedam made changes -
          Assignee Original: ikedam [ ikedam ] New: Filip Daca [ filip_daca ]
          Resolution New: Cannot Reproduce [ 5 ]
          Status Original: Open [ 1 ] New: Fixed but Unreleased [ 10203 ]
          Mark Waite made changes -
          Status Original: Fixed but Unreleased [ 10203 ] New: Closed [ 6 ]

            filip_daca Filip Daca
            filip_daca Filip Daca
            Votes:
            1 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: