Skip to content

Commit

Permalink
Add a note for Windows folks about Unicode :')
Browse files Browse the repository at this point in the history
  • Loading branch information
keithfancher committed Feb 17, 2023
1 parent 4f54d82 commit d1c6d01
Showing 1 changed file with 22 additions and 0 deletions.
22 changes: 22 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,28 @@ $ kept -s "~/Takeout/Keep/Great Ideas.json"
```


## Important note for Windows users!

**Unicode support in the Windows console is dicey.** (Yes, even in
PowerShell!) To ensure your notes are converted as expected:

1. Use PowerShell. (Or anything other than the default `cmd.exe`, probably.)
2. Do the following magical incantation to properly enable UTF-8:
```
$OutputEncoding = [console]::InputEncoding = [console]::OutputEncoding =
New-Object System.Text.UTF8Encoding
```

Only *after* the above should you use `kept` to convert your notes. For more
information (and instructions on how to permanently un-break UTF-8 in the
Windows console) check out [this S.O.
post](https://stackoverflow.com/a/49481797).

If you do *not* do the above step, and your notes contain *any Unicode
characters whatsoever*, you will likely see `invalid character` errors and
your notes **will not be properly exported**.


## Installation

You've got two options:
Expand Down

0 comments on commit d1c6d01

Please sign in to comment.