It would be nice if variables could be interpolated into the strings for the filters.

      Currently, the filter strings are in quotes. Without quotes they could just be a string which contains a regular expression subject to variable interpolation:

      def arch = 'bar'
      def myregex = '.*\\/foobar-\${arch}\\/'
      ...
      recordIssues filters: [excludeFile(myregex)], tools: [gcc4()]
      

      The backslash in front of ${arch} escapes the $ from the RE. if one wanted it escaped from variable interpolation one would need to add another backslash such as
      ${arch
      }

      Being able to define a list of excludeFile() s in a single variable would be even more useful though. not sure how that could work though.

          [JENKINS-55574] interpolate variables in filters strings

          Brian J Murrell created issue -
          Ulli Hafner made changes -
          Description Original: It would be nice if variables could be interpolated into the strings for the filters.

          Currently, the filter strings are in quotes. Without quotes they could just be a string which contains a regular expression subject to variable interpolation:

          {noformat}
          def arch = 'bar'
          def myregex = '.*\\/foobar-\${arch}\\/'
          ...
          recordIssues filters: [excludeFile(myregex)], tools: [gcc4()]
          {noformat}

          The backslash in front of {{$\{arch\}}} escapes the {{$}} from the RE. if one wanted it escaped from variable interpolation one would need to add another backslash such as {{\\$\{arch\}}}

          Being able to define a list of {{excludeFile()}}s in a single variable would be even more useful though. not sure how that could work though.
          New: It would be nice if variables could be interpolated into the strings for the filters.

          Currently, the filter strings are in quotes. Without quotes they could just be a string which contains a regular expression subject to variable interpolation:

          {noformat}
          def arch = 'bar'
          def myregex = '.*\\/foobar-\${arch}\\/'
          ...
          recordIssues filters: [excludeFile(myregex)], tools: [gcc4()]
          {noformat}

          The backslash in front of {{$\{arch\}}} escapes the {{$}} from the RE. if one wanted it escaped from variable interpolation one would need to add another backslash such as {{\\$\{arch\}}}

          Being able to define a list of {{excludeFile()}} s in a single variable would be even more useful though. not sure how that could work though.
          Ulli Hafner made changes -
          Rank New: Ranked higher
          Ulli Hafner made changes -
          Rank New: Ranked higher
          Ulli Hafner made changes -
          Rank New: Ranked higher
          Ulli Hafner made changes -
          Assignee Original: Ulli Hafner [ drulli ]
          Labels New: help-wanted
          Ulli Hafner made changes -
          Rank New: Ranked lower

            Unassigned Unassigned
            brianjmurrell Brian J Murrell
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated: