Skip to content

Commit ccf7712

Browse files
authored
Specify cache directory so GH Actions can locate gh-pages cache folder (#2542)
1 parent 2d21519 commit ccf7712

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

packages/core/src/Site/index.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1405,6 +1405,8 @@ export class Site {
14051405
14061406
};
14071407
} else if (process.env.GITHUB_ACTIONS) {
1408+
// Set cache folder to a location Github Actions can find.
1409+
process.env.CACHE_DIR = path.join(process.env.GITHUB_WORKSPACE || '', 'gh-pages', '.cache');
14081410
repoSlug = Site.extractRepoSlug(options.repo, process.env.GITHUB_REPOSITORY);
14091411

14101412
options.user = {

0 commit comments

Comments
 (0)