1
0
Fork 0
mirror of https://github.com/denoland/deno.git synced 2024-11-21 15:04:11 -05:00
denoland-deno/cli
Leo Kettmeir 1ffbd56164
feat: add "deno init" subcommand (#15469)
This adds an init subcommand to that creates a project starter similar to cargo init.

```
$ deno init my_project
Project initialized
Run these commands to get started:
  cd my_project
  deno run main.ts
  deno run main_test.ts
$ deno run main.ts
Add 2 + 3 5
$ cat main.ts
export function add(a: number, b: number): number {
  return a + b;
}
if (import.meta.main) {
  console.log("Add 2 + 3", add(2, 3));
}
$ cat main_test.ts
import { assertEquals } from "https://deno.land/std@0.151.0/testing/asserts.ts";
import { add } from "./main.ts";
Deno.test(function addTest() {
    assertEquals(add(2, 3), 5);
});
```

Co-authored-by: Bartek Iwańczuk <biwanczuk@gmail.com>
2022-08-20 01:37:05 +02:00
..
args feat: add "deno init" subcommand (#15469) 2022-08-20 01:37:05 +02:00
bench feat(unstable): change Deno.serve() API (#15498) 2022-08-19 14:36:01 +02:00
cache refactor(emit/cache): move cli version into emit hash (#15348) 2022-07-30 12:09:12 -04:00
compat feat: add ext/node for require support (#15362) 2022-08-09 21:06:01 +02:00
dts feat(unstable): change Deno.serve() API (#15498) 2022-08-19 14:36:01 +02:00
lsp refactor(cli): consolidate most MainWorker related code to the same place (#15459) 2022-08-11 16:59:12 -04:00
npm fix(npm): handle storing non-all lowercase package names (#15470) 2022-08-14 09:09:16 -04:00
ops refactor: allocate IDs for tests (#14729) 2022-07-15 13:09:22 -04:00
schemas chore(cli): update config file schema to include test config (#15246) 2022-07-19 15:10:41 -04:00
tests feat: add "deno init" subcommand (#15469) 2022-08-20 01:37:05 +02:00
tools feat: add "deno init" subcommand (#15469) 2022-08-20 01:37:05 +02:00
tsc perf(ops): Monomorphic sync op calls (#15337) 2022-08-11 15:56:56 +02:00
auth_tokens.rs chore: update copyright to 2022 (#13306) 2022-01-07 22:09:52 -05:00
build.rs Revert "refactor(snapshots): to their own crate (#14794)" (#15076) 2022-07-05 00:12:41 +02:00
Cargo.toml chore: forward v1.24.3 release commit to main (#15462) 2022-08-11 16:47:03 -04:00
cdp.rs docs: turn bare URLs into clickable links (#15347) 2022-07-30 12:20:29 +02:00
checksum.rs chore: update copyright to 2022 (#13306) 2022-01-07 22:09:52 -05:00
deno.ico fix(cli): add icon and metadata to deno.exe on Windows (#6693) 2020-07-15 21:54:38 +02:00
deno_dir.rs feat: emit files on demand and fix racy emit (#15220) 2022-07-19 11:58:18 -04:00
diagnostics.rs feat(unstable): change Deno.serve() API (#15498) 2022-08-19 14:36:01 +02:00
diff.rs refactor: update comment in diff.rs (#15142) 2022-07-10 22:49:18 -04:00
display.rs refactor: add cli/display.rs module (#13879) 2022-03-09 00:19:02 +01:00
emit.rs refactor: reuse FastInsecureHasher in get_check_hash (#15354) 2022-07-30 11:43:03 -04:00
errors.rs chore: remove all pub(crate)s from the cli crate (#14083) 2022-03-23 09:54:22 -04:00
file_fetcher.rs refactor: upgrade to deno_ast 0.15 (#14680) 2022-05-20 16:40:55 -04:00
file_watcher.rs fix(permissions): ignore empty values (#15447) 2022-08-10 21:13:53 +02:00
fmt_errors.rs refactor: remove redundant qualification of symbols in Rust (#15201) 2022-07-15 07:52:44 +10:00
fs_util.rs feat: add initial internal npm client and dependency resolver (#15446) 2022-08-10 15:23:58 -04:00
graph_util.rs fix(cli): allow configurations files to also be json modules (#15444) 2022-08-11 07:33:42 +10:00
http_cache.rs chore(tests): use custom temp dir creation for the tests (#14153) 2022-04-01 11:15:37 -04:00
http_util.rs docs: turn bare URLs into clickable links (#15347) 2022-07-30 12:20:29 +02:00
lockfile.rs chore(tests): use custom temp dir creation for the tests (#14153) 2022-04-01 11:15:37 -04:00
logger.rs chore: remove all pub(crate)s from the cli crate (#14083) 2022-03-23 09:54:22 -04:00
main.rs feat: add "deno init" subcommand (#15469) 2022-08-20 01:37:05 +02:00
module_loader.rs feat: emit files on demand and fix racy emit (#15220) 2022-07-19 11:58:18 -04:00
proc_state.rs fix(coverage): ensure coverage is only collected in certain situations (#15467) 2022-08-12 15:21:17 -04:00
README.md Remove deno_typescript (#6813) 2020-07-20 19:49:57 -04:00
resolver.rs feat(vendor): support using an existing import map (#14836) 2022-06-14 10:05:37 -04:00
standalone.rs feat(runtime): add pre_execute_module_cb (#15485) 2022-08-16 21:00:35 -04:00
text_encoding.rs feat: emit files on demand and fix racy emit (#15220) 2022-07-19 11:58:18 -04:00
tsc.rs fix(cli): allow configurations files to also be json modules (#15444) 2022-08-11 07:33:42 +10:00
unix_util.rs build: require safety comments on unsafe code (#13870) 2022-06-26 00:13:24 +02:00
version.rs chore: update copyright to 2022 (#13306) 2022-01-07 22:09:52 -05:00
windows_util.rs chore: fix Windows specific clippy errors (#15212) 2022-07-15 12:30:25 -04:00
worker.rs feat(runtime): add pre_execute_module_cb (#15485) 2022-08-16 21:00:35 -04:00

Deno CLI Crate

crates docs

This provides the actual deno executable and the user-facing APIs.

The deno crate uses the deno_core to provide the executable.