[Rpm-maint] [rpm-software-management/rpm] rpm.execute() and rpm.spawn() seem unsuitable for file triggers (Discussion #4029)
Panu Matilainen
notifications at github.com
Tue Nov 4 08:38:20 UTC 2025
Yeah rpm.execute() doesn't allow that kind of control at all, you'll need rpm.spawn().
But see above, with Lua scriptlets you can't just expect to pass the scriptlet stdin to something else and be done with it, because the Lua scriptlets do not get their input from stdin. You need to "manually" read the input line by line, and feed it onwards:
```
f = rpm.next_file()
while f do
-- do your thing here
f = rpm.next_file()
end
```
"do your thing" would be calling the helper one by one, or you could collect it to a temporary file that you pass to the helper to pass them all at once after the loop.
--
Reply to this email directly or view it on GitHub:
https://github.com/rpm-software-management/rpm/discussions/4029#discussioncomment-14866731
You are receiving this because you are subscribed to this thread.
Message ID: <rpm-software-management/rpm/repo-discussions/4029/comments/14866731 at github.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rpm.org/pipermail/rpm-maint/attachments/20251104/46d619ed/attachment.htm>
More information about the Rpm-maint
mailing list