Skip to content

O_NERD and O_EMOJI creates duplicate letters in filename #1692

@FelixKratz

Description

@FelixKratz

Environment details (Put x in the checkbox along with the information)

  • Operating System: macOS Ventura
  • Desktop Environment: Aqua
  • Terminal Emulator: kitty, Alacritty
  • Shell: zsh
  • Custom desktop opener (if applicable):
  • Program options used: none
  • Configuration options set: O_NERD
  • Plugins are installed
  • Issue exists on nnn master

Exact steps to reproduce the issue

Clone the repo, enable nerdfonts in the makefile

O_NERD := 1  # support icons-nerdfont

and compile with LDLIBS="-L/opt/homebrew/opt/ncurses/lib/" make.

Some files (with certain icons it appears) have duplicate initial letters as seen in the screenshot below:
Screenshot 2023-07-14 at 11 48 58

as soon as I select the makefile it will also have the duplicate initial letter:
Screenshot 2023-07-14 at 11 54 34

I have done some testing, this seems to also happen with O_EMOJI is set to enabled:
Screenshot 2023-07-14 at 11 56 51

but not with O_ICONS enabled:
Screenshot 2023-07-14 at 11 57 37

I have peeked into the source code to find what is different between those options, but did not find a convincing clue.

I have also checked with kitty and alacritty, they both face the same problem.

These are the dynamic libs used by nnn:

 x otool -L ./nnn
./nnn:
	/usr/lib/libedit.3.dylib (compatibility version 2.0.0, current version 3.0.0)
	/opt/homebrew/opt/ncurses/lib/libncursesw.6.dylib (compatibility version 6.0.0, current version 6.0.0)
	/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 1319.0.0)

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions