File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ ---
2+ " @changesets/cli " : patch
3+ ---
4+
5+ Enable guide line for ` add ` command and use box design for dependent patch bump note
Original file line number Diff line number Diff line change 11import c from "@changesets/color" ;
22import type { Release , VersionType } from "@changesets/types" ;
3- import { log } from "@clack/prompts" ;
3+ import { log , note } from "@clack/prompts" ;
44
55export function printConfirmationMessage (
66 changeset : {
@@ -32,12 +32,10 @@ export function printConfirmationMessage(
3232 log . success ( msg ) ;
3333
3434 if ( repoHasMultiplePackages ) {
35- log . info (
36- `
37- Note: All packages that depend on these whose required versions
38- will be incompatible will also be ${ c . blue ( "patch" ) } bumped
39- when this changeset is applied.
40- ` . trim ( ) ,
35+ note (
36+ `All packages that depend on these whose required versions will be incompatible ` +
37+ `will also be ${ c . blue ( "patch" ) } bumped when this changeset is applied.` ,
38+ "NOTE" ,
4139 ) ;
4240 }
4341}
Original file line number Diff line number Diff line change @@ -11,9 +11,15 @@ updateSettings({ withGuide: false });
1111try {
1212 cli . parse ( process . argv , { run : false } ) ;
1313
14- // Do not show intro for --help and --version, which have no command name
15- if ( cli . matchedCommand ?. name != null ) {
16- intro ( `🦋 changeset v${ manifest . version } \n` ) ;
14+ const commandName = cli . matchedCommand ?. name ;
15+
16+ // Enable clack guide for interactive commands
17+ if ( commandName === "add" ) {
18+ updateSettings ( { withGuide : true } ) ;
19+ }
20+ // Show intro when running a command, except for --help and --version (has no command name)
21+ if ( commandName != null ) {
22+ intro ( `🦋 changeset v${ manifest . version } ` ) ;
1723 }
1824
1925 await cli . runMatchedCommand ( ) ;
You can’t perform that action at this time.
0 commit comments