fix: 修复tag问题。

This commit is contained in:
ikechan8370 2023-03-03 21:08:02 +08:00
parent 1d34d7d896
commit 2787acb99c

View file

@ -36,7 +36,7 @@ const defaultConfig = {
debug: true, debug: true,
defaultTimeoutMs: 120000, defaultTimeoutMs: 120000,
chromeTimeoutMS: 120000, chromeTimeoutMS: 120000,
// version: 'v2.0.11', version: 'v2.0.12',
toneStyle: 'balanced' // or creative, precise toneStyle: 'balanced' // or creative, precise
} }
const _path = process.cwd() const _path = process.cwd()
@ -82,8 +82,8 @@ if (fs.existsSync(`${_path}/plugins/chatgpt-plugin/config/config.json`)) {
} }
} }
config = Object.assign({}, defaultConfig, config) config = Object.assign({}, defaultConfig, config)
const latestTag = execSync(`cd ${_path}/plugins/chatgpt-plugin && git describe --tags --abbrev=0`).toString().trim() // const latestTag = execSync(`cd ${_path}/plugins/chatgpt-plugin && git describe --tags --abbrev=0`).toString().trim()
config.version = latestTag // config.version = latestTag
export const Config = new Proxy(config, { export const Config = new Proxy(config, {
set (target, property, value) { set (target, property, value) {