Commit Graph

40 Commits

Author SHA1 Message Date
vsrs
08b3b2a56d Fix lint 2023-07-18 18:06:20 +07:00
vsrs
3468b093bd Platform specific runnables env 2023-07-18 17:51:57 +07:00
Tetsuharu Ohzeki
f7823f3106 editor/code: Re-apply code format 2023-07-13 22:44:29 +09:00
Tetsuharu Ohzeki
445b4fc27f editor/code: Sort the style to import types
see:
- https://github.com/typescript-eslint/typescript-eslint/blob/main/packages/eslint-plugin/docs/rules/consistent-type-imports.md
- https://github.com/typescript-eslint/typescript-eslint/blob/main/packages/eslint-plugin/docs/rules/no-import-type-side-effects.md
2023-07-11 06:12:00 +09:00
Tetsuharu Ohzeki
72a3883a71 editor/code: Enable noUncheckedIndexedAccess ts option
https://www.typescriptlang.org/tsconfig#noUncheckedIndexedAccess
2023-07-06 16:17:02 +09:00
Alex Kladov
832a64e290 feat: don't add panics to error jump list by default
To re-enable this, use

    "rust-analyzer.runnables.problemMatcher": [
        "$rustc",
        "$rust-panic"
    ],

setting.

closes: #14977
2023-06-30 22:23:13 +01:00
Mohsen Alizadeh
6c3e15aaa0 13583 rename runnable env to runnables extra env 2023-06-25 17:26:04 -07:00
Josh Soref
bc7d84c3ce Spelling
* a rule
* access
* after
* amount
* annotations
* assignment
* assist
* associated
* attribute
* borrowed
* built-in type
* clarification
* command
* const
* constructor
* corresponding
* counterparts
* curlies
* dependencies
* deterministic
* diagnostic
* duplicates
* edge
* edited
* efficient
* elsewhere
* execution
* expression
* extensions
* extracted
* fill
* github
* helper
* heuristic
* incomplete
* indent end
* inlay
* invocation
* lifetime
* looking
* maybe
* move
* mutability
* mutable
* necessarily
* necessary
* negative
* nonexistent
* occurred
* offsets
* offsetted
* overridden
* parameters
* params
* params_and_where_preds_in_scope
* paredit
* parent
* parentheses
* prepended if
* punctuation
* receive
* receiver
* referring
* repeated
* representing
* semantically
* separately
* shouldnot
* siblings
* similar
* something's
* statement
* struct
* structure
* surprise
* the
* this
* transparent
* unimplemented
* unnamed
* unnecessary
* unneeded
* unreachable
* unterminated
* utilities
* variant
* variants
* visibility
* work around (v)
* workaround

Signed-off-by: Josh Soref <2119212+jsoref@users.noreply.github.com>
2023-04-19 09:45:55 -04:00
Lukas Wirth
2071d00fd2 Always set up VSCode commands 2022-10-29 00:44:37 +02:00
Lukas Wirth
d68616a140 Make more things private 2022-10-17 15:05:20 +02:00
Jonas Schievink
55fdcbe339
Revert "fix: in VSCode, correctly resolve relative paths to errors" 2022-10-14 09:28:44 +02:00
Aleksey Kladov
5bbfea03cc fix: in VSCode, correctly resolve relative paths to errors
VS Code problem matcher are restricted to be static "regexes". You can't
create a problem matcher dynamically, and you can't use custom code in
lieu of problem matcher.

This creates a problem for rust/cargo compiler errors. They use paths
relative to the root of the Cargo workspace, but VS Code doesn't
necessary know where that root is.

Luckily, there's a way out: our current problem matcher is defined like
this:

    "fileLocation": [ "autoDetect", "${workspaceRoot}" ],

That means that relative pahts would be resoleved relative to workspace
root. VS Code allows to specify a command inside `${}`. So we can plug
custom logic there to fetch Cargo's workspace root!

