fast-school-44220
10/03/2025, 8:32 PMshell_command targets. How do I actually invoke them? pants run apparently only works with run_shell_command but I wanted to use the outputs in downstream shell_command targets.fast-school-44220
10/03/2025, 8:39 PMrun_shell_command of something trivial and set the `shell_command`s as dependencies?fast-school-44220
10/03/2025, 8:39 PMwide-midnight-78598
10/03/2025, 8:41 PMfast-school-44220
10/03/2025, 8:45 PMpants run. I'll give that a try.wide-midnight-78598
10/03/2025, 8:46 PMwide-midnight-78598
10/03/2025, 8:49 PMshell_command and run_shell_command but there are proper usages that I just need to re-familiarize myself with. I almost exclusively use adhoc_tool when doing anything non trivialfast-school-44220
10/03/2025, 8:50 PMfast-school-44220
10/03/2025, 8:51 PMshell_command seems like the most direct mappingwide-midnight-78598
10/03/2025, 8:51 PMwide-midnight-78598
10/03/2025, 8:51 PMwide-midnight-78598
10/03/2025, 8:56 PMfast-school-44220
10/03/2025, 8:56 PMshell_command.py right now. 🙂wide-midnight-78598
10/03/2025, 8:57 PMwide-midnight-78598
10/03/2025, 8:58 PMpants run shell_source_targetfast-school-44220
10/03/2025, 9:00 PMexperimental_wrap_as_ also seems really useful for the other stuff I've been working on.fast-school-44220
10/03/2025, 9:04 PMmonospace formatted words were all links. It talks about setting up as system_binary target, but I don't know where it documents the fields in said target.wide-midnight-78598
10/03/2025, 9:29 PMfast-nail-55400
10/04/2025, 1:01 AMtest goal?fast-nail-55400
10/04/2025, 1:02 AMtest_shell_command.fast-school-44220
10/04/2025, 3:28 AMfast-school-44220
10/06/2025, 3:22 PMrun_shell_command() and named it go with an execution_dependencies referencing my adhoc_tool. When I invoke pants -ldebug run :go I can see that it does happily run the adhoc_tool. Yay. But the output file from the adhoc_tool isn't showing up in the sandbox for the run_shell_command. Boo.fast-nail-55400
10/06/2025, 3:47 PMfast-school-44220
10/06/2025, 3:48 PMmd5sum on the source files and the outputs generated by previous dependency stepsfast-nail-55400
10/06/2025, 4:01 PMrun_shell_command runs interactively and not in a sandbox. Was the code trying to find the output in {chroot}/foo (for a file named foo) or in the current directory?fast-school-44220
10/06/2025, 4:02 PMrun_shell_command because I can easily invoke it with pants run. Is there a better want to invoke an adhoc_tool?fast-nail-55400
10/06/2025, 4:04 PM{chroot} replacement to get access to dependencies in `run_shell_command`: https://github.com/shoalsoft/pants-go-workspace-example/blob/636cb17718ae0818619971a628b98e4b663ceb43/pants-macros/golang.py#L36fast-school-44220
10/06/2025, 4:04 PMfast-nail-55400
10/06/2025, 4:09 PMadhoc_tool and shell_command targets, then the export-codegen goal might be useful.fast-nail-55400
10/06/2025, 4:09 PMmd5sum on the source files and the outputs generated by previous dependency steps
The :go target name made me think for a moment you might be trying to build Go code (in which case I had some examples).fast-nail-55400
10/06/2025, 4:09 PMfast-school-44220
10/06/2025, 5:02 PM{chroot} documented anywhere?