Skip to content

Commit

Permalink
fix: 修改domain 的域名
Browse files Browse the repository at this point in the history
  • Loading branch information
zerolee1231 committed Dec 13, 2023
1 parent a363581 commit 361e826
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions .vitepress/config.mts
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ const branchInfo = await simpleGit('.', {}).pull().branch({});
const { current, branches } = branchInfo;
const isMain = current === 'main';
const base = isMain ? '/' : `/${current}/`;
const domian = '//docs.deepwisdom.ai';
const domain = 'https://docs.deepwisdom.ai';
const versions = Object.keys(branches).reduce((vs, branchname) => {
const regex = /^remotes\/origin\/(v.*)$/;
const [, remotebn] = regex.exec(branchname) || [];
Expand All @@ -56,11 +56,11 @@ const getVersions = () => {
text: current,
items: [
...(!isMain
? [{ text: 'latest', link: `${domian}`, target: '_blank' }]
? [{ text: 'latest', link: `${domain}`, target: '_blank' }]
: []),
...versions.map((v) => ({
text: v,
link: `${domian}/${v}/`,
link: `${domain}/${v}/`,
target: '_blank',
})),
],
Expand Down

0 comments on commit 361e826

Please sign in to comment.