small fix to ensure compressed file path parents are created before compressing

I imagine you'll want this coded slightly differently, but this illustrates the problem.