fileoverview author import { writeFileSync } from 'fs' ; import { resolve } from 'path' ; import { createIndex } from './lib/utils' ; import { updateRuleDocs } from './update-rule-docs' ; updateRuleDocs ( ) ; import './update-docs-index' ; import './update-recommended-rules' ; main ( ) ; async function main ( ) { for ( const pairs of [ [ resolve ( __dirname , '../lib/configs' ) ] , [ resolve ( __dirname , '../lib/rules' ) ] , [ resolve ( __dirname , '../lib/utils' ) , '' , true ] ] as const ) { const [ dirPath , prefix , all ] = pairs ; writeFileSync ( `${ dirPath }.ts` , await createIndex ( dirPath , prefix , all ) ) ; } }