The scheme can be either defined on the workspace or the project level. The step correctly reads the scheme at the beginning of its run phase but does not during the execution. It is because we loose the during the information if the project was part of a workspace or not once the main logic is executed.
The step already passes the scheme name from function to function and reads the scheme over and over again. The scheme settings are not being changed during the runtime so it is fine to read the scheme once at beginning and pass ot down instead of just the scheme name.
This is what this PR introduces. It eliminates the unnecessary scheme creations and only uses the scheme which was created at the beginning of the execution.
Changes
Read the scheme once at the beginning and pass the created struct instead of just the scheme name
Remove the user of the project struct for the main target determination logic
Checklist
step.yml
andREADME.md
is updated with the changes (if needed)Version
Requires a PATCH version update
Context
The scheme can be either defined on the workspace or the project level. The step correctly reads the scheme at the beginning of its run phase but does not during the execution. It is because we loose the during the information if the project was part of a workspace or not once the main logic is executed.
The step already passes the scheme name from function to function and reads the scheme over and over again. The scheme settings are not being changed during the runtime so it is fine to read the scheme once at beginning and pass ot down instead of just the scheme name.
This is what this PR introduces. It eliminates the unnecessary scheme creations and only uses the scheme which was created at the beginning of the execution.
Changes