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

Randomly named additional subfolder when checking out git

XMLWordPrintable

      When checking out (looking in job's console output), local files are getting not directly to the JobName@script folder but also add a subfolder with name like ecb7a9317b1ad672698830264d9e0ce2b9b6f330c043bb85f48623f3cdcab65e

      Checking out git git@...repo.git into /Users/user/.jenkins/workspace/JobName@script/ecb7a9317b1ad672698830264d9e0ce2b9b6f330c043bb85f48623f3cdcab65e/jenkins/A.groovy

       

      Loading the main groovy file here:

      Project to build located directly in Job Name folder, without subfolders. But scripts put in subfolder.

       

      Now, when in A.groovy I am trying to import B.groovy 

      load("jenkins/B.groovy")
      or
      load(env.WORKSPACE + "@script/jenkins/B.groovy"

      I am getting an error 

      java.nio.file.NoSuchFileException:
      /Users/user/.jenkins/workspace/JobName@script/jenkins/B.groovy

      And don't see any way to get that subfolder name from environment or other way. Thus just can't load an external file.

            Unassigned Unassigned
            bodich Bogdan Cho
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: