PowerShellV2/powershell.ts syntax error
See original GitHub issueThe powershell.ts source code line 70 -
await fs.writeFile(
filePath,
'\ufeff' + contents.join(os.EOL), // Prepend the Unicode BOM character.
{ encoding: 'utf8' });
, while fs.writeFile
syntax is fs.writeFile(file, data[, options], callback)
So my self-hosted agent decided to run my powershell task in a container via Node, I ended up with ##[error]Callback must be a function. Received { encoding: 'utf8' }
(Node 12.16.2), or ##[error]Callback must be a function
(Node 10.15.1).
After providing a dummy 4th parameter, everything works.
Issue Analytics
- State:
- Created 3 years ago
- Comments:12 (1 by maintainers)
Top Results From Across the Web
Powershell syntax error only when running as script [duplicate]
When that is ran manually by copy and pasting into Powershell, it works perfectly. However, when saving that code into a test.ps1 file,...
Read more >Set-Content (Microsoft.PowerShell.Management)
Writes new content or replaces existing content in a file. In this article. Syntax; Description; Examples; Parameters; Inputs; Outputs; Notes; Related Links ...
Read more >Solved: "running scripts is disabled on this system" in ...
Press the windows-button on your keyboard. Type 'PowerShell'; Right-click Windows PowerShell; Click Run as Administrator; Run the following ...
Read more >Error trying to edit dashboard - PowerShell Universal
SyntaxError: JSON.parse: unexpected end of data at line 1 column 1 of the JSON data ... Product: PowerShell Universal Version: 2.0.0 ```.
Read more >Fix script error an error has occurred in the script on this page ...
Some user's are having this syntax error while try to access the following servers like webex, powershell,hamachi,ebirforms,globalprotect and ...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
@waynesi it won’t until its published to your account (and once its published it will replace your cached version anyways). It gets published to your account as part of our release process which will be rolling over the next 3 weeks
Okay I’ll try with
tfx-cli
. Just how do I find the collection URI for e.g. thetfx-cli upload ....
cmd?