GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — doc: document fs.write limitation with TTY · nodejs/node@2ebb32b

File tree

Expand file treeCollapse file tree
Open diff view settings
Filter options
  • doc/api
    • fs.md
Expand file treeCollapse file tree
Open diff view settings
Collapse file

‎doc/api/fs.md‎

Copy file name to clipboardExpand all lines: doc/api/fs.md
+8Lines changed: 8 additions & 0 deletions
  • Display the source diff
  • Display the rich diff
Original file line numberDiff line numberDiff line change
@@ -3528,6 +3528,13 @@ On Linux, positional writes don't work when the file is opened in append mode.
35283528
The kernel ignores the position argument and always appends the data to
35293529
the end of the file.
35303530

3531+
On Windows, if the file descriptor is connected to the console (e.g. `fd == 1`
3532+
or `stdout`) a string containing non-ASCII characters will not be rendered
3533+
properly by default, regardless of the encoding used.
3534+
It is possible to configure the console to render UTF-8 properly by changing the
3535+
active codepage with the `chcp 65001` command. See the [chcp][] docs for more
3536+
details.
3537+
35313538
## fs.writeFile(file, data[, options], callback)
35323539
<!-- YAML
35333540
added: v0.1.29
@@ -4926,3 +4933,4 @@ the file contents.
49264933
[MSDN-Using-Streams]: https://docs.microsoft.com/en-us/windows/desktop/FileIO/using-streams
49274934
[support of file system `flags`]: #fs_file_system_flags
49284935
[File Access Constants]: #fs_file_access_constants
4936+
[chcp]: https://ss64.com/nt/chcp.html

0 commit comments

Comments
0 (0)
You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.