File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -198,7 +198,7 @@ impl<'a> CompositionGraphBuilder<'a> {
198198 ) ;
199199 }
200200
201- log:: warn !(
201+ log:: info !(
202202 "instance `{name}` will be imported because a dependency named `{component_name}` could not be found"
203203 ) ;
204204 Ok ( None )
Original file line number Diff line number Diff line change @@ -45,6 +45,10 @@ pub struct Opts {
4545 /// Output the text format of WebAssembly instead of the binary format.
4646 #[ clap( short = 't' , long) ]
4747 wat : bool ,
48+
49+ /// Don't print warnings.
50+ #[ clap( short, long) ]
51+ quiet : bool ,
4852}
4953
5054impl Opts {
@@ -53,11 +57,13 @@ impl Opts {
5357 }
5458
5559 pub fn run ( self ) -> Result < ( ) > {
56- eprintln ! ( "WARNING: `wasm-tools compose` has been deprecated." ) ;
57- eprintln ! ( "" ) ;
58- eprintln ! (
59- "Please use `wac` instead. You can find more information about `wac` at https://github.com/bytecodealliance/wac."
60- ) ;
60+ if !self . quiet {
61+ eprintln ! ( "WARNING: `wasm-tools compose` has been deprecated." ) ;
62+ eprintln ! ( "" ) ;
63+ eprintln ! (
64+ "Please use `wac` instead. You can find more information about `wac` at https://github.com/bytecodealliance/wac."
65+ ) ;
66+ }
6167 let config = self . create_config ( ) ?;
6268 log:: debug!( "configuration:\n {config:#?}" ) ;
6369
@@ -82,7 +88,9 @@ impl Opts {
8288 }
8389
8490 if let Some ( path) = self . output . output_path ( ) {
85- println ! ( "composed component `{}`" , path. display( ) ) ;
91+ if !self . quiet {
92+ println ! ( "composed component `{}`" , path. display( ) ) ;
93+ }
8694 }
8795
8896 Ok ( ( ) )
You can’t perform that action at this time.
0 commit comments