Nayeem Rahman
c36f877f8d
fix(lsp): ignore editor indent settings if deno.json is present ( #26912 )
2024-11-18 21:45:34 +00:00
Bhuwan Pandit
cff6e280c7
feat(cli): support multiple env file argument ( #26527 )
...
Closes #26425
## Overview
This PR adds support for specifying multiple environment files as
arguments when using the Deno CLI. Subsequent files override
pre-existing variables defined in previous files.
If the same variable is defined in the environment and in the file, the
value from the environment takes precedence.
## Example Usage
```bash
deno run --allow-env --env-file --env-file=".env.one" --env-file=".env.two" script.ts
```
---------
Co-authored-by: Bartek Iwańczuk <biwanczuk@gmail.com>
2024-11-17 22:49:35 +00:00
HasanAlrimawi
abf06eb87f
feat(watch): log which file changed on HMR or watch change ( #25801 )
...
Closes #25504
2024-11-16 15:59:31 +01:00
Miguel Rodrigues
99d5c6e423
fix(cli): show prefix hint when installing a package globally ( #26629 )
...
Closes #26545
Shows a hint when a package is installed globally, otherwise fallbacks
to the existing implementation.
2024-11-16 14:57:14 +01:00
Luca Casonato
b8cf259924
feat(fetch): accept async iterables for body ( #26882 )
...
Reland of #24623 , but with a fix for `String` objects.
Co-authored-by: crowlkats <crowlkats@toaxl.com>
2024-11-15 15:54:28 +01:00
Nayeem Rahman
3f26310728
feat(lsp): auto-imports with @deno-types directives ( #26821 )
...
Co-authored-by: David Sherret <dsherret@gmail.com>
2024-11-15 14:40:32 +00:00
Bartek Iwańczuk
dcc75d5685
chore: remove some unused tests ( #26878 )
2024-11-15 00:19:12 +00:00
David Sherret
f091d1ad69
feat(node): stabilize detecting if CJS via "type": "commonjs"
in a package.json ( #26439 )
...
This will respect `"type": "commonjs"` in a package.json to determine if
`.js`/`.jsx`/`.ts`/.tsx` files are CJS or ESM. If the file is found to
be ESM it will be loaded as ESM though.
2024-11-13 15:10:09 +00:00
Kaveh
db53ec230d
refactor(ext/net): Use hickory dns instead of unmaintained trust-dns ( #26741 )
...
This PR replaces the unmaintained and rebranded `trust-dns` to `hickory`
for resolver in `deno_net`.
2024-11-06 15:49:32 -08:00
Nayeem Rahman
5088b25f23
feat(lsp): auto-import completions from byonm dependencies ( #26680 )
2024-11-06 06:26:46 +00:00
Mohammad Sulaiman
89f0b796bd
chore: deprecate run itests ( #26444 )
2024-11-05 06:39:05 +00:00
Nathan Whitaker
44eca0505c
chore: fix serve_watch_all test ( #26725 )
...
It's been failing a ton lately, it looks like the test is just
incorrectly using TS syntax in a JS file
https://github.com/denoland/deno/actions/runs/11672972415/job/32502710624?pr=26724#step:43:2791
I'm not really sure how this ever passes
2024-11-05 01:09:17 +00:00
Nayeem Rahman
d67765b0b4
fix(lsp): scope attribution for lazily loaded assets ( #26699 )
2024-11-04 20:01:31 +00:00
David Sherret
826e42a5b5
fix: improved support for cjs and cts modules ( #26558 )
...
* cts support
* better cjs/cts type checking
* deno compile cjs/cts support
* More efficient detect cjs (going towards stabilization)
* Determination of whether .js, .ts, .jsx, or .tsx is cjs or esm is only
done after loading
* Support `import x = require(...);`
Co-authored-by: Bartek Iwańczuk <biwanczuk@gmail.com>
2024-11-01 12:27:00 -04:00
Nayeem Rahman
2f0c25d33f
fix(lsp): include unstable features from editor settings ( #26655 )
2024-10-31 10:52:43 +00:00
McSneaky
1431ffa9f8
docs(console): Update docstrings for install and uninstall ( #26623 )
...
When running `deno -h` then `install` and `uninstall` scripts had
description since deno 1 times :)
2024-10-30 16:32:04 +01:00
HasanAlrimawi
3b28446000
fix: support watch flag to enable watching other files than the main module on serve subcommand ( #26622 )
...
Closes #26618
2024-10-29 22:55:41 +01:00
snek
4e38fbd0a3
fix: report exceptions from nextTick ( #26579 )
...
Fixes: https://github.com/denoland/deno/issues/24713
Fixes: https://github.com/denoland/deno/issues/25855
2024-10-28 18:16:43 +01:00
Nayeem Rahman
38c7af4565
feat(lsp): "typescript.preferences.preferTypeOnlyAutoImports" setting ( #26546 )
2024-10-25 18:35:09 +01:00
Nayeem Rahman
9e25a4ebbf
fix(lsp): import-map-remap quickfix for type imports ( #26454 )
2024-10-21 22:16:39 +01:00
Nayeem Rahman
9fe2bf42dc
feat(lsp): interactive inlay hints ( #26382 )
2024-10-21 17:15:52 +01:00
Marvin Hagemeister
4b99cde504
fix(npm): ensure scoped package name is encoded in URLs ( #26390 )
...
Fixes https://github.com/denoland/deno/issues/26385
2024-10-18 20:38:57 +02:00
Nayeem Rahman
72dd74d83a
Reland feat(lsp): deno/didRefreshDenoConfigurationTree notifications ( #26325 )
2024-10-16 22:43:26 +01:00
Bartek Iwańczuk
1fd8d092ea
Revert "feat(lsp): "deno/didRefreshDenoConfigurationTree" notificatio… ( #26320 )
...
…ns (#26215 )"
This reverts commit 06778e4e9b
because
benchmarks are failing on `main`.
2024-10-16 19:05:47 +00:00
Nayeem Rahman
06778e4e9b
feat(lsp): "deno/didRefreshDenoConfigurationTree" notifications ( #26215 )
2024-10-16 17:05:13 +01:00
林炳权
533a9b1086
chore: upgrade to rust 1.81.0 ( #26261 )
2024-10-15 21:40:07 +05:30
Mohammad Sulaiman
8dbe77dd29
fix(console/ext/repl): support using parseFloat() ( #25900 )
...
Fixes #21428
Co-authored-by: tannal <tannal2409@gmail.com>
2024-10-14 15:04:18 -07:00
Nayeem Rahman
94b588ce66
fix(lsp): relative completions for bare import-mapped specifiers ( #26137 )
2024-10-11 07:40:17 +01:00
David Sherret
251840a60d
fix: do not panic on wsl share file paths on windows ( #26081 )
...
A test is going to fail on windows (I'm not on a windows machine atm, so
running the CI to see what fails)
Closes #26080
2024-10-09 18:49:56 +01:00
Bartek Iwańczuk
20ae8db50d
fix(repl): importing json files ( #26053 )
...
Closes https://github.com/denoland/deno/issues/26041
2024-10-09 10:04:44 +02:00
Bartek Iwańczuk
0dfd333649
fix(jupyter): keep running event loop when waiting for messages ( #26049 )
...
Closes https://github.com/denoland/deno/issues/24421
2024-10-09 10:04:15 +02:00
Nayeem Rahman
053894b9e0
fix(lsp): exclude missing import quick fixes with bad resolutions ( #26025 )
2024-10-07 18:20:45 +01:00
David Sherret
f288730c38
chore: enable lock_deno_json_package_json_deps ( #26029 )
2024-10-04 20:55:03 +01:00
Satya Rohith
7b509e492e
tests: enable package_json_node_modules_none ( #25825 )
...
Co-authored-by: David Sherret <dsherret@gmail.com>
2024-10-04 09:56:13 +00:00
Simon Lecoq
da7edf1c0c
fix: don't prompt when using Deno.permissions.request
with --no-prompt
( #25811 )
2024-10-03 12:28:38 +00:00
Mohammad Sulaiman
3c193aef98
chore: deprecate check itests ( #25963 )
2024-10-02 09:22:35 +00:00
Nayeem Rahman
3881b71734
feat(lsp): quick fix for @deno-types="npm:@types/*" ( #25954 )
2024-10-01 22:55:02 +01:00
David Sherret
4c8d57db03
BREAKING: rename "deps" remote cache folder to "remote" ( #25969 )
...
Closes https://github.com/denoland/deno/issues/25967
Closes #25968
2024-10-01 14:05:40 -04:00
Bartek Iwańczuk
c487a86b04
fix: Hide 'deno cache' from help output ( #25960 )
...
`deno cache` was soft-deprecated in favor of `deno install`. It should
not show up in the help output.
2024-10-01 15:05:21 +02:00
Luca Casonato
3134abefa4
BREAKING(ext/net): improved error code accuracy ( #25383 )
...
Co-authored-by: Bartek Iwańczuk <biwanczuk@gmail.com>
2024-09-27 14:07:20 +00:00
Bartek Iwańczuk
5504acea67
feat: add --allow-import
flag ( #25469 )
...
This replaces `--allow-net` for import permissions and makes the
security sandbox stricter by also checking permissions for statically
analyzable imports.
By default, this has a value of
`--allow-import=deno.land:443,jsr.io:443,esm.sh:443,raw.githubusercontent.com:443,gist.githubusercontent.com:443`,
but that can be overridden by providing a different set of hosts.
Additionally, when no value is provided, import permissions are inferred
from the CLI arguments so the following works because
`fresh.deno.dev:443` will be added to the list of allowed imports:
```ts
deno run -A -r https://fresh.deno.dev
```
---------
Co-authored-by: David Sherret <dsherret@gmail.com>
2024-09-26 01:50:54 +00:00
Mohammad Sulaiman
c232ecc6af
chore: deprecate npm itests ( #25804 )
2024-09-25 18:46:18 +00:00
Bartek Iwańczuk
74e294c8c1
refactor: reenable more tests after DENO_FUTURE migration ( #25752 )
...
Rewrites and reenables following tests:
- `task::task_both_package_json_selected`
2024-09-24 03:33:03 +02:00
David Sherret
e1c8d2755e
BREAKING: remove support for remote import maps in deno.json ( #25836 )
...
This is for security reasons for the time being for Deno 2. Details to
follow post Deno 2.0 release.
Remote import maps seem incredibly rare (only 2 usages on GitHub from
what I can tell), so we'll add this back with more permissions if
there's enough demand for it:
https://github.com/search?type=code&q=%2F%22importMap%22%3A+%22http%2F
In the meantime, use the `--import-map` flag and `"deno.importMap"`
config in the LSP for remote import maps.
2024-09-23 18:46:50 +00:00
Bartek Iwańczuk
a7ac89935b
feat(fmt): stabilize CSS, HTML and YAML formatters ( #25753 )
...
This commits stabilizes CSS, HTML and YAML formatters
in `deno fmt`.
It is no longer required to use either of these flags:
- `--unstable-css`
- `--unstable-html`
- `--unstable-yaml`
Or these `unstable` options in the config file:
- `fmt-css`
- `fmt-html`
- `html-yaml`
2024-09-23 18:01:04 +02:00
Satya Rohith
94bdebe399
refactor(tests): migrate npm itests to specs ( #25764 )
...
Towards https://github.com/denoland/deno/issues/25241
2024-09-20 22:38:32 +02:00
Asher Gomez
5057f58145
feat: suggest deno install --entrypoint
instead of deno cache
( #25228 )
...
Hides `deno cache` from `--help` output.
---------
Signed-off-by: Asher Gomez <ashersaupingomez@gmail.com>
Co-authored-by: Bartek Iwańczuk <biwanczuk@gmail.com>
2024-09-18 19:55:50 +00:00
Leo Kettmeir
a1d0a427e8
feat: default to TS for file extension and support ext flag in more scenarios ( #25472 )
...
Closes #11220
Currently does lint, fmt, and repl
2024-09-18 21:15:13 +02:00
Leo Kettmeir
ec86089c4e
feat: require jsr prefix for deno install
and deno add
( #25698 )
2024-09-18 20:38:22 +02:00
Yazan AbdAl-Rahman
bed46474b2
fix: do not panic running invalid file specifier ( #25530 )
...
Co-authored-by: Bedis Nbiba <bedisnbiba@gmail.com>
2024-09-18 14:51:39 +01:00