on 2021 Jul 12 1:58 PM
Hi there,
When trying to use cds-ts with PowerShell I received the following error message:
&: C:\Users\<user>\AppData\Roaming\npm\cds-ts.ps1:15:5
Line |
15 | & "ts-node$exe" "$basedir/node_modules/@sap/cds-dk/bin/cds-ts.js" …
| ~~~~~~~~~~~~~
| The term 'ts-node.exe' is not recognized as a name of a cmdlet, function, script file, or executable program. Check the spelling of the name, or if a path was included, verify that the path is correct and try again.
Removing $exe solves the issue for me. Might be something to look into.
Best regards,
Tobias
Request clarification before answering.
Hello CAPpers,
after following other suggestions as well to save adjustment efforts of the cds-ts module all the time, I I've tried to set newly installed Powershell
7 as default under settings in Terminal as well, so VSCode opens new
Powershell 7 (pwsh) as default terminal.
I stilled faced the issue, as alternate I tried to run it with
npx cds-ts run
It seems working properly including debugging, so I started to use it in package.json and launch.json in VSCode.
Best regards
Attila
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
TypeScript is intened for dev-time. For deployment you compile to normal JavaScript. Check out https://cap.cloud.sap/docs/tools/cds-typer#integrate-into-your-build-process for the details.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
80 | |
30 | |
10 | |
8 | |
8 | |
7 | |
6 | |
6 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.