mirror of
https://github.com/ikechan8370/chatgpt-plugin.git
synced 2025-12-16 21:37:11 +00:00
feat: support dalle image variation
This commit is contained in:
parent
38de2ce714
commit
5fceef37ec
5 changed files with 127 additions and 6 deletions
|
|
@ -2,6 +2,8 @@
|
|||
// import stripMarkdown from 'strip-markdown'
|
||||
import { exec } from 'child_process'
|
||||
import lodash from 'lodash'
|
||||
import fs from 'node:fs'
|
||||
import path from 'node:path'
|
||||
// export function markdownToText (markdown) {
|
||||
// return remark()
|
||||
// .use(stripMarkdown)
|
||||
|
|
@ -205,3 +207,14 @@ async function execSync (cmd) {
|
|||
})
|
||||
})
|
||||
}
|
||||
|
||||
export function mkdirs (dirname) {
|
||||
if (fs.existsSync(dirname)) {
|
||||
return true
|
||||
} else {
|
||||
if (mkdirs(path.dirname(dirname))) {
|
||||
fs.mkdirSync(dirname)
|
||||
return true
|
||||
}
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue