-
-
Notifications
You must be signed in to change notification settings - Fork 251
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
manualExit
suppresses -quit
, useful for buildMethods with async calls
#574
Conversation
Notes
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me, mostly.
manualExit: | ||
required: false | ||
default: '' | ||
description: 'Suppresses `-quit`. Exit your build method using `EditorApplication.Exit(0)` instead.' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Currently you're passing the variable directly to the bash script and doing complicated logic (I believe this is the first time we use +set
in this repo) that differs from other is set
checks in our bash scripts.
We want to move as much away from the bash scripts as possible (in favour of the higher level TypeScript code) and not pass arbitrary values to it. Normalisation and input should either be guaranteed to be correct or throw an error so that the user knows they've misconfigured something.
Should this default to false?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It should default to false. Having it be the presence of a value wasn’t what I wanted, but was a first pass at using what I found; e.g. I didn’t see an example of boolean handling; Input.getInput
returns a string. Happy to be pointed in the right direction.
Similarly, the bash script responds to the presence or not of the env var, which is clean from the POV of the separation of parsing the input. But I have no love for this kind of scripting and am happy to be pointed in the direction of how this this effect is achieved elsewhere in the codebase.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm in a bit of a hurry atm, but basically consider workflow inputs as input for the TS logic, and the TS logic to be responsible for passing in something deterministic to the bash script.
Ideally we'd remove the string | undefined
in favour of string
like the rest does, and parse that into a true
or false
or 1
or 0
value, and pass that into the script.
06e2b3c
to
256fce9
Compare
256fce9
to
aab7c4f
Compare
Now models input as a boolean. I can squash the commit if that’s desired. Reminder – haven’t touched the other platforms. |
Codecov Report
❗ Your organization needs to install the Codecov GitHub app to enable full functionality. Additional details and impacted files@@ Coverage Diff @@
## main #574 +/- ##
==========================================
+ Coverage 36.96% 37.02% +0.06%
==========================================
Files 77 77
Lines 3038 3041 +3
Branches 641 632 -9
==========================================
+ Hits 1123 1126 +3
+ Misses 1915 1765 -150
- Partials 0 150 +150
|
This'll also need to be documented in https://github.com/game-ci/documentation |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nice
Changes
with: manualExit
parameter to the action, that when present suppresses the Unity-quit
command line argument. See Add config flag that drops -quit from builder cli#13 and Configuration option to suppress-quit
#442Checklist
code of conduct
a PR in the documentation repo)