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

Delay asset pipeline until rust build finished #701

Open
lpotthast opened this issue Feb 3, 2024 · 2 comments
Open

Delay asset pipeline until rust build finished #701

lpotthast opened this issue Feb 3, 2024 · 2 comments
Labels
enhancement New feature or request help wanted Extra attention is needed needs design This item needs design work

Comments

@lpotthast
Copy link
Contributor

lpotthast commented Feb 3, 2024

My use case includes copying SCSS files through a libraries build.rs file into my application root directory.

Building the styles (SASS) will only work with the output from this build script.

But the asset pipeline always runs in parallel / can not be configured to run after a finished rust build. Errors in the SASS pipeline lead to a retry, also skipping/aborting the rust build, leading to no build.rs being executed an and endless retry-loop.

Could such an optional behavior be integrated into trunk?

@lpotthast
Copy link
Contributor Author

A not-so-great workaround would be to add a “pre-build” hook that executes a cargo check to enforce running the build once.

@ctron
Copy link
Collaborator

ctron commented Feb 4, 2024

Interesting. Right now, there isn't a real scheduler/dependency tree in the trunk build pipeline. However, there's another use case, where web-workers might have a dependency on each other, and the application being last (in order to inject env-vars with cache busting name).

Your use case looks like one more use case for having dependencies between different build steps.

@ctron ctron added enhancement New feature or request help wanted Extra attention is needed needs design This item needs design work labels Feb 4, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request help wanted Extra attention is needed needs design This item needs design work
Projects
None yet
Development

No branches or pull requests

2 participants