summaryrefslogtreecommitdiff
path: root/cli/main.rs
diff options
context:
space:
mode:
Diffstat (limited to 'cli/main.rs')
-rw-r--r--cli/main.rs6
1 files changed, 5 insertions, 1 deletions
diff --git a/cli/main.rs b/cli/main.rs
index 5e088d891..02ac5891c 100644
--- a/cli/main.rs
+++ b/cli/main.rs
@@ -42,6 +42,7 @@ use deno_runtime::colors;
use deno_runtime::fmt_errors::format_js_error;
use deno_runtime::tokio_util::run_local;
use std::env;
+use std::env::current_exe;
use std::path::PathBuf;
async fn run_subcommand(flags: Flags) -> Result<i32, AnyError> {
@@ -245,8 +246,11 @@ pub fn main() {
let args: Vec<String> = env::args().collect();
let future = async move {
+ let current_exe_path = current_exe()?;
let standalone_res =
- match standalone::extract_standalone(args.clone()).await {
+ match standalone::extract_standalone(&current_exe_path, args.clone())
+ .await
+ {
Ok(Some((metadata, eszip))) => standalone::run(eszip, metadata).await,
Ok(None) => Ok(()),
Err(err) => Err(err),