改成默认github用 main 分支

This commit is contained in:
陆柯 2021-08-24 11:43:01 +08:00
parent c50d29c072
commit 8991abbdd7

View File

@ -25,7 +25,7 @@ const wo = (global.wo = {
github: { github: {
targetType: 'git', targetType: 'git',
repo: undefined, repo: undefined,
branch: 'master', branch: 'main',
gitname: undefined, gitname: undefined,
gitemail: undefined, gitemail: undefined,
user: undefined, user: undefined,
@ -207,7 +207,7 @@ function deployToGit(connection){
const path = match[2] const path = match[2]
if (host === 'github.com') { if (host === 'github.com') {
branch = rGithubPage.test(path) ? 'master' : 'gh-pages' branch = rGithubPage.test(path) ? (connection.branch || 'main') : 'gh-pages'
} else if (host === 'coding.net') { } else if (host === 'coding.net') {
branch = 'coding-pages' branch = 'coding-pages'
} }