diff options
Diffstat (limited to 'cli/main.rs')
-rw-r--r-- | cli/main.rs | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/cli/main.rs b/cli/main.rs index b91540c37..f18c3c976 100644 --- a/cli/main.rs +++ b/cli/main.rs @@ -686,6 +686,17 @@ async fn run_command( return run_from_stdin(flags).await; } + if !flags.has_permission() && flags.has_permission_in_argv() { + log::warn!( + "{}", + crate::colors::yellow( + r#"Permission flags have likely been incorrectly set after the script argument. +To grant permissions, set them before the script argument. For example: + deno run --allow-read=. main.js"# + ) + ); + } + if flags.watch.is_some() { return run_with_watch(flags, run_flags.script).await; } |