Giter Site home page Giter Site logo

Comments (6)

fdncred avatar fdncred commented on July 22, 2024

Nushell uses rust strings which are utf-8 already so there's no need to change anything in nushell to get utf-8.

from nushell.

timxx avatar timxx commented on July 22, 2024

Nushell uses rust strings which are utf-8 already so there's no need to change anything in nushell to get utf-8.

But seems not work for git

image

I can use chcp 65001 for workaround, but I have to set it every new nushell window.
image

from nushell.

fdncred avatar fdncred commented on July 22, 2024

So, that means your question is how to set your terminal to 65001 every time. I've googled it before and that's what I did for my Windows machine. So I know it's possible. IIRC, there was some registry setting I had to change.

from nushell.

devyn avatar devyn commented on July 22, 2024

Sounds like it's probably the region settings control panel, where you can set UTF-8 as the "non-Unicode" codepage (remember: Unicode in Windows means wide char UTF-16)

https://stackoverflow.com/a/57134096/371407

All Windows console hosts including Windows Terminal use the system code page encoding, not wide chars, which is why you have to chcp

from nushell.

timxx avatar timxx commented on July 22, 2024

So, that means your question is how to set your terminal to 65001 every time. I've googled it before and that's what I did for my Windows machine. So I know it's possible. IIRC, there was some registry setting I had to change.

I'd prefer use nushell it's way, not by calling chcp. Such as powershell can change with $OutputEncoding = [Console]::OutputEncoding = [System.Text.Encoding]::UTF8, and can be added to profile

from nushell.

timxx avatar timxx commented on July 22, 2024

Sounds like it's probably the region settings control panel, where you can set UTF-8 as the "non-Unicode" codepage (remember: Unicode in Windows means wide char UTF-16)

https://stackoverflow.com/a/57134096/371407

All Windows console hosts including Windows Terminal use the system code page encoding, not wide chars, which is why you have to chcp

I have tried the regional settings before, but the impact is too great. Some software does not support it, which will also cause the entire interface to become garbled.

from nushell.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.