Skip to content

Commit e5cda33

Browse files
committed
feat(yarn): changesetBaseRefs will not be set when default branch is master
1 parent 46060a0 commit e5cda33

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/actions/CreateYarn2ConfigsAction.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,8 @@ export class CreateYarn2ConfigsAction extends Action {
2424

2525
// Set changesetBaseRefs to default branch (require version plugin)
2626
const changesetBaseRefs = getChangesetBaseRefs(this.userConfigs.defaultBranch);
27-
await runCommand("yarn", ["config", "set", "changesetBaseRefs", changesetBaseRefs]);
27+
this.userConfigs.defaultBranch !== "master" &&
28+
(await runCommand("yarn", ["config", "set", "changesetBaseRefs", changesetBaseRefs]));
2829

2930
// Remove old .yarnrc
3031
await removeFile(withCurrentDir("./.yarnrc"));

0 commit comments

Comments
 (0)