jenkinsci / jenkinsci/durable-task-plugin

[JENKINS-59872] Allow Poweshell Stage Steps to run without -noprofile

Open
#467 0 comments 0 reactions 0 assignees View on GitHub
component:durable-task-plugin imported-jira-issue priority:minor resolution:unresolved
Dominant language
Java
Stars
30
Forks
101
PR merge metrics
No merged PRs in 30d

Description

Powershell steps are executed with the -noprofile powershell option.

This is not always desired. In our case we add setup and configuration tasks to the default profile. A workaround if to add ". $profile" at the beginning of each powershell step but this adds overhead to all steps and is a maintenance burden.

Additionally, the powershell plugin for jenkins doesn't use -noprofile, so it would be good to preserve that behaviour to make the switch to the jenkins pipeline seemless.

 

Suggestion:

Make the hardcoded command line to powershell configurable globally, so that  a "use default profile" global checkbox can drive this behaviour.

 

---
Originally reported by sebastian_sl, imported from: Allow Poweshell Stage Steps to run without -noprofile


  • status: Open
  • priority: Minor
  • component(s): durable-task-plugin
  • resolution: Unresolved
  • votes: 0
  • watchers: 2
  • imported: 2025-12-09

Raw content of original issue

Powershell steps are executed with the -noprofile powershell option.

This is not always desired. In our case we add setup and configuration tasks to the default profile. A workaround if to add ". $profile" at the beginning of each powershell step but this adds overhead to all steps and is a maintenance burden.

Additionally, the powershell plugin for jenkins doesn't use -noprofile, so it would be good to preserve that behaviour to make the switch to the jenkins pipeline seemless.

 

Suggestion:

Make the hardcoded command line to powershell configurable globally, so that  a "use default profile" global checkbox can drive this behaviour.

 

environment

```
Jenkins ver: 2.176.2

OS: Windows Server 16

Pipeline plugin: 2.4
```

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.