Skip to content

Commit e138c75

Browse files
committed
adapt to beta site
1 parent 10729b2 commit e138c75

1 file changed

Lines changed: 5 additions & 1 deletion

File tree

releaseDocs.ps1

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,11 @@ write-host "`ACTOR is $ACTOR"
99
$SOURCE_DIR=$psscriptroot
1010
$TEMP_REPO_DIR=[System.IO.Path]::GetFullPath("$psscriptroot/../docs-gh-pages")
1111

12-
$remote_repo="https://github-actions:${TOKEN}@github.com/rws/studio-api-docs.git"
12+
# Determine if current repo ends with -beta
13+
$currentRepoName = Split-Path -Leaf $SOURCE_DIR
14+
$betaSuffix = if ($currentRepoName -match '-beta$') { '-beta' } else { '' }
15+
16+
$remote_repo="https://github-actions:${TOKEN}@github.com/rws/studio-api-docs${betaSuffix}.git"
1317

1418
write-host "Cloning the repo $remote_repo with the gh-pages branch"
1519
git clone $remote_repo --branch gh-pages $TEMP_REPO_DIR

0 commit comments

Comments
 (0)