Skip to content

Commit

Permalink
docs: fix docs build
Browse files Browse the repository at this point in the history
  • Loading branch information
vikiboss committed Dec 6, 2024
1 parent a4a5dff commit 3afb4ce
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions docs/scripts/build-docs.ts
Original file line number Diff line number Diff line change
@@ -1,16 +1,15 @@
import 'zx/globals'

const isSoDoc = process.env.PIPLINENAME === 'SODOC'
const __dirname = new URL('.', import.meta.url).pathname

if (isSoDoc) {
process.env.IS_SODOC = 'true'

await $`pnpm add @alita/rspress-plugin@^1.5.0-beta.2 @shein/rspress-plugin-sodoc`
await $`pnpm add @alita/rspress-plugin@^1.6.3 @shein/rspress-plugin-sodoc`
}

await $`rspress build`

if (isSoDoc) {
await $({ cwd: __dirname })`cp -r ../docs-dist ../../docs-dist`
await $`cp -r ./docs-dist ../docs-dist`
}

0 comments on commit 3afb4ce

Please sign in to comment.