Age | Commit message (Collapse) | Author |
|
|
|
|
|
1. Adds a new "license" field.
1. Adds this field by default when doing `deno init --lib`
|
|
This commit adds "--serve" flag to "deno init" subcommand,
that provides a template for quick starting a project using
"deno serve".
---------
Co-authored-by: Asher Gomez <ashersaupingomez@gmail.com>
|
|
This moves all package-specific object keys right next to each other.
|
|
Closes #24580
|
|
This commit fixes the broken link in the sample template provided by the
deno init command.
|
|
Closes #22287
Co-authored-by: Asher Gomez <ashersaupingomez@gmail.com>
Co-authored-by: David Sherret <dsherret@gmail.com>
|
|
This commit changes "deno init" subcommand to use "jsr:" specifier for
standard library "assert" module. It is unversioned, but we will change
it to `@^1` once `@std/assert` release version 1.0.
This allows us to start decoupling `deno` and `deno_std` release. The
release scripts have been updated to take that into account.
|
|
|
|
|
|
### What
Skip writing files from the template if the files already exist in the
project directory.
### Why
When I run deno init in a directory that already has a main.ts, or one
of the other template files, I usually want to initialize a workspace
around a file I've started working in. A hard error in this case seems
counter productive. An informational message about what's being skipped
seems sufficient.
Close #20433
|
|
- Don't include benchmark file - most people won't need this.
- Use deno.json instead of deno.jsonc, because it's a more common file
format.
|
|
|
|
There's no point in having `Lazy<Url>`, since the only use case
is string substitution in the "deno init" subcommand.
|
|
Co-authored-by: Bartek Iwańczuk <biwanczuk@gmail.com>
|
|
Yearly tradition of creating extra noise in git.
|
|
The output of `init` are commands, so this should be treated as a "Shell
script". In Shell script, comments must start with `#`, not `//`. (This
also makes the commands example easier to be copied to somewhere.)
|
|
This commit changes "deno init" to generate "main_bench.ts" file
which scaffold two example bench cases.
|
|
Generate "deno.jsonc" instead of "deno.json" when running "deno init"
subcommand.
|
|
Updates `deno init` subcommand to create a `deno.json` when initializing
a new project.
Slightly changes the output, to make it more readable.
|
|
|
|
|
|
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>
|