mirror of
https://github.com/nuxt/nuxt.git
synced 2024-11-22 05:35:13 +00:00
19 lines
430 B
TypeScript
19 lines
430 B
TypeScript
import { readdir } from 'fs/promises'
|
|
import { resolve } from 'upath'
|
|
import { build } from './build'
|
|
|
|
async function main () {
|
|
const pkgsDir = resolve(__dirname, '../packages')
|
|
const pkgs = await readdir(pkgsDir)
|
|
|
|
const stub = process.argv.includes('--stub')
|
|
|
|
for (const pkg of pkgs) {
|
|
const rootDir = resolve(pkgsDir, pkg)
|
|
process.chdir(rootDir)
|
|
await build(rootDir, stub)
|
|
}
|
|
}
|
|
|
|
main().catch(console.error)
|