WARNING: THIS SITE IS A MIRROR OF GITHUB.COM / IT CANNOT LOGIN OR REGISTER ACCOUNTS / THE CONTENTS ARE PROVIDED AS-IS / THIS SITE ASSUMES NO RESPONSIBILITY FOR ANY DISPLAYED CONTENT OR LINKS / IF YOU FOUND SOMETHING MAY NOT GOOD FOR EVERYONE, CONTACT ADMIN AT ilovescratch@foxmail.com
Skip to content

Conversation

@jlesquembre
Copy link
Member

Fixes #615

@malt3 malt3 self-requested a review October 15, 2025 14:54
Copy link
Collaborator

@malt3 malt3 left a comment

Choose a reason for hiding this comment

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

Looks pretty good to me. I think this would be a little nicer using an output_list.

run_nix_shell = rule(
implementation = _run_nix_shell_impl,
attrs = {
"output": attr.string(
Copy link
Collaborator

Choose a reason for hiding this comment

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

Suggested change
"output": attr.string(
"outputs": attr.output_list(

I think an output list would give us a bit more flexibility. This way, users can define multiple outputs for a single action. This also avoids the need to ctx.actions.declare_file. Instead, the file is available through ctx.outputs.outputs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add an easy way to use packages inside run_shell

3 participants