Skip to content
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

Fix the --watch flag for AssemblyScript #493

Merged
merged 1 commit into from
Jan 4, 2022

Conversation

Integralist
Copy link
Collaborator

Fixes #476

Problem: When implementing the --watch functionality we neglected to notice that the source code directory for AssemblyScript wasn't src (as it is with JavaScript and Rust) and so when it came to using the --watch flag we had hardcoded "src" to be watched.

Solution: We inspect the --language flag, falling back to the fastly.toml manifest to identify the language and use that information to identify the correct source code directory to watch.

Screenshots: The following screenshot shows that the compiled binary now correctly runs the compute serve --watch command and will (when an update is made to a file) trigger the hot reload functionality.

Screenshot 2021-12-17 at 17 08 07

@Integralist Integralist added the bug Something isn't working label Dec 17, 2021
@Integralist Integralist requested review from a team and triblondon and removed request for a team December 17, 2021 17:13
Copy link
Contributor

@triblondon triblondon left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@Integralist Integralist merged commit 14d0584 into main Jan 4, 2022
@Integralist Integralist deleted the integralist/fix-serve-watch branch January 4, 2022 10:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

--watch doesn't work with AssemblyScript
2 participants