Strange quote rules for parameters

This issue is archived. You can view it, but you can't modify it. Learn more

XMLWordPrintable

    • Type: Bug
    • Resolution: Not A Defect
    • Priority: Minor
    • Component/s: prescmbuildstep-plugin
    • Environment:

      I have a "String parameter" named GIT_BRANCH_NAME.

      If I have the following shell code for the pre-SCM:

      export | sort
      ...
      if [ x${GIT_BRANCH_NAME} != "xdevelop" ]; then
        export BRANCHNAME=" (${GIT_BRANCH_NAME})"
      fi
      

      then the result includes

      export GIT_BRANCH_NAME="\${GIT_BRANCH_NAME}"
      

      BUT if I force a quote around the parameter name:

      export | sort
      ...
      if [ x"${GIT_BRANCH_NAME}" != "xdevelop" ]; then
        export BRANCHNAME=" (${GIT_BRANCH_NAME})"
      fi
      

      I get the expected results:

      export GIT_BRANCH_NAME="develop"
      

      This could be envinject causing the problems as well.

            Assignee:
            Unassigned
            Reporter:
            Aaron D. Marasco
            Archiver:
            Jenkins Service Account

              Created:
              Updated:
              Resolved:
              Archived: