mirror of
https://github.com/JamesIves/github-pages-deploy-action.git
synced 2023-12-15 20:03:39 +08:00
Debugging
This commit is contained in:
parent
df3cf28e75
commit
fc94a2604d
@ -14,7 +14,7 @@ exports.workspace = process.env.GITHUB_WORKSPACE;
|
||||
exports.folder = core.getInput("FOLDER", { required: true });
|
||||
// Required action data.
|
||||
exports.action = {
|
||||
build: exports.folder === '.' ? exports.workspace : exports.folder,
|
||||
build: exports.folder,
|
||||
gitHubRepository: repository ? repository.full_name : "",
|
||||
gitHubToken: core.getInput("GITHUB_TOKEN"),
|
||||
accessToken: core.getInput("ACCESS_TOKEN"),
|
||||
|
@ -97,7 +97,7 @@ function deploy() {
|
||||
recursive: true,
|
||||
force: true
|
||||
});*/
|
||||
yield util_1.execute(`rsync -av --progress ${constants_1.action.build}/. ${temporaryDeploymentDirectory} --exclude .git`, constants_1.workspace);
|
||||
yield util_1.execute(`rsync -av --progress ${constants_1.action.build}/. ${temporaryDeploymentDirectory} --exclude .git ${constants_1.action.build === '.' && `--exclude ${temporaryDeploymentDirectory}`}`, constants_1.workspace);
|
||||
// Commits to GitHub.
|
||||
yield util_1.execute(`git add --all .`, temporaryDeploymentDirectory);
|
||||
yield util_1.execute(`git switch -c ${temporaryDeploymentBranch}`, temporaryDeploymentDirectory);
|
||||
|
@ -8,7 +8,7 @@ export const folder = core.getInput("FOLDER", { required: true });
|
||||
|
||||
// Required action data.
|
||||
export const action = {
|
||||
build: folder === '.' ? workspace : folder,
|
||||
build: folder,
|
||||
gitHubRepository: repository ? repository.full_name : "",
|
||||
gitHubToken: core.getInput("GITHUB_TOKEN"),
|
||||
accessToken: core.getInput("ACCESS_TOKEN"),
|
||||
|
@ -91,7 +91,7 @@ export async function deploy(): Promise<any> {
|
||||
force: true
|
||||
});*/
|
||||
|
||||
await execute(`rsync -av --progress ${action.build}/. ${temporaryDeploymentDirectory} --exclude .git`, workspace)
|
||||
await execute(`rsync -av --progress ${action.build}/. ${temporaryDeploymentDirectory} --exclude .git ${action.build === '.' && `--exclude ${temporaryDeploymentDirectory}`}`, workspace)
|
||||
|
||||
// Commits to GitHub.
|
||||
await execute(`git add --all .`, temporaryDeploymentDirectory);
|
||||
|
Loading…
Reference in New Issue
Block a user