-
Notifications
You must be signed in to change notification settings - Fork 15
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
feat: Run Core Script, Script Options, Script Consolidation #9
Conversation
- Observe visibility of `.testEnvStarted` (`--force` to remove previous environment) - Add `--help` option, `--silent` option, and `--force` option - Add argument aliases (`-w` for `--wait`, etc)
- Add "Run Core" run configuration for `./runCore` - Added options `--help`, `--silent`, `--cicd`, and `--force` with aliases - Handles both Linux/Mac and Windows paths using cygpath
@JeremyEastham please lmk when this is ready for review :) You can assign me as a reviewer. |
- `startTestingEnv` is now `startTestEnv` - `setupTestEnvLocal` is now `setupTestEnv --local` or `setupTestEnv` - `cleanTestEnvLocal` is now `cleanTestEnv --local` or `cleanTestEnv` - `setupTestEnvCicd` is now `setupTestEnv --cicd` - `cleanTestEnvCicd` is now `cleanTestEnv --cicd`
I have consolidated
These changes not only make the commands clearer (since most of the time you want to run the local version anyway), but they also make the scripts much DRYer. We now only have one script to edit for each part of the development process. I have made sure to replace all occurrences of I have converted this PR to a draft because I need to submit a PR for the core with the naming changes so it doesn't break the automatic tests. |
These changes seem great!! Really cool! There is just one big problem though -> All the other repos use
And the above are just some of the examples. I think a good solution to this would be to keep the older scripts where they are and make those call the new scripts. We can add comments in the older ones saying why they exist and to not use them, or we can add an What do you think? |
I am preparing a PR that updates the GitHub Actions and CircleCI CI/CD scripts. I will make the existing scripts echo a deprecation warning to stderr so that any scripts that I miss can be updated. These deprecated scripts can call the correct scripts with the default options so that existing tasks will still work. |
After all of this is done, I eventually plan to migrate the functionality of these scripts into either Gradle Tasks, or maybe a separate development-only Java module. This would eliminate the need for platform-specific code or development setup. Currently, the |
I have implemented the changes that you suggested. If one of the deprecated scripts is called, it now prints a deprecation warning in red to stderr. This PR can be merged if it looks good to go. |
I just changed |
How can I commit my changes to the hook for the core? Even if I run It does run the updated script when I commit, but I'm not sure if it will update the hook for everyone else. |
When you run |
If you are doing this for all the other repos, here is a list of them:
|
Is this ready for review and merging? |
Yes, it is. Please double-check the deprecated scripts so that this PR doesn't interrupt any CI/CD pipelines. |
@JeremyEastham i noticed a few issues:
|
Thanks for explaining these issues. I'm surprised that Git Bash ran the scripts fine, since they weren't executable. Did you fix the kill signal issue? |
runCore
that starts the testing environment and runs the corestartTestingEnv
andrunCore
-h
or--help
displays usage info-w
or--wait
uses existing behavior (startTestingEnv
only)-s
or--silent
suppresses echoes in both scripts-c
or--cicd
tells the script to use the CI/CD versions ofsetupTestEnv
andcleanTestEnv
-f
or--force
tells the script to destroy the testing environment if a.testEnvStarted
file exists