Nuxt/scripts/bump.ts
pooya parsa d991a55ec3
v3.0.0 (#9051)
Co-authored-by: Sébastien Chopin <seb@nuxtjs.com>
2022-11-16 15:56:11 +01:00

22 lines
456 B
TypeScript

import { loadWorkspace } from './_utils'
async function main () {
const workspace = await loadWorkspace(process.cwd())
const newVersion = process.argv[2]
if (!newVersion) {
throw new Error('Please provide version!')
}
for (const pkg of workspace.packages.filter(p => !p.data.private)) {
workspace.setVersion(pkg.data.name, newVersion!)
}
await workspace.save()
}
main().catch((err) => {
console.error(err)
process.exit(1)
})