Anomareh/mynt — pull request #7 by href (2012-02-18 12:58:08+00:00)
Title: Remove Files from Destination Instead of Deleting the Folder Itself

Hi!

I'm trying out mynt for a personal project.

I'm checking my generated output using SimpleHTTPServer like this:

cd _site
python -m SimpleHTTPServer

I can then look at my site through localhost:8000 to test it in different browsers on different virtual machines.

What's a bit annoying in this usecae is the fact that `mynt _site -f`will always delete the _site directory, rebuilding it afterwards. And this does not go well with SimpleHTTPServer (or other tools really, like symbolic links or folder-watch tools).

I went ahead and changed the behavior of the generator to delete the contents of the destination folder instead of the folder itself, enabling me to use SimpleHTTPServer without restarting it after each generation.

Hopefully, you'll find this useful as well :)

In any case, thanks for mynt!

Denis