heroku / heroku-repo

Plugin for heroku CLI that can manipulate the repo
MIT License
682 stars 111 forks source link

Use absolute file names when extracting the tar #100

Closed JamesHarker closed 5 months ago

JamesHarker commented 3 years ago

When trying to run the repo:purge_cache command it kept failing with the following errors:

tar: ./heroku-16/vendor/bundle/ruby: Directory renamed before its status could be extracted
tar: ./heroku-16/vendor/bundle: Directory renamed before its status could be extracted
tar: ./heroku-16/vendor: Directory renamed before its status could be extracted
tar: ./heroku-16: Directory renamed before its status could be extracted
tar: Exiting with failure status due to previous errors

I think something in our existing slug was using relative paths (../) which was causing the tar to fail. The tar is extracted successfully if we simply add the --absolute-names (-P) flag 1

mantrala commented 3 years ago

+1