-
-
Notifications
You must be signed in to change notification settings - Fork 81
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
bump typescript => 5.2.2; migrate to ESM #1979
Conversation
Heh, I anticipated the build failing the moment I saw the PR title 😂 |
We need to bump typescript-eslint and prettier before typescript anyway. |
would you recommend doing that in a separate PR or combine with this one? |
Our typescript-eslint version disagrees with our current typescript version anyway, so we need to bump it regardless. |
dd43c8d
to
5b106ce
Compare
- In preparation for #1979 ## Checklist - [ ] I have added [tests](https://www.cursorless.org/docs/contributing/test-case-recorder/) - [ ] I have updated the [docs](https://github.com/cursorless-dev/cursorless/tree/main/docs) and [cheatsheet](https://github.com/cursorless-dev/cursorless/tree/main/cursorless-talon/src/cheatsheet) - [ ] I have not broken the cheatsheet
...and we're green!! 🙌 But do give stuff a whirl locally on windows @AndreasArvidsson to make sure it works for you 😅 (don't forget to do a pnpm install and pnpm clean) |
No
I'm working on a solution |
@pokey After I fixed the support for absolute paths in my latest commit I still can't run scripts like preprocess hats because CURSORLESS_REPO_ROOT is missing from the environmental variables
|
Ok that is fixed now. I must say I'm not a big fan of having to add these really complicated run scripts with env. |
Yeah it's the whole Maybe something like evanw/esbuild#859 (comment) |
We could switch to using cross-spawn. That's more robust and I believe supports spaces. Or I could go back to my bash script for my-ts-node. Translating it to a node script was a Hail Mary that I thought would help windows CI and turned out to be totally irrelevant but I left it because js is a bit easier to read |
I definitely prefer javascript over bash |
I guess we could also use a heuristic like looking for a .git directory and a couple child files we know should be in root But basically the old way was pretty dicey. Eg we were relying on the fact that transpiled code was at same level of nesting, etc |
meta updater just looks for |
Yeah that could work. Would make the function need to be async or I guess just read synchronously Or we could bake computing the env var into the my-ts-node script now that we own it |
ok @AndreasArvidsson have a look at my latest changes and lmk if things still work locally for you; I
|
Works fine here |
great! have a look at the code when you get a minute; it's not nearly as long as the diff implies. the vast majority of the lines of code are in the pnpm lockfile. If you're happy, let's give @auscompgeek a chance to have a look and then let's ship it! |
ok @auscompgeek I'm going to go ahead and merge this one in, but feel free to leave comments when you get a minute and I can fix in follow-ups. Biggest remaining annoyance from my perspective is that every test file (eg |
Checklist