From eb25e50edb8efe6fe8fa973199dccfccf22575c7 Mon Sep 17 00:00:00 2001 From: Cre3per <12541974+Cre3per@users.noreply.github.com> Date: Thu, 23 Mar 2023 17:45:43 +0100 Subject: fix(cli): restore `deno run -` to handle stdin as typescript (#18391) Bug reported here shortly after merging `--ext` changes https://github.com/denoland/deno/pull/17172#issuecomment-1480898098 Also found a missing `--check` in integration tests for `--ext` that would have missed a bug if there was one. Fixes #18392 --- cli/args/mod.rs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'cli/args') diff --git a/cli/args/mod.rs b/cli/args/mod.rs index fb44c0a8f..338637455 100644 --- a/cli/args/mod.rs +++ b/cli/args/mod.rs @@ -696,7 +696,8 @@ impl CliOptions { std::env::current_dir() .context("Unable to get CWD") .and_then(|cwd| { - resolve_url_or_path("./$deno$stdin", &cwd).map_err(AnyError::from) + resolve_url_or_path("./$deno$stdin.ts", &cwd) + .map_err(AnyError::from) }) } else if self.flags.watch.is_some() { resolve_url_or_path(&run_flags.script, self.initial_cwd()) -- cgit v1.2.3