tschaub/gh-pages

Filename to long error due to cache changes

cniesen opened this issue · 0 comments

Release 3.1.0 has a breaking change, at least for me. Would have been nice if that change was documented in the release notes.

PR 362 changed the path of the cache from a relative to an absolute path. This turned out to be detrimental for my deploys from MS Window OS that has is stricter with path lengths. Therefore the following error is being displayed:
error: cannot stat 'foo.bar': Filename too long

My hack to fix this issue is to set the CACHE_DIR in package.json
set CACHE_DIR=/tmp&& gh-pages ...
Note the lack of space between the cache directory name and the ampersands. I've tested it only with the windows command line and in Git Bash so I'm not sure if that's an universal fix.

I'm not sure if there is any better solution for the project to shorten the cache path.

BTW, thanks for the great work on gh-pages and the continuing maintenance of it.