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

EnvInject uses UNIX style file separator when setting $WORKSPACE on Windows slave

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Blocker Blocker
    • envinject-plugin
    • None
    • Master Win Server Enterprise 2008 R2
      Slave Win server Enterprise 2008 R2

      The $WORKSPACE variable contains only / instead of \ on a windows slave. I tried setting the $WORKSPACE my self using a batch command before EnvInject kicks in and it gets set, but EnvInject overrides it. There's no workaround as far as I can tell.

          [JENKINS-16625] EnvInject uses UNIX style file separator when setting $WORKSPACE on Windows slave

          Andrei Paun added a comment -

          This was actually a mistake I made. When I configured my slave I accidentally used Unix style separators when specifing the FS root where Jenkins projects should be deployed. It seems that Jenkins really trust the user and doesn't not validate that against the platform it runs so you might end up with your $WORKSPACE variable messed up.

          Andrei Paun added a comment - This was actually a mistake I made. When I configured my slave I accidentally used Unix style separators when specifing the FS root where Jenkins projects should be deployed. It seems that Jenkins really trust the user and doesn't not validate that against the platform it runs so you might end up with your $WORKSPACE variable messed up.

            andrei_paun Andrei Paun
            andrei_paun Andrei Paun
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: