mirror of
https://github.com/Tencent/tmagic-editor.git
synced 2025-05-29 19:39:19 +08:00
chore: 修改发布脚本,使用pnpm发布
This commit is contained in:
parent
04a72da06c
commit
978391fe90
@ -186,16 +186,10 @@ async function publishPackage(pkgName, version, runIfNotDry) {
|
|||||||
|
|
||||||
step(`Publishing ${pkgName}...`);
|
step(`Publishing ${pkgName}...`);
|
||||||
try {
|
try {
|
||||||
await runIfNotDry(
|
await runIfNotDry('pnpm', ['publish', ...(releaseTag ? ['--tag', releaseTag] : []), '--access', 'public'], {
|
||||||
// note: use of yarn is intentional here as we rely on its publishing
|
|
||||||
// behavior.
|
|
||||||
'yarn',
|
|
||||||
['publish', '--new-version', version, ...(releaseTag ? ['--tag', releaseTag] : []), '--access', 'public'],
|
|
||||||
{
|
|
||||||
cwd: pkgRoot,
|
cwd: pkgRoot,
|
||||||
stdio: 'pipe',
|
stdio: 'pipe',
|
||||||
},
|
});
|
||||||
);
|
|
||||||
console.log(chalk.green(`Successfully published ${pkgName}@${version}`));
|
console.log(chalk.green(`Successfully published ${pkgName}@${version}`));
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
if (e.stderr.match(/previously published/)) {
|
if (e.stderr.match(/previously published/)) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user