Skip to content

Commit

Permalink
Warn on install commands if nothing was built
Browse files Browse the repository at this point in the history
Summary: Warn the user if there are no targets instead of reporting `INSTALL SUCCEEDED` to match `build` commands.

Reviewed By: JakobDegen

Differential Revision: D57188780

fbshipit-source-id: ed206154d5502c9a3443f45555328f857ace8772
  • Loading branch information
christolliday authored and facebook-github-bot committed May 10, 2024
1 parent fc89685 commit 25ad1ec
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion app/buck2_client/src/commands/install.rs
Expand Up @@ -201,7 +201,11 @@ impl StreamingCommand for InstallCommand {

match response {
CommandOutcome::Success(_) => {
console.print_success("INSTALL SUCCEEDED")?;
if self.patterns.is_empty() {
console.print_warning("NO BUILD TARGET PATTERNS SPECIFIED")?;
} else {
console.print_success("INSTALL SUCCEEDED")?;
}
ExitResult::success()
}
CommandOutcome::Failure(exit_result) => {
Expand Down

0 comments on commit 25ad1ec

Please sign in to comment.