And that's exactly what this PR is doing!
2022-10-08 23:25:13 +01:00
Hofer-Julian
2916cd2a86
Fix typo 2022-05-26 19:12:49 +02:00
Andrei Listochkin
f247090558 prettier run 2022-05-17 18:15:06 +01:00
Aleksey Kladov
249e22b325 minor: explicitly set the focus to false 2021-05-26 13:04:01 +03:00
bors[bot]
82a1b91f20
Merge #7625
7625: Add **Copy Run Command Line** command for vscode r=matklad a=matklad

bors r+
🤖

Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
2021-02-10 11:38:56 +00:00
Aleksey Kladov
97166e2ad9 Add **Copy Run Command Line** command for vscode
This is useful when you want to, e.g., run a specific test in a terminal
with `--release`.
2021-02-10 14:37:27 +03:00
Sahandevs
91dd61b9a6 use await instead 2021-02-09 17:42:46 +03:30
Sahandevs
2f82a84d2a fix errors 2021-02-07 22:06:16 +03:30
Sahandevs
3a0234d60f format 2021-02-07 21:59:06 +03:30
Sahandevs
1bb4e973ff handle Thenable type rejects 2021-02-07 21:52:32 +03:30
Sahandevs
1d0e93b58e handle promise catches 2021-02-07 21:27:21 +03:30
Sahandevs
06c02021a3 remove unnecessary 2021-02-07 21:15:13 +03:30
feileacan
d019cdbbb2
Check cargoExtraArgs for undefined before using 2020-10-18 11:40:48 +11:00
Igor Aleksanov
5b26629a4d Support 'runnables' options in the vs code extension 2020-10-02 12:35:22 +03:00
vsrs
bebbfa1a29 Fix workspaceRoot 2020-07-03 14:56:30 +03:00
vsrs
611fad275f code linting 2020-07-03 14:23:51 +03:00
vsrs
271abb7bc4 Add tests 2020-07-03 14:23:51 +03:00
vsrs
7b79d24ad5 Add runnable env support. 2020-07-03 14:23:51 +03:00
Aleksey Kladov
03c5a6690d Add light-weight snapshot testing library with editor integration 2020-06-27 19:22:31 +02:00
vsrs
647b126da5 Switch to ShellExecution instead of full Task 2020-06-24 10:53:49 +03:00
vsrs
a43a9103bc Add custom cargo runners 2020-06-24 10:53:49 +03:00
vsrs
b91fa7494e Fix Run lens. 2020-06-06 15:12:17 +03:00
Aleksey Kladov
0303982119 New runnables API 2020-06-02 17:22:42 +02:00
Aleksey Kladov
0ced18eee0 Move run commands to commands.ts 2020-06-02 14:52:55 +02:00
bors[bot]
131ccd9540
Merge #4580
4580: Fix invoking cargo without consulting CARGO env var or standard installation paths r=matklad a=Veetaha

Followup for #4329

The pr essentially fixes [this bug](https://youtu.be/EzQ7YIIo1rY?t=2189)

cc @lefticus

Co-authored-by: veetaha <veetaha2@gmail.com>
2020-06-02 11:58:28 +00:00
Alin Sinpalean
771457ec5c Always derive from process.env when spawning a child process/shell execution
This is useful when an extension (e.g. Nix Environment Selector) or launch
configuration sets one or more environment variables.

When `env` is not explicitly specified in the options passed to
`child_process.spawn()` or `vscode.ShellExecution()`, then `process.env` gets
applied automatically. But when an explicit `env` is set, it should inherit from
`process.env` rather than replace it completely.
2020-05-31 13:41:55 +02:00
veetaha
d605ec9c32 Change Runnable.bin -> Runnable.kind
As per matklad, we now pass the responsibility for finding the binary to the frontend.
Also, added caching for finding the binary path to reduce
the amount of filesystem interactions.
2020-05-31 05:21:45 +03:00
Aleksey Kladov
a30bdd9795 Cleanup lsp extensions on the client side 2020-05-25 14:56:26 +02:00
Aleksey Kladov
6058b8b0f6 Flatten commands.ts 2020-05-25 12:14:44 +02:00