-
Notifications
You must be signed in to change notification settings - Fork 345
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: watch for changed integration test files #464
Conversation
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.
Wow, this is amazing! I'm surprised at how small & neat the watch.ts
script is too; I'm definitely going to be cribbing this for another use cases I have on other/future projects. :-D
Thanks!
I'm glad to hear that! I see that this doesn't work on Ubuntu in WSL, so I'm adding an option Please let me know if it works on Linux. Then I see there's still an issue generating the pbjs files, so I broke something there. Will fix that. |
@boukeversteegh wow, worked the 1st time on linux. |
# [1.98.0](v1.97.2...v1.98.0) (2022-01-06) ### Features * watch for changed integration test files ([#464](#464)) ([988cd7e](988cd7e))
🎉 This PR is included in version 1.98.0 🎉 The release is available on: Your semantic-release bot 📦🚀 |
This was quite some work, but well worth it.
Added
Watch for changes in
integration/*/*.{bin, proto}
and automatically run the correct scripts (proto2bin
,proto2pbjs
andbin2ts
).Automatically keeps
.ts
and.pbjs
files up to date while working onts-proto
.Motivation
Features
Missing features
main.ts
).This would be extremely impractical as it takes at least a minute, and would run each time you type a letter
Implementation
nodemon
nodemon
cannot pass the changed files as arguments to the configuredexec
script, so usingnodemon
would force us to regenerate all files, each time one changed.nodemon
but has the same limitation, so couldn't be usedcodegen.sh value/value.bin
(this is passed byyarn watch
)Screenshot
Running
yarn watch
and updatingintegration/simple-optionals/simple.proto