bf_copy question

R Kimber richardkimber at btinternet.com
Sat Jul 25 12:35:40 CEST 2015


On Fri, 24 Jul 2015 14:35:34 +0100
R Kimber wrote:

> This may seem a naive question, but what exactly does bf_copy do?
> 
> the syntax is bf_copy <path>/A <path>/B and the manpage says that it
> copies a bogofilter working directory to another directory.  But does
> this mean that it only copies the contents of A to the pre-existing
> directory B, or does assume B does not exist and tries to create B first?
> If the latter, what error code does it produce if B already exists?
> 
> The reason why I ask is that I use it in a backup script and at the point
> where bf_copy is running I get a message via cron saying
>    mkdir: cannot create directory ‘<path>/.bogofilter’: File exists
> the script does not use mkdir, so I'm assuming the error comes from
> bf_copy.

Sorry, please ignore thabove.  Whe I wrote it I assumed bf_copy would be
binary, but I realise it's a script and can now see how it works, and  have
inserted a test before the offending mkdir.

- Richard.
-- 
Richard Kimber



More information about the bogofilter mailing list