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

Improve powershell version selection




      The help text does not represent the current state

      "On Windows it uses PowerShell.exe and on Linux pwsh (PowerShell Core)"

      It should be somthing like

      "The used Powershell binary is defined by the tool configuration.
      (DefaultWindows is used under Windows and DefaultLinux under Linux)"


      Currently only these two are hardcoded with their tool name.
      i.e. it is useless to create new powershell-tools because they cannot be selected.

      But it would really be an added value to be able to select the tool to be used per build step.

      Currently it is not possible to run scripts with Powershell5 and PowershellCore on a Windows node.
      You have to choose because the "DefaultWindows" tool is always used.

      Also on Linux it will be useful in the future to be able to select different versions of Powershell (6,7,8 ...).



          martinbauer Martin Bauer created issue -
          beny Benzion made changes -
          Field Original Value New Value
          Comment [ I am on the latest version, 1.7, and my script running 'Start-Transcript -UseMinimalHeader' is failing because this argument is not supported, which was introduced in Powershell6 in 2016.

          Please expedite this ticket so the community can use all commands. ]


            froque Filipe Roque
            martinbauer Martin Bauer
            0 Vote for this issue
            2 Start watching this issue