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

Some of the Environment Variables are not expanding properly

    XMLWordPrintable

Details

    Description

      Environment variables are not expanding properly in XSHELL command
      Ex:
      In Xshell, if i give a command as below,

      python test.py "$WORKSPACE/sdkljnkjndj/sdkgjnkdjnbg" "http://idc-ws-isparbs.mchp-main.com:8080/job/$JOB_NAME/$BUILD_NUMBER"

      and if i print the parameters in test.py, I get the following

      '%WORKSPACE\\sdkljnkjndj
      sdkgjnkdjnbg%'
      'http://idc-ws-isparbs.mchp-main.com:8080/job/%JOB_NAME/25%'

      I also get few '%' characters appended to the output

      I was expecting the output as

      'C:\\WS\\sdkljnkjndj
      sdkgjnkdjnbg'
      'http://idc-ws-isparbs.mchp-main.com:8080/job/test_job/25'

      Attachments

        Activity

          shankar_ramasamy Shankar R created issue -
          shankar_ramasamy Shankar R made changes -
          Field Original Value New Value
          Summary Some of the Environment Variables are not Some of the Environment Variables are not expanding properly
          alexrovner alexrovner made changes -
          Labels plugin
          alexrovner alexrovner made changes -
          Labels plugin plugin windows
          alexrovner alexrovner made changes -
          Labels plugin windows plugin windows xshell
          rtyler R. Tyler Croy made changes -
          Workflow JNJira [ 152003 ] JNJira + In-Review [ 178149 ]

          People

            Unassigned Unassigned
            shankar_ramasamy Shankar R
            Votes:
            0 Vote for this issue
            Watchers:
            7 Start watching this issue

            Dates

              Created:
              Updated: