Some additional changes for the release

This commit is contained in:
James Ives 2020-05-24 11:25:38 -04:00
parent 7b5eb6be51
commit fdd6b767e0
3 changed files with 5 additions and 3 deletions

View File

@ -43,7 +43,8 @@ exports.action = {
? core_1.getInput('GIT_CONFIG_EMAIL')
: pusher && pusher.email
? pusher.email
: `${process.env.GITHUB_ACTOR || 'github-pages-deploy-action'}@users.noreply.github.com`,
: `${process.env.GITHUB_ACTOR ||
'github-pages-deploy-action'}@users.noreply.github.com`,
gitHubToken: core_1.getInput('GITHUB_TOKEN'),
name: !util_1.isNullOrUndefined(core_1.getInput('GIT_CONFIG_NAME'))
? core_1.getInput('GIT_CONFIG_NAME')

View File

@ -150,7 +150,7 @@ function deploy(action) {
finally {
// Cleans up temporary files/folders and restores the git state.
core_1.info('Running post deployment cleanup jobs… 🗑️');
yield execute_1.execute(`git worktree remove ${temporaryDeploymentDirectory}`, action.workspace);
yield execute_1.execute(`git worktree remove ${temporaryDeploymentDirectory} --force`, action.workspace);
yield io_1.rmRF(temporaryDeploymentDirectory);
}
});

View File

@ -15,7 +15,8 @@ exports.generateTokenType = (action) => action.ssh
/* Generates a the repository path used to make the commits. */
exports.generateRepositoryPath = (action) => action.ssh
? `git@github.com:${action.repositoryName}`
: `https://${action.accessToken || `x-access-token:${action.gitHubToken}`}@github.com/${action.repositoryName}.git`;
: `https://${action.accessToken ||
`x-access-token:${action.gitHubToken}`}@github.com/${action.repositoryName}.git`;
/* Checks for the required tokens and formatting. Throws an error if any case is matched. */
exports.hasRequiredParameters = (action) => {
if ((exports.isNullOrUndefined(action.accessToken) &&