diff --git a/crates/vite_task/src/schedule.rs b/crates/vite_task/src/schedule.rs index 66c832a506..365fa6f3a8 100644 --- a/crates/vite_task/src/schedule.rs +++ b/crates/vite_task/src/schedule.rs @@ -14,6 +14,7 @@ use crate::{ config::{DisplayOptions, ResolvedTask, Workspace}, execute::{OutputKind, execute_task}, fs::FileSystem, + ui::get_display_command, }; #[derive(Debug)] @@ -26,6 +27,7 @@ pub struct ExecutionPlan { /// Status of a task before execution #[derive(Debug, Serialize, Deserialize, Clone)] pub struct PreExecutionStatus { + pub display_command: Option, pub task: ResolvedTask, pub cache_status: CacheStatus, pub display_options: DisplayOptions, @@ -148,7 +150,12 @@ impl ExecutionPlan { .await?; let has_inner_runner = step.resolved_config.config.command.has_inner_runner(); - let pre_execution_status = PreExecutionStatus { task: step, cache_status, display_options }; + let pre_execution_status = PreExecutionStatus { + display_command: get_display_command(display_options, &step), + task: step, + cache_status, + display_options, + }; // The inner runner is expected to display the command and the cache status. The outer runner will skip displaying them. if !has_inner_runner { diff --git a/crates/vite_task/src/ui.rs b/crates/vite_task/src/ui.rs index 1c2a8340ff..bbf0f02615 100644 --- a/crates/vite_task/src/ui.rs +++ b/crates/vite_task/src/ui.rs @@ -6,6 +6,7 @@ use vite_path::RelativePath; use crate::{ cache::{CacheMiss, FingerprintMismatch}, + config::{DisplayOptions, ResolvedTask}, fingerprint::PostRunFingerprintMismatch, schedule::{CacheStatus, ExecutionFailure, ExecutionSummary, PreExecutionStatus}, }; @@ -22,27 +23,38 @@ impl ColorizeExt for T { } } +const COMMAND_STYLE: Style = Style::new().cyan(); +const CACHE_MISS_STYLE: Style = Style::new().purple(); + +pub fn get_display_command(display_options: DisplayOptions, task: &ResolvedTask) -> Option { + let display_command = if display_options.hide_command { + if let Ok(outer_command) = std::env::var("VITE_OUTER_COMMAND") { + outer_command + } else { + return None; + } + } else { + task.resolved_command.fingerprint.command.to_string() + }; + + let cwd = task.resolved_command.fingerprint.cwd.as_str(); + Some(format!( + "{}$ {}", + if cwd.is_empty() { format_args!("") } else { format_args!("~/{}", cwd) }, + display_command + )) +} + /// Displayed before the task is executed impl Display for PreExecutionStatus { fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result { - let display_command = format!("$ {}", &self.task.resolved_command.fingerprint.command); - let outer_command = - format!("$ {}", std::env::var("VITE_OUTER_COMMAND").unwrap_or_default()); - let display_command: Option> = if self.display_options.hide_command { - if outer_command != "$ " { - Some(outer_command.style(Style::new().cyan())) - } else { - None - } - } else { - Some(display_command.style(Style::new().cyan())) - }; + let display_command = self.display_command.as_ref().map(|cmd| cmd.style(COMMAND_STYLE)); // Print cache status with improved, shorter messages match &self.cache_status { CacheStatus::CacheMiss(CacheMiss::NotFound) => { // No message for "Cache not found" as requested - tracing::debug!("{}", "Cache not found".style(Style::new().yellow())); + tracing::debug!("{}", "Cache not found".style(CACHE_MISS_STYLE)); if let Some(display_command) = &display_command { writeln!(f, "{}", display_command)?; } @@ -86,7 +98,7 @@ impl Display for PreExecutionStatus { format_args!("✗ cache miss: {}, executing", reason), if display_command.is_some() { ")" } else { "" }, ) - .style(Style::new().yellow().dimmed()) + .style(CACHE_MISS_STYLE.dimmed()) )?; } CacheStatus::CacheHit => { @@ -166,7 +178,7 @@ impl Display for ExecutionSummary { "Statistics:".style(Style::new().bold()), format!("{} tasks", total).style(Style::new().bright_white()), format!("• {} cache hits", cache_hits).style(Style::new().green()), - format!("• {} cache misses", cache_misses).style(Style::new().yellow()), + format!("• {} cache misses", cache_misses).style(CACHE_MISS_STYLE), if failed > 0 { format!("• {} failed", failed).style(Style::new().red()).to_string() } else if skipped > 0 { @@ -186,7 +198,7 @@ impl Display for ExecutionSummary { cache_rate.to_string().style(if cache_rate >= 75 { Style::new().green().bold() } else if cache_rate >= 50 { - Style::new().yellow() + CACHE_MISS_STYLE } else { Style::new().red() }) @@ -212,6 +224,10 @@ impl Display for ExecutionSummary { task_name.style(Style::new().bright_white().bold()) )?; + if let Some(display_command) = &status.pre_execution_status.display_command { + write!(f, ": {}", display_command.style(COMMAND_STYLE))?; + } + // Execution result icon and status match &status.execution_result { Ok(exit_status) if *exit_status == 0 => { @@ -246,14 +262,14 @@ impl Display for ExecutionSummary { )?; } CacheStatus::CacheMiss(miss) => { - write!(f, " {}", "→ Cache miss: ".style(Style::new().yellow()))?; + write!(f, " {}", "→ Cache miss: ".style(CACHE_MISS_STYLE))?; match miss { CacheMiss::NotFound => { writeln!( f, "{}", - "no previous cache entry found".style(Style::new().yellow()) + "no previous cache entry found".style(CACHE_MISS_STYLE) )?; } CacheMiss::FingerprintMismatch(mismatch) => { @@ -336,13 +352,13 @@ impl Display for ExecutionSummary { writeln!( f, "{}", - "configuration changed".style(Style::new().yellow()) + "configuration changed".style(CACHE_MISS_STYLE) )?; } else { writeln!( f, "{}", - changes.join("; ").style(Style::new().yellow()) + changes.join("; ").style(CACHE_MISS_STYLE) )?; } } @@ -353,7 +369,7 @@ impl Display for ExecutionSummary { f, "{}", format!("content of input '{}' changed", path) - .style(Style::new().yellow()) + .style(CACHE_MISS_STYLE) )?; } } diff --git a/packages/cli/snap-tests/associate-existing-cache/snap.txt b/packages/cli/snap-tests/associate-existing-cache/snap.txt index 6031ae6f99..74ba783a39 100644 --- a/packages/cli/snap-tests/associate-existing-cache/snap.txt +++ b/packages/cli/snap-tests/associate-existing-cache/snap.txt @@ -12,7 +12,7 @@ Performance: 0% cache hit rate Task Details: ──────────────────────────────────────────────── - [1] script1 ✓ + [1] script1: $ echo hello ✓ → Cache miss: no previous cache entry found ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ @@ -30,7 +30,7 @@ Performance: 100% cache hit rate Task Details: ──────────────────────────────────────────────── - [1] script2 ✓ + [1] script2: $ echo hello ✓ → Cache hit - output replayed ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ @@ -49,6 +49,6 @@ Performance: 0% cache hit rate Task Details: ──────────────────────────────────────────────── - [1] script2 ✓ + [1] script2: $ echo world ✓ → Cache miss: command changed from echo hello to echo world ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ diff --git a/packages/cli/snap-tests/cache-clean/snap.txt b/packages/cli/snap-tests/cache-clean/snap.txt index 043a3c5a01..5c9bb144ce 100644 --- a/packages/cli/snap-tests/cache-clean/snap.txt +++ b/packages/cli/snap-tests/cache-clean/snap.txt @@ -12,7 +12,7 @@ Performance: 0% cache hit rate Task Details: ──────────────────────────────────────────────── - [1] hello ✓ + [1] hello: $ echo hello ✓ → Cache miss: no previous cache entry found ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ @@ -30,7 +30,7 @@ Performance: 100% cache hit rate Task Details: ──────────────────────────────────────────────── - [1] hello ✓ + [1] hello: $ echo hello ✓ → Cache hit - output replayed ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ @@ -49,7 +49,7 @@ Performance: 0% cache hit rate Task Details: ──────────────────────────────────────────────── - [1] hello ✓ + [1] hello: $ echo hello ✓ → Cache miss: no previous cache entry found ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ @@ -68,6 +68,6 @@ Performance: 0% cache hit rate Task Details: ──────────────────────────────────────────────── - [1] hello ✓ + [1] hello: $ echo hello ✓ → Cache miss: no previous cache entry found ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ diff --git a/packages/cli/snap-tests/cache-miss-command-change/snap.txt b/packages/cli/snap-tests/cache-miss-command-change/snap.txt index 25cb375b97..33647c7116 100644 --- a/packages/cli/snap-tests/cache-miss-command-change/snap.txt +++ b/packages/cli/snap-tests/cache-miss-command-change/snap.txt @@ -15,10 +15,10 @@ Performance: 0% cache hit rate Task Details: ──────────────────────────────────────────────── - [1] hello(subcommand 0) ✓ + [1] hello(subcommand 0): $ echo foo ✓ → Cache miss: no previous cache entry found ······················································· - [2] hello ✓ + [2] hello: $ echo bar ✓ → Cache miss: no previous cache entry found ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ @@ -40,10 +40,10 @@ Performance: 50% cache hit rate Task Details: ──────────────────────────────────────────────── - [1] hello(subcommand 0) ✓ + [1] hello(subcommand 0): $ echo baz ✓ → Cache miss: command changed from echo foo to echo baz ······················································· - [2] hello ✓ + [2] hello: $ echo bar ✓ → Cache hit - output replayed ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ @@ -62,6 +62,6 @@ Performance: 100% cache hit rate Task Details: ──────────────────────────────────────────────── - [1] hello ✓ + [1] hello: $ echo bar ✓ → Cache hit - output replayed ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ diff --git a/packages/cli/snap-tests/change-passthrough-env-config/snap.txt b/packages/cli/snap-tests/change-passthrough-env-config/snap.txt index e91724ff10..ff3aa3fba5 100644 --- a/packages/cli/snap-tests/change-passthrough-env-config/snap.txt +++ b/packages/cli/snap-tests/change-passthrough-env-config/snap.txt @@ -12,7 +12,7 @@ Performance: 0% cache hit rate Task Details: ──────────────────────────────────────────────── - [1] hello ✓ + [1] hello: $ node -p process.env.MY_ENV ✓ → Cache miss: no previous cache entry found ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ @@ -30,7 +30,7 @@ Performance: 100% cache hit rate Task Details: ──────────────────────────────────────────────── - [1] hello ✓ + [1] hello: $ node -p process.env.MY_ENV ✓ → Cache hit - output replayed ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ @@ -49,6 +49,6 @@ Performance: 0% cache hit rate Task Details: ──────────────────────────────────────────────── - [1] hello ✓ + [1] hello: $ node -p process.env.MY_ENV ✓ → Cache miss: pass-through env configuration changed from ["MY_ENV"] to ["MY_ENV, MY_ENV2"] ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ diff --git a/packages/cli/snap-tests/check-oxlint-env/snap.txt b/packages/cli/snap-tests/check-oxlint-env/snap.txt index 486f2e6e8a..4cd058154d 100644 --- a/packages/cli/snap-tests/check-oxlint-env/snap.txt +++ b/packages/cli/snap-tests/check-oxlint-env/snap.txt @@ -12,7 +12,7 @@ Performance: 0% cache hit rate Task Details: ──────────────────────────────────────────────── - [1] check-oxlint-env#check ✓ + [1] check-oxlint-env#check: $ node check.js ✓ → Cache miss: no previous cache entry found ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ @@ -32,6 +32,6 @@ Performance: 0% cache hit rate Task Details: ──────────────────────────────────────────────── - [1] check-oxlint-env#check ✓ + [1] check-oxlint-env#check: $ node check.js ✓ → Cache miss: no previous cache entry found ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ diff --git a/packages/cli/snap-tests/exit-code/snap.txt b/packages/cli/snap-tests/exit-code/snap.txt index 2c267f1a3c..8c0fd54ff7 100644 --- a/packages/cli/snap-tests/exit-code/snap.txt +++ b/packages/cli/snap-tests/exit-code/snap.txt @@ -12,7 +12,7 @@ Performance: 0% cache hit rate Task Details: ──────────────────────────────────────────────── - [1] script1 ✓ + [1] script1: $ echo success ✓ → Cache miss: no previous cache entry found ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ @@ -30,7 +30,7 @@ Performance: 100% cache hit rate Task Details: ──────────────────────────────────────────────── - [1] script1 ✓ + [1] script1: $ echo success ✓ → Cache hit - output replayed ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ @@ -48,7 +48,7 @@ Performance: 0% cache hit rate Task Details: ──────────────────────────────────────────────── - [1] script2 ✗ (exit code: 1) + [1] script2: $ node failure.js ✗ (exit code: 1) → Cache miss: no previous cache entry found ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ @@ -66,6 +66,6 @@ Performance: 0% cache hit rate Task Details: ──────────────────────────────────────────────── - [1] script2 ✗ (exit code: 1) + [1] script2: $ node failure.js ✗ (exit code: 1) → Cache miss: no previous cache entry found ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ diff --git a/packages/cli/snap-tests/individual-cache-for-adt-args/snap.txt b/packages/cli/snap-tests/individual-cache-for-adt-args/snap.txt index fd3d322d15..c5869f08e3 100644 --- a/packages/cli/snap-tests/individual-cache-for-adt-args/snap.txt +++ b/packages/cli/snap-tests/individual-cache-for-adt-args/snap.txt @@ -12,7 +12,7 @@ Performance: 0% cache hit rate Task Details: ──────────────────────────────────────────────── - [1] echo ✓ + [1] echo: $ echo a ✓ → Cache miss: no previous cache entry found ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ @@ -30,7 +30,7 @@ Performance: 0% cache hit rate Task Details: ──────────────────────────────────────────────── - [1] echo ✓ + [1] echo: $ echo b ✓ → Cache miss: no previous cache entry found ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ @@ -48,7 +48,7 @@ Performance: 100% cache hit rate Task Details: ──────────────────────────────────────────────── - [1] echo ✓ + [1] echo: $ echo a ✓ → Cache hit - output replayed ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ @@ -66,6 +66,6 @@ Performance: 100% cache hit rate Task Details: ──────────────────────────────────────────────── - [1] echo ✓ + [1] echo: $ echo b ✓ → Cache hit - output replayed ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ diff --git a/packages/cli/snap-tests/individual-cache-for-envs/snap.txt b/packages/cli/snap-tests/individual-cache-for-envs/snap.txt index 6ba578d76f..a1c5d8e925 100644 --- a/packages/cli/snap-tests/individual-cache-for-envs/snap.txt +++ b/packages/cli/snap-tests/individual-cache-for-envs/snap.txt @@ -12,7 +12,7 @@ Performance: 0% cache hit rate Task Details: ──────────────────────────────────────────────── - [1] hello ✓ + [1] hello: $ node -p process.env.FOO ✓ → Cache miss: no previous cache entry found ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ @@ -30,7 +30,7 @@ Performance: 0% cache hit rate Task Details: ──────────────────────────────────────────────── - [1] hello ✓ + [1] hello: $ node -p process.env.FOO ✓ → Cache miss: env FOO value changed from '1' to '2' ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ @@ -48,7 +48,7 @@ Performance: 100% cache hit rate Task Details: ──────────────────────────────────────────────── - [1] hello ✓ + [1] hello: $ node -p process.env.FOO ✓ → Cache hit - output replayed ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ @@ -66,6 +66,6 @@ Performance: 100% cache hit rate Task Details: ──────────────────────────────────────────────── - [1] hello ✓ + [1] hello: $ node -p process.env.FOO ✓ → Cache hit - output replayed ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ diff --git a/packages/cli/snap-tests/pass-no-color-env/snap.txt b/packages/cli/snap-tests/pass-no-color-env/snap.txt index c2b982dc4e..a31c23a43c 100644 --- a/packages/cli/snap-tests/pass-no-color-env/snap.txt +++ b/packages/cli/snap-tests/pass-no-color-env/snap.txt @@ -12,7 +12,7 @@ Performance: 0% cache hit rate Task Details: ──────────────────────────────────────────────── - [1] check ✓ + [1] check: $ node check.js --foo ✓ → Cache miss: no previous cache entry found ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ @@ -30,6 +30,6 @@ Performance: 0% cache hit rate Task Details: ──────────────────────────────────────────────── - [1] check ✓ + [1] check: $ node check.js --bar ✓ → Cache miss: no previous cache entry found ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ diff --git a/packages/cli/snap-tests/plain-terminal-ui-nested/snap.txt b/packages/cli/snap-tests/plain-terminal-ui-nested/snap.txt index 9fd15c7fc5..d6ba9492e8 100644 --- a/packages/cli/snap-tests/plain-terminal-ui-nested/snap.txt +++ b/packages/cli/snap-tests/plain-terminal-ui-nested/snap.txt @@ -19,10 +19,10 @@ Performance: 0% cache hit rate Task Details: ──────────────────────────────────────────────── - [1] lint ✓ + [1] lint: $ vite lint ./src ✓ → Cache miss: no previous cache entry found ······················································· - [2] lint ✓ + [2] lint: $ vite lint ✓ → Cache miss: no previous cache entry found ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ @@ -48,9 +48,9 @@ Performance: 50% cache hit rate Task Details: ──────────────────────────────────────────────── - [1] lint ✓ + [1] lint: $ vite lint ./src ✓ → Cache hit - output replayed ······················································· - [2] lint ✓ + [2] lint: $ vite lint ✓ → Cache miss: content of input 'a.ts' changed ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ diff --git a/packages/cli/snap-tests/plain-terminal-ui/snap.txt b/packages/cli/snap-tests/plain-terminal-ui/snap.txt index ef725ffd11..4601e48b41 100644 --- a/packages/cli/snap-tests/plain-terminal-ui/snap.txt +++ b/packages/cli/snap-tests/plain-terminal-ui/snap.txt @@ -12,7 +12,7 @@ Performance: 0% cache hit rate Task Details: ──────────────────────────────────────────────── - [1] root-package#hello ✓ + [1] root-package#hello: $ node hello.mjs ✓ → Cache miss: no previous cache entry found ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ @@ -30,7 +30,7 @@ Performance: 100% cache hit rate Task Details: ──────────────────────────────────────────────── - [1] root-package#hello ✓ + [1] root-package#hello: $ node hello.mjs ✓ → Cache hit - output replayed ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ @@ -48,7 +48,7 @@ Performance: 0% cache hit rate Task Details: ──────────────────────────────────────────────── - [1] root-package#hello ✓ + [1] root-package#hello: $ node hello.mjs ✓ → Cache miss: env FOO value changed from '1' to '2' ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ @@ -66,7 +66,7 @@ Performance: 0% cache hit rate Task Details: ──────────────────────────────────────────────── - [1] root-package#hello ✓ + [1] root-package#hello: $ node hello.mjs ✓ → Cache miss: env BAR=1 added ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ @@ -84,7 +84,7 @@ Performance: 0% cache hit rate Task Details: ──────────────────────────────────────────────── - [1] root-package#hello ✓ + [1] root-package#hello: $ node hello.mjs ✓ → Cache miss: env BAR=1 removed; env FOO=2 removed ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ @@ -103,7 +103,7 @@ Performance: 0% cache hit rate Task Details: ──────────────────────────────────────────────── - [1] root-package#hello ✓ + [1] root-package#hello: $ node hello.mjs ✓ → Cache miss: content of input 'input.txt' changed ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ @@ -122,13 +122,13 @@ Performance: 0% cache hit rate Task Details: ──────────────────────────────────────────────── - [1] root-package#hello ✓ + [1] root-package#hello: $ node hello.mjs ✓ → Cache miss: pass-through env configuration changed from [""] to ["PTE"] ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ > json-edit vite-task.json "_.tasks.hello.cwd='subfolder'" > vite run hello # cwd changed -$ node hello.mjs (✗ cache miss: working directory changed, executing) +~/subfolder$ node hello.mjs (✗ cache miss: working directory changed, executing) hello from subfolder @@ -141,6 +141,6 @@ Performance: 0% cache hit rate Task Details: ──────────────────────────────────────────────── - [1] root-package#hello ✓ + [1] root-package#hello: ~/subfolder$ node hello.mjs ✓ → Cache miss: working directory changed from '.' to 'subfolder' ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ diff --git a/packages/cli/snap-tests/replay-logs-chronological-order/snap.txt b/packages/cli/snap-tests/replay-logs-chronological-order/snap.txt index e8930c8a22..b260bf9ac8 100644 --- a/packages/cli/snap-tests/replay-logs-chronological-order/snap.txt +++ b/packages/cli/snap-tests/replay-logs-chronological-order/snap.txt @@ -104,7 +104,7 @@ Performance: 0% cache hit rate Task Details: ──────────────────────────────────────────────── - [1] @test/replay-logs-chronological-order#build ✓ + [1] @test/replay-logs-chronological-order#build: $ node build.js ✓ → Cache miss: no previous cache entry found ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ @@ -214,7 +214,7 @@ Performance: 100% cache hit rate Task Details: ──────────────────────────────────────────────── - [1] @test/replay-logs-chronological-order#build ✓ + [1] @test/replay-logs-chronological-order#build: $ node build.js ✓ → Cache hit - output replayed ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ @@ -324,7 +324,7 @@ Performance: 100% cache hit rate Task Details: ──────────────────────────────────────────────── - [1] @test/replay-logs-chronological-order#build ✓ + [1] @test/replay-logs-chronological-order#build: $ node build.js ✓ → Cache hit - output replayed ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ @@ -434,7 +434,7 @@ Performance: 100% cache hit rate Task Details: ──────────────────────────────────────────────── - [1] @test/replay-logs-chronological-order#build ✓ + [1] @test/replay-logs-chronological-order#build: $ node build.js ✓ → Cache hit - output replayed ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ @@ -544,6 +544,6 @@ Performance: 100% cache hit rate Task Details: ──────────────────────────────────────────────── - [1] @test/replay-logs-chronological-order#build ✓ + [1] @test/replay-logs-chronological-order#build: $ node build.js ✓ → Cache hit - output replayed ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ diff --git a/packages/cli/snap-tests/same-name-as-builtin/snap.txt b/packages/cli/snap-tests/same-name-as-builtin/snap.txt index d106308853..64b7cd4858 100644 --- a/packages/cli/snap-tests/same-name-as-builtin/snap.txt +++ b/packages/cli/snap-tests/same-name-as-builtin/snap.txt @@ -17,7 +17,7 @@ Performance: 0% cache hit rate Task Details: ──────────────────────────────────────────────── - [1] lint ✓ + [1] lint: $ echo lint script ✓ → Cache miss: no previous cache entry found ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ @@ -42,6 +42,6 @@ Performance: 100% cache hit rate Task Details: ──────────────────────────────────────────────── - [1] lint ✓ + [1] lint: $ echo lint script ✓ → Cache hit - output replayed ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ diff --git a/packages/cli/snap-tests/shared-caching-inputs/snap.txt b/packages/cli/snap-tests/shared-caching-inputs/snap.txt index f45b7a1de9..4d942170ad 100644 --- a/packages/cli/snap-tests/shared-caching-inputs/snap.txt +++ b/packages/cli/snap-tests/shared-caching-inputs/snap.txt @@ -12,7 +12,7 @@ Performance: 0% cache hit rate Task Details: ──────────────────────────────────────────────── - [1] script1 ✓ + [1] script1: $ cat foo.txt ✓ → Cache miss: no previous cache entry found ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ @@ -30,7 +30,7 @@ Performance: 100% cache hit rate Task Details: ──────────────────────────────────────────────── - [1] script2 ✓ + [1] script2: $ cat foo.txt ✓ → Cache hit - output replayed ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ @@ -49,7 +49,7 @@ Performance: 0% cache hit rate Task Details: ──────────────────────────────────────────────── - [1] script2 ✓ + [1] script2: $ cat foo.txt ✓ → Cache miss: content of input 'foo.txt' changed ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ @@ -67,6 +67,6 @@ Performance: 100% cache hit rate Task Details: ──────────────────────────────────────────────── - [1] script1 ✓ + [1] script1: $ cat foo.txt ✓ → Cache hit - output replayed ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ diff --git a/packages/cli/snap-tests/task-config-cwd/snap.txt b/packages/cli/snap-tests/task-config-cwd/snap.txt index f4017dbf65..57e476822f 100644 --- a/packages/cli/snap-tests/task-config-cwd/snap.txt +++ b/packages/cli/snap-tests/task-config-cwd/snap.txt @@ -1,5 +1,5 @@ > vite run hello -$ node a.js +~/subfolder$ node a.js hello from subfolder @@ -12,6 +12,6 @@ Performance: 0% cache hit rate Task Details: ──────────────────────────────────────────────── - [1] hello ✓ + [1] hello: ~/subfolder$ node a.js ✓ → Cache miss: no previous cache entry found ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ diff --git a/packages/cli/snap-tests/test-nested-tasks/snap.txt b/packages/cli/snap-tests/test-nested-tasks/snap.txt index d913915791..da6f546cf9 100644 --- a/packages/cli/snap-tests/test-nested-tasks/snap.txt +++ b/packages/cli/snap-tests/test-nested-tasks/snap.txt @@ -12,7 +12,7 @@ Performance: 0% cache hit rate Task Details: ──────────────────────────────────────────────── - [1] script1 ✓ + [1] script1: $ echo 'hello vite' ✓ → Cache miss: no previous cache entry found ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ @@ -31,6 +31,6 @@ Performance: 100% cache hit rate Task Details: ──────────────────────────────────────────────── - [1] script1 ✓ + [1] script1: $ echo 'hello vite' ✓ → Cache hit - output replayed ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━