refactor(ChangedComponentsDetector): update shell command execution to use steps.sh for consistency

Signed-off-by: 孙振宇 <>
This commit is contained in:
孙振宇 2025-02-04 12:15:40 +08:00
parent aa7d449616
commit a46e87ac1c

View File

@ -13,7 +13,7 @@ class ChangedComponentsDetector {
steps.dir(workspace) { steps.dir(workspace) {
// using git command to get changed files list // using git command to get changed files list
def changedFiles = sh(script: 'git diff --name-only HEAD~1 HEAD', returnStdout: true) def changedFiles = steps.sh(script: 'git diff --name-only HEAD~1 HEAD', returnStdout: true)
.trim() .trim()
.split('\n') .split('\n')