File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 11import { defineConfig } from "vitepress" ;
22import { withPwa } from "@vite-pwa/vitepress" ;
33import { groupIconVitePlugin } from "vitepress-plugin-group-icons" ;
4+ import { spawnSync } from "node:child_process" ;
45
56const SITE_URL = "https://cli.fishxcode.com" ;
67const SITE_TITLE = "FishXCode CLI" ;
78const SITE_DESC =
89 "AI 编码工具管理器 — 一键接入 FishXCode API,支持 claude-code、aider、codex、opencode 等主流工具" ;
910
1011const BASE = ( process . env . VITEPRESS_BASE ?? "/" ) . replace ( / ( [ ^ / ] ) $ / , "$1/" ) ;
12+ const hasGit = spawnSync ( "git" , [ "--version" ] , { stdio : "ignore" } ) . status === 0 ;
1113
1214function p ( path : string ) {
1315 return BASE . replace ( / \/ $ / , "" ) + path ;
@@ -18,7 +20,7 @@ export default withPwa(
1820 base : BASE ,
1921 title : SITE_TITLE ,
2022 description : SITE_DESC ,
21- lastUpdated : true ,
23+ lastUpdated : hasGit ,
2224 cleanUrls : true ,
2325 srcExclude : [ "**/CLAUDE.md" ] ,
2426 rewrites : {
You can’t perform that action at this time.
0 commit comments