@@ -323,53 +323,6 @@ namespace vix::commands::BuildCommand
323323 std::cout << std::flush;
324324 }
325325
326- static void watch_print_started (
327- const WatchDisplayContext &display,
328- const vix::engine::watch::Batch &batch,
329- WatchDisplayAction action,
330- bool structuralChange)
331- {
332- if (display.verbose )
333- return ;
334-
335- const bool configurationChange =
336- action == WatchDisplayAction::Reconfigured;
337-
338- const std::string subject =
339- watch_change_subject (
340- batch,
341- display.projectDir ,
342- configurationChange,
343- structuralChange);
344-
345- const char *phaseColor = CYAN ;
346- const char *phase = " Building" ;
347- const char *detail = " incremental graph" ;
348-
349- if (configurationChange)
350- {
351- phase = " Configuring" ;
352- detail = " project graph" ;
353- }
354- else if (structuralChange)
355- {
356- phaseColor = YELLOW ;
357- detail = " project structure" ;
358- }
359-
360- std::ostringstream changeLine;
361- changeLine << watch_label (MAGENTA , " Change" )
362- << WATCH_PRIMARY << subject << RESET ;
363-
364- watch_print_line (display, changeLine.str ());
365-
366- std::ostringstream phaseLine;
367- phaseLine << watch_label (phaseColor, phase)
368- << detail;
369-
370- watch_print_line (display, phaseLine.str ());
371- }
372-
373326 static bool watch_is_ninja_progress_line (const std::string &line)
374327 {
375328 if (line.empty () || line.front () != ' [' )
@@ -479,7 +432,8 @@ namespace vix::commands::BuildCommand
479432 const vix::engine::watch::Batch &batch,
480433 WatchDisplayAction action,
481434 bool structuralChange,
482- long long ms)
435+ long long ms,
436+ std::string detail = {})
483437 {
484438 if (display.verbose )
485439 return ;
@@ -519,6 +473,9 @@ namespace vix::commands::BuildCommand
519473 << watch_format_duration (ms)
520474 << RESET ;
521475
476+ if (!detail.empty ())
477+ line << GRAY << " (" << detail << " )" << RESET ;
478+
522479 watch_print_line (display, line.str ());
523480 }
524481
@@ -5120,15 +5077,6 @@ namespace vix::commands::BuildCommand
51205077 displayBatch.events .push_back (
51215078 {vix::engine::watch::EventKind::Modified, source, {}, false });
51225079
5123- if (compactWatchOutput)
5124- {
5125- watch_print_started (
5126- display,
5127- displayBatch,
5128- WatchDisplayAction::Rebuilt,
5129- false );
5130- }
5131-
51325080 if (!buildOpt.quiet && !compactWatchOutput)
51335081 std::cout << " \n change " << source.filename ().string () << " \n " ;
51345082
@@ -5360,15 +5308,6 @@ namespace vix::commands::BuildCommand
53605308 }
53615309 }
53625310
5363- if (compactWatchOutput)
5364- {
5365- watch_print_started (
5366- display,
5367- *batchOpt,
5368- action,
5369- false );
5370- }
5371-
53725311 if (!buildOpt.quiet && !compactWatchOutput)
53735312 {
53745313 if (batchOpt->events .size () == 1 )
@@ -5467,7 +5406,8 @@ namespace vix::commands::BuildCommand
54675406 *batchOpt,
54685407 action,
54695408 false ,
5470- ms);
5409+ ms,
5410+ sourceOnlyChange ? std::string () : std::string (" full refresh" ));
54715411 else
54725412 watch_print_failed (
54735413 display,
@@ -5692,15 +5632,6 @@ namespace vix::commands::BuildCommand
56925632 const build::BuildGraphInvalidationResult &invalidation,
56935633 const vix::engine::watch::Batch &batch) -> int
56945634 {
5695- if (compactWatchOutput)
5696- {
5697- watch_print_started (
5698- watchDisplay,
5699- batch,
5700- WatchDisplayAction::Rebuilt,
5701- false );
5702- }
5703-
57045635 const auto t0 = std::chrono::steady_clock::now ();
57055636
57065637 if (sessionOpt.explain && !sessionOpt.quiet )
@@ -5855,15 +5786,6 @@ namespace vix::commands::BuildCommand
58555786 ? WatchDisplayAction::Reconfigured
58565787 : WatchDisplayAction::Rebuilt;
58575788
5858- if (compactWatchOutput)
5859- {
5860- watch_print_started (
5861- watchDisplay,
5862- batch,
5863- action,
5864- action == WatchDisplayAction::Rebuilt);
5865- }
5866-
58675789 const auto t0 = std::chrono::steady_clock::now ();
58685790 WatchCapturedRun run = run_full_refresh ();
58695791 lastCode = run.code ;
@@ -5883,7 +5805,8 @@ namespace vix::commands::BuildCommand
58835805 batch,
58845806 action,
58855807 action == WatchDisplayAction::Rebuilt,
5886- ms);
5808+ ms,
5809+ " full refresh" );
58875810 else
58885811 watch_print_failed (
58895812 watchDisplay,
@@ -5926,15 +5849,6 @@ namespace vix::commands::BuildCommand
59265849 ? WatchDisplayAction::Reconfigured
59275850 : WatchDisplayAction::Rebuilt;
59285851
5929- if (compactWatchOutput)
5930- {
5931- watch_print_started (
5932- watchDisplay,
5933- batch,
5934- action,
5935- action == WatchDisplayAction::Rebuilt);
5936- }
5937-
59385852 const auto t0 = std::chrono::steady_clock::now ();
59395853 WatchCapturedRun run = run_full_refresh ();
59405854 lastCode = run.code ;
@@ -5954,7 +5868,8 @@ namespace vix::commands::BuildCommand
59545868 batch,
59555869 action,
59565870 action == WatchDisplayAction::Rebuilt,
5957- ms);
5871+ ms,
5872+ " full refresh" );
59585873 else
59595874 watch_print_failed (
59605875 watchDisplay,
0 commit comments