Commit Graph

109 Commits

Author SHA1 Message Date
Emil Lauridsen 0cdbd08149 Keep VSCode config mostly backwards compatible 2019-12-25 20:26:06 +01:00
Emil Lauridsen 6af4bf7a8d Configuration plumbing for cargo watcher 2019-12-25 17:37:40 +01:00
Emil Lauridsen 41a1ec723c Remove cargo-watch from vscode extension.
Still keeps tests around for reference when porting them to rust
2019-12-25 17:37:40 +01:00
kjeremy be78e3c224 Update to latest packages 2019-12-20 13:52:11 -05:00
bors[bot] ee93fac776 Merge #2583
2583: Use prettier settings in ts-lint r=matklad a=edwin0cheng

This PR add `tslint-plugin-prettier` extension in ts-lint, which "runs prettier rules as tslint rules." and remove  `quotemark` from ts-lint and let prettier to handle it. 

And also fix #2515

Co-authored-by: Edwin Cheng <edwin0cheng@gmail.com>
2019-12-17 21:12:18 +00:00
Edwin Cheng da29b7fb14 use pretter settings in ts-lint 2019-12-17 23:50:18 +08:00
bors[bot] a26840d603 Merge #2568
2568: Add option to disable all-targets. r=matklad a=pftbest

Can be useful in embedded.

Co-authored-by: Vadzim Dambrouski <vadzim.dambrouski@promwad.com>
2019-12-17 13:28:37 +00:00
bors[bot] ba6312a2df Merge #2571
2571: Fixed a typo in settings r=matklad a=omerbenamram

@lnicola found a typo in the description for one of the settings introduced in #2559.

Co-authored-by: Omer Ben-Amram <omerbenamram@gmail.com>
2019-12-17 13:19:59 +00:00
Aleksey Kladov 2432f278cb Default to client watching on VS Code 2019-12-17 12:41:44 +01:00
Omer Ben-Amram 624abc1db3 Fixed a typo
thanks @lnicola
2019-12-16 17:32:46 +02:00
Vadzim Dambrouski a85cd6455a Add option to disable all-targets.
Can be useful in embedded.
2019-12-15 23:32:13 +05:30
Oliver Scherer 5166f6e5f2 Properly format json 2019-12-15 17:19:41 +01:00
Oliver Scherer eed57dcded Add a rudimentary json regex to get at information like endLine 2019-12-15 17:12:52 +01:00
Omer Ben-Amram 5e4e713fc9 Merge branch 'refs/heads/master' into feature/granular-scopes 2019-12-14 17:29:30 +02:00
Omer Ben-Amram 083010f633 removed type.alias 2019-12-14 13:29:42 +02:00
Omer Ben-Amram 67641d3f5f added decorations 2019-12-14 13:24:07 +02:00
oxalica f56a2a0790 Enable allFeatures by default and fix lints 2019-12-14 00:48:47 +08:00
oxalica af4eb26645 Support setting cargo features 2019-12-13 18:16:34 +08:00
Laurențiu Nicola 273299693b Code: enable prettier trailing commas 2019-12-09 21:07:19 +02:00
Edwin Cheng 81ce9833a5 Add rollup sourcemap and fix launch.json 2019-12-09 03:58:43 +08:00
Laurențiu Nicola c7dc067104 Code: bump deps 2019-12-08 20:39:22 +02:00
Laurențiu Nicola 78e8934976 Code: check whether the LSP binary is in PATH 2019-12-08 15:04:37 +02:00
Edwin Cheng d16cc223e1 Use DocumentProvider instead of Hover 2019-11-20 01:06:10 +08:00
Aleksey Kladov dc65219ae1 document feature flags 2019-10-25 09:00:30 +03:00
bors[bot] d2e1f9f6da Merge #1980
1980: Shorten inline type hints r=matklad a=detrumi

Implements #1946 

Co-authored-by: Wilco Kusee <wilcokusee@gmail.com>
2019-10-23 11:13:04 +00:00
Wilco Kusee 3b61acb4ae Make inlay hint length configurable 2019-10-18 13:45:04 +02:00
Roberto Vidal f4d50de275 Adds config option for cargo-watch --ignore flag 2019-10-17 20:21:07 +02:00
Laurențiu Nicola 3a86a6dfb5 Add rust-analyzer.showWorkspaceLoadedNotification to package.json 2019-10-17 17:27:59 +03:00
bors[bot] 62acb9f233 Merge #1984
1984: Bump rollup and vsce r=matklad a=kjeremy

I got sick of the vsce warning on install and noticed that rollup was also out of date.

Co-authored-by: kjeremy <kjeremy@gmail.com>
2019-10-10 14:23:21 +00:00
kjeremy de32ae75f8 Bump rollup and vsce 2019-10-10 10:19:05 -04:00
kjeremy 86939ce0e3 engine.vscode and @types/vscode should match 2019-10-10 10:10:50 -04:00
JasperDeSutter 2151d4da6a add rollup bundler for vscode extension 2019-09-23 23:25:16 +02:00
Lucas Spits 934d7990fd Update minimal required vscode version to 1.37 2019-09-10 08:49:23 +02:00
Aleksey Kladov 28df377759 add option to disable notify 2019-09-06 17:21:29 +03:00
Bastian Köcher b58f84626f Switch to @types/vscode and vscode-test
The old `vscode` package is outdated and it is recommened to switch to
these two new packages. This also solves a problem of a missing `.d.ts`
for `vscode` in Nixos.
2019-08-26 08:22:48 +02:00
Aleksey Kladov 69bbe79c50 implement feature flags 2019-08-22 15:07:31 +03:00
Aleksey Kladov 6ab85cc192 fix default for the exlude key 2019-08-21 17:30:58 +03:00
Aleksey Kladov deea8f52d9 allow to exclude certain files and directories 2019-08-06 14:28:31 +02:00
bors[bot] 78317383c9 Merge #1614
1614: show prettier diff on CI r=matklad a=matklad



Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
2019-07-29 08:55:09 +00:00
Aleksey Kladov 605b2983ef show prettier diff on CI 2019-07-29 11:54:37 +03:00
Aleksey Kladov c1dcdd4735 ⬆️ npm 2019-07-29 11:22:56 +03:00
Kirill Bulatov 169e69d217 Show type decorators 2019-07-25 15:17:28 +03:00
Aleksey Kladov 51568c1467 try to show exact prettier problem 2019-07-25 13:05:34 +03:00
Aleksey Kladov 38f3b47a00 ⬆️ npm deps 2019-07-25 12:17:27 +03:00
Aleksey Kladov d690249bc8 Remove obsolete keybinding 2019-07-21 19:08:05 +03:00
Aleksey Kladov e418889996 underline mutable bindings 2019-07-19 15:07:18 +03:00
Ekaterina Babshukova 4abe03879b highlight mutable variables differently 2019-07-18 18:52:50 +03:00
kjeremy 45d6f47c28 Update vsce to latest 2019-07-03 09:55:48 -04:00
Ryan Cumming 60ba253753 Run VS Code tests on CI
This is actually much faster than I expected; it takes about 13 seconds
to download VS Code and run the unit tests. This means the VS Code tests
are still significantly faster than the Rust ones.

If this ends up being unreliable we can always remove it later or move
it to a separate optional job.

We also need to ignore the `.vscode-test` directory when running
`prettier` or it will get upset about some temporary JSON files VS Code
creates.
2019-06-30 07:12:42 +10:00
Ryan Cumming f82ceca0bd Initial Visual Studio Code unit tests
As promised in #1439 this is an initial attempt at unit testing the
VSCode extension. There are two separate parts to this: getting the test
framework working and unit testing the code in #1439.

The test framework nearly intact from the VSCode extension generator.
The main thing missing was `test/index.ts` which acts as an entry point
for Mocha. This was simply copied back in. I also needed to open the
test VSCode instance inside a workspace as our file URI generation
depends on a workspace being open.

There are two ways to run the test framework:

1. Opening the extension's source in VSCode, pressing F5 and selecting
   the "Extensions Test" debug target.

2. Closing all copies of VSCode and running `npm test`. This is started
   from the command line but actually opens a temporary VSCode window to
   host the tests.

This doesn't attempt to wire this up to CI. That requires running a
headless X11 server which is a bit daunting. I'll assess the difficulty
of that in a follow-up branch. This PR is at least helpful for local
development without having to induce errors on a Rust project.

For the actual tests this uses snapshots of `rustc` output from a real
Rust project captured from the command line. Except for extracting the
`message` object and reformatting they're copied verbatim into fixture
JSON files.

Only four different types of diagnostics are tested but they represent
the main combinations of code actions and related information possible.
They can be considered the happy path tests; as we encounter
corner-cases we can introduce new tests fixtures.
2019-06-26 20:31:36 +10:00