Граф коммитов

1791 Коммитов

Автор SHA1 Сообщение Дата
Garrett Campbell bc0f5ec9a4
Use mementos for state management for pinned commands (#4175)
* Use mementos for state management for pinned commands

* update activeCommands check
2024-11-20 15:24:32 +00:00
Joshua Goins 12ea80dd33
Improve test case failure/skip states and their output (#4116) (#4129)
* Improve test case failure/skip states and their output (#4116)

Currently if a test fails, it's not immediately clear why that is
because we give the exit code - and not the output from ctest. That is
now fixed and the ctest output is shown which greatly improves the
usefulness of the Test Results pane and other places where this output
is shown like Code Lens.

Skipped test cases were also not actually marked as skipped, and that is
now fixed as well.

* fix linter issue

---------

Co-authored-by: Garrett Campbell <gcampbell@microsoft.com>
Co-authored-by: Garrett Campbell <86264750+gcampbell-msft@users.noreply.github.com>
2024-11-11 09:09:41 -05:00
Garrett Campbell 31372d6b7f
Sanitize cmake.copyCompileCommands (#4149)
* Sanitize cmake.copyCompileCommands

* we don't need to push path again
2024-11-06 19:37:06 +00:00
hippo91 565d905ad7
fix: CTest Test Suite Delimiter prevents running all tests (#4092) (#4154)
* fix: CTest Test Suite Delimiter prevents running all tests (#4092)

* Introduces type alias (DriverMapT) to factorize type declaration
* Introduces the getProjectDriver method
* Adds comments
* Adds entry in the CHANGELOG

* Fix wrong object initialization

* Takes into account code review remarks.

Do not return CMakeDriver | String but do return CMakeDriver and throw error in case of problem

* Fix lint issue

---------

Co-authored-by: Garrett Campbell <86264750+gcampbell-msft@users.noreply.github.com>
2024-11-06 12:53:01 -05:00
Garrett Campbell 781a5a6e9b
Retire Options Moved notification (#4145) 2024-11-06 11:33:38 +00:00
Garrett Campbell 4d381d341a
Update tests after build (#4148)
* Update tests after build

* update changelog

* fix type error
2024-11-06 05:43:00 -05:00
0xemgy 220ac74783
Fix GCC linker errors not showing up in Problems View (#3950)
* gcc.ts: Replace single regex pattern with array

* CHANGELOG.md: Add GCC parsing fix

* Change parser from gnuLD to gcc for linker error diagnostics unit test

* Fix GNU LD diagnostics parser not being enabled due to inconsistency in config and in build.ts by_source strings

* Improve GCC and GNU LD diagnostics parsers

* Remove obsolete french linker error unit test

* Add gcc and gnuld diagnostics unit tests

* Clean up regexes, add unit tests

* Make gcc and gnuld parsers execution order agnostic

* Share the RegexPattern interface and the MatchType interface rather than doubly defining it

* Remove C++ template compiler error detection from gnu-ld, move common data types to util.ts

* fix extra line

* update changelog

* Remove obsolete return statement

* Add comments

---------

Co-authored-by: 0xemgy <0xemgy>
Co-authored-by: Garrett Campbell <86264750+gcampbell-msft@users.noreply.github.com>
Co-authored-by: Garrett Campbell <gcampbell@microsoft.com>
2024-11-01 13:52:55 +00:00
Garrett Campbell d0ad11e566
Support cancelling ctest execution (#4141)
* Support cancelling ctest execution

* fix wording for progress bar

* fix linter issues
2024-10-25 09:00:56 -07:00
Garrett Campbell 46f2d16e31
Refactor and improve test infrastructure, starting with automated version validation tests (#4126)
* renamed to end-to-end-tests and moved backend unit tests to unit-tests folder

* create folder for kits code, refactor imports to use @cmt and @test

* move variants into the kits folder

* refactor into better folder structure, still more to go

* Initial refactor making presets validation unit testing possible.

This seems to work well so far, I have v1-v3 presets tested, with some
more refactors regarding error reporting to come. However, the
design/infrastructure refactor seems to be allowing us to unit test
validation.

* implemented Presets version validation automated testing

* Added version testing for presets v1-9.

This adds testing for our version validation for all Presets versions
currently supported.
It creates presets on the fly and ensures that we correctly get errors,
or don't, depending on the setup and what fields are present with what
versions.

* fix workflows

* Ensure that we correctly initialize the presetsParser class

* refactor imports

* refactor imports

* more import fixes

* imports in projectStatus

* missed one

* workflow imports

* added comment about definite assignment

* add comments

* fix launch file to make sure breakpoints happen

* fix syntax error
2024-10-21 11:02:35 -07:00
Sandro Pedrett 9327d3c9ef
Add support to configure default ActiveProject (#3730)
* Implemented defaultActiveProject configuration to select default project during initialization (#1078)

* Updated docu

* Removed unused comment

* Fixed lint issues

* Fixed review findings

* Improved description of new defaultActiveFolder configuration

* Updated changelog

---------

Co-authored-by: Garrett Campbell <86264750+gcampbell-msft@users.noreply.github.com>
2024-10-10 19:58:14 +00:00
Garrett Campbell caca06d89f
fix the issue (#4111) 2024-10-10 11:33:45 -04:00
Garrett Campbell 0786aa8259
determine shell for .cmd, .bat, .ps1 (#4044)
* determine shell for .cmd, .bat, .ps1

* update changelog

* only apply fix on windows, as necessary

* undefined -> false

* use concrete if statement

* update changelog and change if statement order

* nit: remove extra space
2024-10-10 14:23:17 +00:00
Garrett Campbell 1818a7ea52
only set isUserPreset to rue if it's defined in a user presets file (#4081) 2024-10-10 13:44:26 +00:00
Garrett Campbell 2c3b07f333
fix dropdown entries (#4106) 2024-10-10 09:13:08 -04:00
Garrett Campbell 1fe127896a
support additional macros for include field for presets v9 (#4113)
* support additional macros for include field for presets v9

* use expandString and adhere to interface requirements

* revert unneeded change

* remove unnecessary change from tempErrorList to errorList

* add option for ExpansionOptions for vars to be preset contextual but not preset specific interface

* now that we've added the appropriate required preset fields, refer to them explicitly

* remove unused import

* remove unused imports
2024-10-09 13:55:46 -04:00
Lin Hsu ed37b19f51
Add command substitutions `launchTargetName` and `getLaunchTargetName` (#3979)
Co-authored-by: Garrett Campbell <86264750+gcampbell-msft@users.noreply.github.com>
2024-10-07 08:01:40 -04:00
Paul 9b6e016e72
Fix #4056, Debugger statements in production code (#4082)
Signed-off-by: paulober <44974737+paulober@users.noreply.github.com>
2024-09-30 14:49:34 +00:00
Garrett Campbell d860f0859d
update node version, @vsce/vsce, and fix build errors from node updat… (#4055)
* update node version, @vsce/vsce, and fix build errors from node update, add improved signing

* update node in ci builds

* update vscode engine

* fix copy

* don't sign vsix with VsixSha2 anymore

* update changelog
2024-09-11 06:19:52 -04:00
Garrett Campbell f35be385cb
Correctly store cache and update `binaryDir` (#4028)
* fix binary dir

* fixes the issue, but more testing and possible improvement to come

* set expandedPreset.binaryDir if already set too

* properly update caches, ensure we correctly store cached presets

* remove some unnecessary comments

* fix linter errors

* update envOverride with expandedPreset env

* update the changelog

* update parent environment when never
2024-08-30 18:42:56 +00:00
Garrett Campbell 5fbcb1364c
fix generator logic (#4033)
* fix generator logic

* fix logic

* fix logic

* fix use of gen.name
2024-08-30 14:06:55 -04:00
Garrett Campbell 4a334a60ce
if Win64 is at the end of the generator, use platform x64 (#4025) 2024-08-30 11:44:56 -04:00
Garrett Campbell f1a377045e
fix presets expansion (#4024)
* fix presets expansion

* missed a change

* update changelog
2024-08-29 16:27:15 +00:00
Garrett Campbell 5820bc55e8
return expandedPreset, not preset (#4008)
* return expandedPreset, not preset

* make sure user presets are considered
2024-08-27 13:18:55 -07:00
Fatima Qarni d04ec39e6d
fix env expansion (#3997)
* In short, with our recent updates, we are attempting to expand every
string in the environment. This isn't a problem in most cases, but it
exposed a bug in certain linux distros that use aliasing (environment
variables).

Therefore, we should be wiser about what we attempt to expand and only
expand the presets environment variables the user has in their files.
To do this, we need to be smarter about what we save in our cache and
update by reference.


* updated the other presets so they dont always have to reexpand configure preset. when they do, use plusIncludes which has the dev env cached if its been expanded before. also include the inherited parent envs

* Fix environment expansion so we don't expand unnecessary variables - don't save the process.env or parent environment to the environment field of the cache.

* Don't re-expand configure presets in the associated build/test/etc presets.

* Fix expansion reporting issues with reporting an invalid config preset, and changing for each loop to a traditional for loop to make sure we dont have async issues with reporting.

* fix validation bug for not being able to find a null config preset

---------

Co-authored-by: Garrett Campbell <gcampbell@microsoft.com>
2024-08-21 12:16:26 -07:00
Garrett Campbell a9972e5902
rollbar try catch (#3985)
Co-authored-by: Fatima Qarni <fatimaqarni@microsoft.com>
2024-08-16 12:41:53 -04:00
Garrett Campbell 4ba260c480
fix regression of kit environment variables (#3991) 2024-08-16 06:03:43 -04:00
Garrett Campbell b77a853ba2
add telemetry for developer environment use (#3975) 2024-08-13 14:50:56 -04:00
Garrett Campbell a4ff8d1716
Remove popups and update defaults for `configureOnOpen` (#3967)
* update defaults and remove popups

* update changelog

* fix types for configureOnOpen

* fix eslint
2024-08-13 05:28:34 -04:00
Garrett Campbell c848ee3705
only do special handling of ~ in linux, it breaks windows (#3965) 2024-08-08 14:49:13 -04:00
Garrett Campbell 7f2f5abb73
saving progress (#3960) 2024-08-06 14:37:26 -04:00
Garrett Campbell c779bf1fcd
Ensure we correctly inherit preset from UserPreset (#3958)
* fix

* analyze user presets first because it's the base if it exists

* more updates to fix include files and telemetry, still needs work and testing

* ensure telemetry and other uses of 'all..Presets' is right

* more fixes

* ensure we don't duplicate cmakepresets in userpresets includes

* remove unnecessary return

* unionWith consistency

* add test
2024-08-06 14:36:51 -04:00
Fatima Qarni e7cf93eec0
Set usepresets context after manually creating presets file (#3935)
Fixes #3854. Support for watching multiple paths (cmakepresets.json/cmakeuserpresets.json/include files) was broken due to a Chokidar bug. Created a wrapper class to handle this scenario.
2024-08-01 19:53:21 +00:00
moyo1997 8f32d0ca46
evaluate inherit presets based on presets that should be visible from file (#3941)
* initial changes

* modify other preset flows

* fix unused import

* remove unused import

* check for default preset

* acocunt for userpresets

* remove extra condition

---------

Co-authored-by: Garrett Campbell <gcampbell@microsoft.com>
2024-07-30 17:27:29 +00:00
Andreea Isac 27cb55e70e
Configure precondition handler to return boolean to signal a successful recovery case (#3776)
* Making configure precondition handler return a boolean helps to differentiate the successful recovery cases

* Fix pre-condition handler prototype errors in tests

* Experiment with prototypes to fix linter errors

* Add setting for building whole build dir when clean configure

* Remove anything related to deleteBuildDirOnCleanConfigure since it's in a different PR. Keep proper promise<bool> prototype for pre-configure handler return and fix appropriately compilation and lint errors in tests.

* Forgot one file to remove deleteBuildDirOnCleanConfigure from

* Remove forgotten comment

* Add changelog entry

* remove changes not needed

* removing more bad changes

* add logic to regenerate the driver after selecting cmakelists

* remove unused imports

* keep sanity check in _beforeConfigureOrBuild

* only ensure we set the variable so that on retry, it works

* switch return

* erroneous update

* fix

---------

Co-authored-by: Garrett Campbell <gcampbell@microsoft.com>
Co-authored-by: Garrett Campbell <86264750+gcampbell-msft@users.noreply.github.com>
2024-07-29 15:47:40 -04:00
fargies 97b36c94ad
Fix GitHub 1401, diagnostics relative to workspace folder (#3780)
* Fix GitHub 1401, diagnostics relative to workspace folder

 - relative diagnostics files are searched in build_dir and src_dir,
   first existing file is returned
 - defaults to old behavior : `path.resolve(build_dir, file)`
 - `resolveDiagnostics` has been made async to not slow down IDE when
   testing files

* update ChangeLog for #1401

* fix relative file resolution diagnostics test

 - diagnostics paths always use POSIX separators (see `normalizePath` in
   [src/util.ts](src/util.ts))

---------

Co-authored-by: Sylvain Fargier <sylvain.fargier@cern.ch>
Co-authored-by: Garrett Campbell <86264750+gcampbell-msft@users.noreply.github.com>
2024-07-29 14:54:26 -04:00
Garrett Campbell 998ebbd447
update telemetry key (#3944)
* update telemetry key

* typo
2024-07-29 12:10:34 -04:00
Garrett Campbell 4dc3817666
ensure we take deep copy of presets for presetsPlusIncluded (#3939) 2024-07-26 12:47:49 -04:00
Fatima Qarni 2be0df4591
check for quick start in select configure preset to prevent second configure (#3933)
Co-authored-by: Garrett Campbell <86264750+gcampbell-msft@users.noreply.github.com>
2024-07-26 08:49:23 -04:00
Jonathan Phippen ed6d9adeb3
Revert "Don't require Ninja or Make on PATH when checking generators (#3927)" (#3938)
This reverts commit bbc74d8797.
2024-07-25 11:55:39 -07:00
Fatima Qarni 1eadb61980
Preset file expansion on open/save and expansion validation (#3905)
This change changes the way we do preset file expansion. Expansion now occurs upfront on file open or save, and if there are no errors, the expanded presets will be cached so repeated expansion is not necessary every time getAll{type of preset}Presets() is called.

The only time expansion will happen again is on set preset, which will then also apply the VS developer environment as needed. This is avoided on the initial expansion for performance.

If there are errors in expansion, the errors are shown in the problems panel per file. The presets file will also be set to undefined, which will invalidate that file and not allow any presets in that file to be recognized/selected as valid presets. This is in line with the CMake command line experience.

Some notes:

- The ${generator} macro should not work for packagePresets, but should now expand correctly for all other presets and evaluate conditions correctly
- Tertiary preset cache was added (really its just the original presets cache but used in a new way) to account for included json files that wouldnt be in the original presets files
2024-07-24 15:52:00 +00:00
Jonathan Phippen bbc74d8797
Don't require Ninja or Make on PATH when checking generators (#3927) 2024-07-23 09:52:25 -07:00
stepeos 890fb569a1
implement #2521 by adding output channel argument (#3785)
* implement  #2521 by adding output channel argument

* fix failed configuration not showing output channel on "on error"

* implement review, add changelog

* fix changelog

---------

Co-authored-by: Garrett Campbell <86264750+gcampbell-msft@users.noreply.github.com>
Co-authored-by: Garrett Campbell <gcampbell@microsoft.com>
2024-07-23 13:41:47 +00:00
Jonathan Phippen 01db4d6d1f
Dispose of Launch terminal if environment has changed (#3902)
* Compare entire terminal launch environment and dispose if not equal

* Updated CHANGELOG

---------

Co-authored-by: Garrett Campbell <86264750+gcampbell-msft@users.noreply.github.com>
2024-07-22 09:33:21 -07:00
Yonggang Luo 8ed18b224a
Only visual studio 2015 neesd fixes the windows sdk path (#3837)
Co-authored-by: Garrett Campbell <86264750+gcampbell-msft@users.noreply.github.com>
2024-07-18 15:36:15 +00:00
Yonggang Luo aff67c4359
The kit name for Clang/MSVC too long, put the arch at the front (#3835)
[kit] Found Kit (trusted): Clang 17.0.3 (MSVC CLI) for MSVC 17.10.35004.147 (Visual Studio Community 2022 Release - x86)
[kit] Found Kit (trusted): Clang 17.0.3 (GNU CLI) for MSVC 17.10.35004.147 (Visual Studio Community 2022 Release - x86)
[kit] Found Kit (trusted): Clang 17.0.3 (MSVC CLI) for MSVC 17.10.35004.147 (Visual Studio Community 2022 Release - amd64)
[kit] Found Kit (trusted): Clang 17.0.3 (GNU CLI) for MSVC 17.10.35004.147 (Visual Studio Community 2022 Release - amd64)

Signed-off-by: Yonggang Luo <luoyonggang@gmail.com>
Co-authored-by: Garrett Campbell <86264750+gcampbell-msft@users.noreply.github.com>
2024-07-17 14:36:09 +00:00
Garrett Campbell bdc9f5f0c4
Add setting to control how we use VS Dev Env (#3892)
* committing state, no progress, just thinking through

* fix how we apply and override devenv to ensure we don't accidentally delete preset environment modifications from user

* check if ninja exists and it's the generator, use that to determine if we should add vs devenv as well

* currently broken, but saving state for adding a setting

* this works well, but I need to add back code that prohibits repeated devenv searching with where.exe

* finalize implementation of the setting for useVsDeveloperEnvironment

* minimize branches

* fix import

* update comments

* fix comment

* remove unnecessary comment

* fallback to better architecture/toolset

* update devenv vars and tests

* fix test for mac

* fix tests

* update changelog

* fix test expand and where.exe env

* update test to explicitly test architecture unit test

---------

Co-authored-by: snehara99 <113148726+snehara99@users.noreply.github.com>
2024-07-16 19:35:40 +00:00
Fatima Qarni 4cdfacde0a
Fix localized file path for schemas (#3906) 2024-07-16 17:32:45 +00:00
snehara99 a63562f0a8
if installDir is a relative path, calculate it relative to the source directory (#3903)
* if installDir is a relative path, I calculate it relative to the source dir

* updated location of checking and updating installDir

* combined with expansion check
2024-07-15 21:14:32 +00:00
Garrett Campbell e263ecd226
fix our depth search for CMakeLists.txt (#3904) 2024-07-15 16:30:13 -04:00
moyo1997 15ad70769f
show build task if preset is set to activebuildpreset (#3898)
* show build task if preset is set to activebuildpreset

* changelog
2024-07-12 10:12:23 -07:00