Hi,
The doc site is wrong, please use echo ${2.exec.exitCode}. (Note that the doc refers to 2.exit.exitCode).
I’ll send a PR to fix that on the doc site.
Thanks!
Hi,
If you’re using a command step, use the ${1.exec.exitCode} way.
If you’re using a script step (“inline script”): @1.exec.exitCode@ way.
Greetings.
Hi!
Let me share a job definition example:
- defaultTab: nodes description: '' executionEnabled: true id: 52dac3c6-6ddf-42cc-a55b-6c636a917f59 loglevel: INFO name: HelloWorld nodeFilterEditable: false plugins: ExecutionLifecycle: null scheduleEnabled: true sequence: commands: - script: echo "hi" - exec: 'echo "first step exit code: ${1:exec.exitCode}"' - script: 'echo "first step exit code: @1:exec.exitCode@"' keepgoing: false strategy: node-first uuid: 52dac3c6-6ddf-42cc-a55b-6c636a917f59Check the result here.