chore(scripts): cleanup release script
This commit is contained in:
@@ -1,18 +1,18 @@
|
|||||||
import type { ExecSyncOptions } from 'child_process'
|
import type { ExecSyncOptions } from 'child_process'
|
||||||
import { execSync } from 'child_process'
|
|
||||||
|
|
||||||
import chalk from 'chalk'
|
import chalk from 'chalk'
|
||||||
|
import { execSync } from 'child_process'
|
||||||
import execa from 'execa'
|
import execa from 'execa'
|
||||||
import fse from 'fs-extra'
|
import fse from 'fs-extra'
|
||||||
import minimist from 'minimist'
|
import minimist from 'minimist'
|
||||||
|
import { fileURLToPath } from 'node:url'
|
||||||
import path from 'path'
|
import path from 'path'
|
||||||
import prompts from 'prompts'
|
import prompts from 'prompts'
|
||||||
import semver from 'semver'
|
import semver from 'semver'
|
||||||
import simpleGit from 'simple-git'
|
import { simpleGit } from 'simple-git'
|
||||||
|
|
||||||
import { getPackageDetails } from './lib/getPackageDetails'
|
import { getPackageDetails } from './lib/getPackageDetails.js'
|
||||||
import { updateChangelog } from './utils/updateChangelog'
|
import { updateChangelog } from './utils/updateChangelog.js'
|
||||||
import { fileURLToPath } from 'url'
|
|
||||||
|
|
||||||
// Update this list with any packages to publish
|
// Update this list with any packages to publish
|
||||||
const packageWhitelist = [
|
const packageWhitelist = [
|
||||||
@@ -37,6 +37,8 @@ const cwd = path.resolve(__dirname, '..')
|
|||||||
const git = simpleGit(cwd)
|
const git = simpleGit(cwd)
|
||||||
|
|
||||||
const execOpts: ExecSyncOptions = { stdio: 'inherit' }
|
const execOpts: ExecSyncOptions = { stdio: 'inherit' }
|
||||||
|
const execaOpts: execa.Options = { stdio: 'inherit' }
|
||||||
|
|
||||||
const args = minimist(process.argv.slice(2))
|
const args = minimist(process.argv.slice(2))
|
||||||
|
|
||||||
const {
|
const {
|
||||||
@@ -128,8 +130,6 @@ async function main() {
|
|||||||
// Prebuild all packages
|
// Prebuild all packages
|
||||||
header(`\n🔨 Prebuilding all packages...`)
|
header(`\n🔨 Prebuilding all packages...`)
|
||||||
|
|
||||||
const execaOpts: execa.Options = { ...execOpts, stdio: 'inherit' }
|
|
||||||
|
|
||||||
await execa('pnpm', ['install'], execaOpts)
|
await execa('pnpm', ['install'], execaOpts)
|
||||||
|
|
||||||
const buildResult = await execa('pnpm', ['build:core', '--output-logs=errors-only'], execaOpts)
|
const buildResult = await execa('pnpm', ['build:core', '--output-logs=errors-only'], execaOpts)
|
||||||
|
|||||||
Reference in New Issue
Block a user