Skip to content

Commit

Permalink
ci: fix version of docs
Browse files Browse the repository at this point in the history
  • Loading branch information
QuadStingray committed Oct 24, 2023
1 parent 2ced42a commit cb1a445
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 17 deletions.
5 changes: 4 additions & 1 deletion .github/workflows/release_and_changelog.yml
Original file line number Diff line number Diff line change
Expand Up @@ -46,5 +46,8 @@ jobs:
with:
version: 6.0.2

- name: Update versions file
run: 'echo "{\"mongocamp\": \"${{ github.ref_name }}\"}" > ./docs/versions.json'

- name: Build and deploy Docu
run: sbt ci-deploy-docs
run: sh ./deploy_ghpages.sh
14 changes: 0 additions & 14 deletions build_docu.sbt

This file was deleted.

5 changes: 3 additions & 2 deletions docs/.vitepress/config.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import Unocss from 'unocss/vite'
import {defineConfig} from 'vitepress'
import {version} from '../../package.json'
import fs from 'fs'

export default defineConfig({
lang: 'en-US',
Expand Down Expand Up @@ -43,13 +43,14 @@ export default defineConfig({
})

function nav() {
var versionInfos = JSON.parse(fs.readFileSync('docs/versions.json', 'utf-8'))
return [
{text: 'Guide', link: '/guide/', activeMatch: '/guide/'},
{text: 'Config', link: '/config/', activeMatch: '/config/'},
{text: 'Plugins', link: '/plugins/', activeMatch: '/plugins/'},
{text: 'REST API', link: '/rest/README', activeMatch: '/rest/'},
{
text: version,
text: versionInfos.mongocamp,
items: [
{
text: 'Changelog',
Expand Down
1 change: 1 addition & 0 deletions docs/versions.json
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{"mongocamp": "1.5.8"}

0 comments on commit cb1a445

Please sign in to comment.