You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

23 lines
564 B

const fsPromises = require('fs/promises')
const path = require('path')
const server = require('../server')
const exportFile = path.join(__dirname, 'moddef.json')
async function main() {
const def = await server.getModulesDefinitions(
path.join(__dirname, '..', 'module'),
{
'daily_signin.js': '/daily_signin',
'fm_trash.js': '/fm_trash',
'personal_fm.js': '/personal_fm',
},
false,
)
fsPromises.writeFile(exportFile, JSON.stringify(def, null, 4))
console.log(`👍 Get your own definition at: ${exportFile}`)
}
main()