[CMake] cmake -E remove -f

Craig Scott craig.scott at crascit.com
Wed Apr 5 19:35:23 EDT 2017


Yes, but in both cases the directory foo is still not deleted! At least on
OSX any way.

On Thu, Apr 6, 2017 at 9:22 AM, Mark Ferry <mark at cognomen.co.uk> wrote:

> Hi Craig
>
> On Thu, 06 Apr 2017 08:55:58 +1000, Craig Scott wrote:
> > Can anyone identify a scenario where the -f option to the CMake command
> > mode's "remove" command makes any difference?
> >
>
> How about removing directories:
>
> ~/src/cmake-test$ cmake --version
> cmake version 3.0.2
>
> CMake suite maintained and supported by Kitware (kitware.com/cmake).
> ~/src/cmake-test$ mkdir foo
>
> ~/src/cmake-test$ cmake -E remove foo
> ~/src/cmake-test$ echo $?
> 1
>
> ~/src/cmake-test$ cmake -E remove -f foo
> ~/src/cmake-test$ echo $?
> 0
>
>
>
> --
> Cognomen Ltd
> http://cognomen.co.uk
> +44 7855 790184
>



-- 
Craig Scott
Melbourne, Australia
https://crascit.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/cmake/attachments/20170406/5679c2b4/attachment.html>


More information about the CMake mailing list