diff --git a/README.md b/README.md index fc4a3c1..22e54a5 100644 --- a/README.md +++ b/README.md @@ -68,7 +68,7 @@ deploy: - Defaults to `coding-pages` on Coding.net. - Otherwise defaults to `master`. - **token**: Optional token value to authenticate with the repo. Prefix with `$` to read token from environment variable (recommended). Repo must be a http(s) url. [More details](#deploy-with-token). - - **token_name** coding.net needs token name and token to authenticate. [More details](#deploy-with-token) + - **token_name** only valid for coding.net, coding.net needs token name and token to authenticate. [More details](#deploy-with-token) - **repo_name**: Unique name when deploying to multiple repositories. * Example: ``` yaml diff --git a/lib/parse_config.js b/lib/parse_config.js index 7bacb06..d1b548b 100644 --- a/lib/parse_config.js +++ b/lib/parse_config.js @@ -31,7 +31,7 @@ function parseObjRepo(repo) { } else { userToken = configToken; } - if (token_name && repoUrl.host === 'e.coding.net') { + if (token_name && repoUrl.host.includes('coding.net')) { repoUrl.username = token_name; repoUrl.password = userToken; } else {