Answer the question
In order to leave comments, you need to log in
In a sh script, extract all but one line from a file and paste it into a command?
Dear community, hello.
Please tell me how to make such a construction:
I need all the lines from the file (subscriptions), except for the line containing the word (Spam)
grep -v -w "Spam" /var/www/site/.maildir/subscriptions
sa-learn --ham /var/www/site/.maildir/cur/"Сюда вставить строки по одной"
Answer the question
In order to leave comments, you need to log in
grep -v -w "Spam" /var/www/site/.maildir/subscriptions | xargs -i sa-learn --ham /var/www/site/.maildir/cur/{}
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question