• 请不要在回答技术问题时复制粘贴 AI 生成的内容
niseceric
V2EX  ›  程序员

有没有用 oh-my-zsh 配置 zsh 的,在终端遇到过粘贴中文时候乱码啊。。。

  •  
  •   niseceric · Oct 4, 2015 · 7089 views
    This topic created in 4048 days ago, the information mentioned may be changed or developed.

    我猜测是 自动转义 锅。。。

    一般 会把 & 自动粘贴成 &
    但是突然粘贴中文就傻了。。。卡住, ctrl-c 之后就是乱码。。。

    怎么把 url-quote-magic 关掉呢。。。

    我是 zsh5.1.1 ,刚刚更新的 oh-my-zsh 。。。

    Supplement 1  ·  Oct 4, 2015
    已经确认是 zsh5.1.1 的 bug 。。。 坑啊
    12 replies  •  2021-07-12 15:58:55 +08:00
    z742364692
    z742364692
    Oct 4, 2015 via Android
    1
    没用过中文,暂时还没遇到
    iShao
    iShao
    Oct 4, 2015
    2
    没遇到 ( omz 最新版使用中)
    niseceric
    niseceric
    OP
    Oct 4, 2015
    3
    @iShao 请问 你 zsh 的版本是 5.1.1 么 我猜是 zsh 的锅。。。 我用 osx 自带的 5.0.8 就好好的额
    iShao
    iShao
    Oct 4, 2015 via Android
    4
    @niseceric zsh 没升级过,应该还是系统自带的版本
    niseceric
    niseceric
    OP
    Oct 4, 2015
    5
    @iShao 确认了, zsh 5.1.1 的 bug , bracketed-paste-magic 的问题,和 ohmyzsh 无关。。。
    Axurez
    Axurez
    Oct 6, 2015
    6
    乱码?我只遇到过把原编码打出来的,还有无法识别颜色编码的。。。
    Leone27
    Leone27
    Oct 9, 2015
    7
    zsh_5.1-1_amd64 今天同样遇到这个问题。
    figozhu
    figozhu
    Dec 22, 2015
    8
    @niseceric 怎么解决呢?
    niseceric
    niseceric
    OP
    Dec 22, 2015
    9
    @figozhu 降级 5.08 or 升级 5.2
    figozhu
    figozhu
    Dec 23, 2015
    10
    @niseceric 升级到 5.2 了,之前是粘贴没反应。
    现在是粘贴 /输入后,是显示 <ffffffff><ffffffff><ffffffff><ffffffff><ffffffff><ffffffff>
    figozhu
    figozhu
    Jan 5, 2016
    11
    搞定了,在~/.zshrc 文件末尾增加 2 个 export ,设置字符集
    export LC_ALL=en_US.UTF-8
    export LANG=en_US.UTF-8
    Fortississimo16
    Fortississimo16
    Jul 12, 2021
    12
    @figozhu 感谢,解决了我的问题
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Privacy   ·   Solana   ·   4997 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 37ms · UTC 03:46 · PVG 11:46 · LAX 19:46 · JFK 22:46
    ♥ Do have faith in what you're doing.