cpm-cmake/CPM.cmake

cpm git fetch is occasionally empty

Febbe opened this issue · 1 comments

Sometimes, automated builds on our build server fails due to the fact, that cpm failed to clone a dependency.
The resulting folder is just empty and cpm warns that the repository is dirty.

I could not find the cause of this behavior, but having a force checkout option, if the directory is dirty, will hopefully query a new clone attempt.

This is similar to #548
The cache dir is created before download, if download is aborted for any reason the directory must be deleted manually