Commit Graph

31 Commits

Author SHA1 Message Date
Matt Bierner
2648263d3e Run our build scripts directly as typescript (#277567)
* Run our build scripts directly as typescript #277567

Follow up on #276864
For #277526

* Remove a few more ts-node references

* Fix linux and script reference

* Remove `_build-script` ref

* Fix script missing closing quote

* use type only import

* Fix export

* Make sure to run copy-policy-dto

* Make sure we run the copy-policy-dto script

* Enable `verbatimModuleSyntax`

* Pipelines fixes

* Try adding explicit ext to path

* Fix bad edit

* Revert extra `--`

---------

Co-authored-by: João Moreno <joaomoreno@users.noreply.github.com>
2025-11-21 14:56:00 +01:00
Johannes Rieken
626370b3f7 no more any-casts in tsb land, https://github.com/microsoft/vscode/issues/269213 (#270192) 2025-10-07 15:07:24 +02:00
Matt Bierner
360c9fd134 Add lint rule for as any and bulk ignore all existing breaks
For #269213

This adds a new eslint rule for `as any` and `<any>({... })`. We'd like to remove almost all of these, however right now the first goal is to prevent them in new code. That's why with this first PR I simply add `eslint-disable` comments for all breaks

Trying to get this change in soon after branching off for release to hopefully minimize disruption during debt week work
2025-10-02 23:38:33 -07:00
Johannes Rieken
3f527562bb Fix cyclic dependency reporting in chat module (#269095)
* fix cyclic dependency in chat land

* make sure cyclic dependencies are correctly reported when running  complie-client task
2025-09-30 15:09:13 +00:00
Robo
2305e3bbcd ci: fix linux node_modules publish pipeline (#256781)
* ci: fix linux node_modules publish pipeline

* fix: build
2025-07-21 18:09:57 +09:00
Connor Peet
cac4de4186 fix cycle checker on windows 2025-06-09 10:57:54 -07:00
Johannes
9a7cbdef4d stable cycle reporting 2025-06-09 15:38:23 +02:00
Johannes
c5af7e2424 fix & improve reporting of cyclic dependencies 2025-06-09 15:02:25 +02:00
Johannes
6bb8066506 fix tsb cyclic dependency check 2025-06-09 14:37:05 +02:00
Johannes Rieken
938caeaa2f Merge branch 'main' into tmm1/build-improvements 2025-04-01 11:59:57 +02:00
Johannes Rieken
b14a80cb7f fix https://github.com/microsoft/vscode/issues/241094 (#241114) 2025-02-18 19:53:44 +01:00
Johannes Rieken
f6fb04a2bb Merge pull request #238409 from tmm1/tmm1/tsb-edgecase
tsb: fix for deleted and re-added source file not being re-generated
2025-01-31 14:01:03 +01:00
Aman Karmani
e76c50f20e build: switch build/tsconfig.json to module: nodenext (#238426)
* build/tsconfig: switch to module: nodenext for bun compat

* build: rewrite imports for nodenext compat

* build: re-generate
2025-01-22 20:12:39 +01:00
Aman Karmani
61e52c3265 tsb: fix for deleted and re-added source file not being re-generated 2025-01-21 14:21:13 -08:00
Aman Karmani
fb0388deb6 tsb: avoid processing css imports 2025-01-07 18:04:08 -08:00
Aman Karmani
33c3dbafa4 tsb - normalize filenames consistently in add/removeScriptSnapshot 2025-01-07 18:03:38 -08:00
Johannes Rieken
a40e594f25 Check for cyclic dependencies during compile (#235808)
* Check for cyclic dependencies during compile

Changes gulp-tsb to check the emitted JS code for cyclic dependencies. Historically we never cared about cycles between TS files as long as they dissappeared after compile (e.g type-dependencies, not runtime dependencies)

https://github.com/microsoft/vscode-internalbacklog/issues/5271

* fix cycling dependencies

fyi @aeschli @aiday-mar

* remove cyclic dependency with unused `BasedTextEdit` fyi @hediet

* remove cycle between chatEditService and chatEditingSession

fyi @alexdima

* remove cyclic dependency between chatSetup and chatViewPane

fyi @roblourens

* better cycle detection

* don't check cycles when not needed

* clear graph when reprocessing file dependencies

* remove cycle between with `notebookChatEditController` fyi @DonJayamanne

* modernize and cleanup tsb/utils
2024-12-11 11:26:59 +01:00
Robo
b5a6aa14a8 feat: switch to npm as default package manager (#226927)
* feat: move from yarn to npm

* chore: skip yarn.lock files

* fix: playwright download

* chore: fix compile and hygiene

* chore: bump vsce@2.17.0

Refs 8b49e9dfdf

* test: update results for bat and sh colorizer tests

* fix: add missing lock files for windows

* fix: switch to legacy-peer-deps

* chore: update markdown-it@14.1.0

Refs 737c95a129

esbuild step in extensions-ci-pr was previously using markdown-it
from root which had userland punycode and was able to compile successfully.

* ci: increase pr timeout for windows integration tests

* chore: fix product build

* build: ignore extension dev dependency for rcedit

* build: fix working directory inside container

* build: fix dependency generation

* npm: update dependencies

* ci: use global npmrc

* ci: update cache

* ci: setup global npmrc for private npm auth

* build: fix extension bundling

* chore: sync npm dependencies

* ci: debug env variables for container

* ci: fix win32 cli pipeline

* build: fix npmrc config usage for build/ and remote/ dirs

* fix: windows build

* fix: container builds

* fix: markdown-language-features tests and bundling

```
[03:58:22] Error: Command failed: /Users/demohan/.nvm/versions/node/v20.15.1/bin/node /Users/demohan/github/vscode/extensions/markdown-language-features/esbuild-notebook.js --outputRoot /Users/demohan/github/vscode/.build/extensions/markdown-language-features
✘ [ERROR] Could not resolve "punycode"

    extensions/markdown-language-features/node_modules/markdown-it/lib/index.js:14:27:
      14 │ var punycode     = require('punycode');
         ╵                            ~~~~~~~~~~

  The package "punycode" wasn't found on the file system but is built into node. Are you trying to bundle for node? You can use "platform: 'node'" to do that, which will remove this error.
```

Adds userland package based on beed9aee2c

* fix: container builds for distro

* chore: update yarn occurrences

* fixup! chore: bump vsce@2.17.0

Uses the closest version to `main` branch that does not
include d3cc84cdec
while still having the fix 8b49e9dfdf

* chore: sync npm dependencies

* chore: sync npm dependencies

* chore: sync npm dependencies

* chore: throw error when yarn is used for installation

* chore: add review feedback

* chore: switch exec => run where needed

* chore: npm sync dependencies

* fix: markdown-language-features bundling

```
✘ [ERROR] Could not resolve "punycode"

    extensions/markdown-language-features/node_modules/markdown-it/lib/index.js:14:27:
      14 │ var punycode     = require('punycode');
         ╵                            ~~~~~~~~~~

  The package "punycode" wasn't found on the file system but is built into node. Are you trying to bundle for node? You can use "platform: 'node'" to do that, which will remove this error.
```

Adds missing userland package based on markdown-it/markdown-it@beed9ae,
can be removed once we update markdown-it >= 14.1.0

* ci: rename no-yarn-lock-changes.yml

* chore: sync npm dependencies

* ci: restore no-yarn-lock-changes.yml

We can disable it in a separate PR to keep the required
checks happy and also need workflow edit perms.

* chore: sync npm dependencies

* ci: rebuild cache

* ci: fix no-package-lock-changes.yml

* chore: bump distro

* chore: rm yarn.lock files

* chore: rm yarn.lock files without dependencies

* chore: add vscode-selfhost-import-aid to postinstall dirs

* chore: bump distro
2024-09-06 22:18:02 +09:00
Johannes Rieken
e1cc3fa181 tsb should handle .js suffix (#227544)
fixes https://github.com/microsoft/vscode/issues/227540
2024-09-04 10:36:15 +02:00
Johannes Rieken
236d5dc072 sha256 over md5 (#202985)
* `sha256` over `md5`

* add missing JS file
2024-01-22 14:40:18 +01:00
Johannes
0d5f87e9dd change source map merge logic to be like applying line edits to the typescript source maps (based on the input source maps) 2022-12-14 15:57:55 +01:00
Johannes
f73bb21f27 wip 2022-12-02 13:03:16 +01:00
Johannes
eda80f2065 Merge branch 'main' into joh/voluminous-lobster 2022-06-09 16:47:09 +02:00
Johannes
ba66d68c76 add transpile only stream to tsb, using ts.transpile.
https://github.com/Microsoft/TypeScript/wiki/Using-the-Compiler-API#a-simple-transform-function
2022-06-09 15:00:55 +02:00
Johannes
43c31079ee manual fixing of prefer-const violations 2022-06-09 10:19:56 +02:00
Johannes
0656d21d11 auto-fixed prefer-const violation 2022-06-08 17:49:21 +02:00
Johannes
1105ead47b add a transpileOnly option to gulp-tsb 2022-06-08 17:33:54 +02:00
João Moreno
5854ef865c Generate policies again (#149322)
* Generate ADMX/ADML policy declaration files from static analysis

Fixes: #148941

* fix build

* move to optional dependencies
2022-05-12 09:16:03 +02:00
Joyce Er
ba8ced85c5 Revert "Generate ADMX/ADML policy declaration files from static analysis" (#149194)
This reverts commit dcfe6b3b84.
2022-05-10 16:30:34 -07:00
João Moreno
dcfe6b3b84 Generate ADMX/ADML policy declaration files from static analysis
Fixes: #148941
2022-05-10 13:17:05 +02:00
Johannes
c13d581bce move gulp-tsb into the build/lib remove as dependency 2022-05-05 11:35:33 +02:00