summaryrefslogtreecommitdiff
path: root/cli
diff options
context:
space:
mode:
authorNayeem Rahman <nayeemrmn99@gmail.com>2020-09-12 10:33:51 +0100
committerGitHub <noreply@github.com>2020-09-12 11:33:51 +0200
commit5276cc85923a1791bf73a91b05c27fbdeeaa6f9b (patch)
tree911a388ca69cef185549ad4bfcd87f9e4931819b /cli
parent60dbc6b29417d666bf01762be84f12b9d2217f90 (diff)
refactor: Improve placeholder module names (#7430)
Diffstat (limited to 'cli')
-rw-r--r--cli/main.rs8
-rw-r--r--cli/tsc.rs4
2 files changed, 5 insertions, 7 deletions
diff --git a/cli/main.rs b/cli/main.rs
index 0d55ea1df..4584f0c30 100644
--- a/cli/main.rs
+++ b/cli/main.rs
@@ -223,7 +223,7 @@ async fn lint_command(
async fn cache_command(flags: Flags, files: Vec<String>) -> Result<(), ErrBox> {
let main_module =
- ModuleSpecifier::resolve_url_or_path("./__$deno$fetch.ts").unwrap();
+ ModuleSpecifier::resolve_url_or_path("./$deno$cache.ts").unwrap();
let global_state = GlobalState::new(flags)?;
let mut worker = MainWorker::create(&global_state, main_module.clone())?;
@@ -245,7 +245,7 @@ async fn eval_command(
) -> Result<(), ErrBox> {
// Force TypeScript compile.
let main_module =
- ModuleSpecifier::resolve_url_or_path("./__$deno$eval.ts").unwrap();
+ ModuleSpecifier::resolve_url_or_path("./$deno$eval.ts").unwrap();
let global_state = GlobalState::new(flags)?;
let mut worker = MainWorker::create(&global_state, main_module.clone())?;
let main_module_url = main_module.as_url().to_owned();
@@ -430,7 +430,7 @@ async fn doc_command(
async fn run_repl(flags: Flags) -> Result<(), ErrBox> {
let main_module =
- ModuleSpecifier::resolve_url_or_path("./__$deno$repl.ts").unwrap();
+ ModuleSpecifier::resolve_url_or_path("./$deno$repl.ts").unwrap();
let global_state = GlobalState::new(flags)?;
let mut worker = MainWorker::create(&global_state, main_module)?;
loop {
@@ -441,7 +441,7 @@ async fn run_repl(flags: Flags) -> Result<(), ErrBox> {
async fn run_from_stdin(flags: Flags) -> Result<(), ErrBox> {
let global_state = GlobalState::new(flags.clone())?;
let main_module =
- ModuleSpecifier::resolve_url_or_path("./__$deno$stdin.ts").unwrap();
+ ModuleSpecifier::resolve_url_or_path("./$deno$stdin.ts").unwrap();
let mut worker =
MainWorker::create(&global_state.clone(), main_module.clone())?;
diff --git a/cli/tsc.rs b/cli/tsc.rs
index d78485fd3..fa1c79589 100644
--- a/cli/tsc.rs
+++ b/cli/tsc.rs
@@ -216,10 +216,8 @@ fn create_compiler_worker(
global_state: &Arc<GlobalState>,
permissions: Permissions,
) -> CompilerWorker {
- // TODO(bartlomieju): these $deno$ specifiers should be unified for all subcommands
- // like 'eval', 'repl'
let entry_point =
- ModuleSpecifier::resolve_url_or_path("./__$deno$ts_compiler.ts").unwrap();
+ ModuleSpecifier::resolve_url_or_path("./$deno$compiler.ts").unwrap();
let worker_state =
State::new(&global_state, Some(permissions), entry_point, None, true)
.expect("Unable to create worker state");