aspect-build / aspect-build/rules_esbuild
[FR]: Should `output_dir` use `output` as the dir name rather than `name?
- Dominant language
- Starlark
- Stars
- 35
- Forks
- 45
- Avg merge
- 1d 1h
- Merged PRs (30d)
- 1
Description
### What is the current behavior?
It seems that if `output_dir` is true, a directory artifact is declared using the rule name as the folder name.
https://github.com/aspect-build/rules_esbuild/blob/cede902c94e2313a3ea183b6a5e1dbbbfcf40347/esbuild/private/esbuild.bzl#L255-L257
### Describe the feature
I was surprised that when I defined `output = "dist"` with `output_dir = True`, that the rule would fail with “The following files have no generating action: .../dist". After digging into the code, it seems that `name` is used for the folder name. Is that intentional?
Contributor guide
Research direction
Read esbuild/private/esbuild.bzl around lines 255-257 and reproduce the case with output="dist" and output_dir=True. Done means the declared directory artifact resolves to dist rather than the rule name, without the reported missing-generating-action error.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript
- Domain
- build-system
- Issue type
- Feature
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100