[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: How to pass something on to xargs rm?
From: |
Eli Zaretskii |
Subject: |
Re: How to pass something on to xargs rm? |
Date: |
Tue, 27 Dec 2016 15:04:14 +0200 |
> From: ng0 <address@hidden>
> Date: Tue, 27 Dec 2016 12:42:13 +0000
> Cc: address@hidden
>
> I think I was a bit too verbose with my question. I meant to say:
> the part behind the "|", which originates from a 1:1 conversion of
> the bash based part, is ignored for obvious reasons. But what
> would be a quick way (until I've learned enough on this topic
> myself) to perform the deletion?
> I know that the original, "notmuch search --output=files
> tag:deleted | xargs -L 1 rm" works in the bash script, but for
> the .scm script, everything above (fetching mail, tagging mail)
> works and this part is ignored:
> (system* "notmuch" "search" "--output=files" "tag:deleted" "|" "xargs" "-L"
> "1" "rm")
'system*' doesn't run the shell. You need either 'system' (which
does), or use 'open-pipe*', 'open-input-pipe', etc.