sebastiencs / icons-in-terminal

Use any fonts in the terminal without replacing or patching
MIT License
984 stars 46 forks source link

Can’t get it running on MacOS #42

Open iCraft85 opened 2 years ago

iCraft85 commented 2 years ago

Hi! I git cloned the repo and then I used ./install.sh. The output I received is the following:

+ DATA=/Users/user/.local/share/icons-in-terminal/
+ mkdir -p /Users/user/.fonts
+ cp ./build/icons-in-terminal.ttf /Users/user/.fonts/
+ mkdir -p /Users/user/.config/fontconfig/conf.d
+ ./scripts/generate_fontconfig.sh
./scripts/generate_fontconfig.sh: line 20: fc-list: command not found
+ fc-cache -fvr --really-force /Users/baner75418/.fonts
./install.sh: line 30: fc-cache: command not found

After this I ran the following commands because I am not sure but I think that's what I have to do. All of the commands ran but after that when I ran the command ./scripts/generate_fontconfig.sh I received the following output:

<?xml version="1.0"?>
<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
<fontconfig>
  <!-- You are supposed to remove all the lines but the one(s) where the font is used in your terminal -->
  <!-- Only monospaced fonts have been listed here -->
  <!-- If your font isn't in the list, uncomment the next line and write its name -->
  <!-- <alias><family>YOUR_TERMINAL_FONT</family><default><family>icons-in-terminal</family></default></alias> -->
./scripts/generate_fontconfig.sh: line 20: fc-list: command not found
  <alias><family>Monospace</family><default><family>icons-in-terminal</family></default></alias>
</fontconfig>

After I got to this part I got really confused on what it wanted me to do. How should I proceed from here.

Terminal: Kitty Shell: ZSH macOS Version: Big Sur 11.5.2

nowell-morris commented 1 year ago

line 20: fc-list: command not found This means you have not installed fontconfig as a package. It is not a standard package for a Mac system, but is a very common package on Linux. You can install it with homebrew: brew install fontconfig I got this far, but I am getting no display of icons, myself. I get a squarebox with a question mark in it
Terminal: iTerm2 Shell: bash (homebrew latest bash, 5.1.16) macOS: Monterey 12.5 on M1

2KAbhishek commented 1 year ago

Same issue I'm just seeing the glyphs as text:

firacode (116 glyphs):
\uee2d  \uee2e  \uee2f  \uee30  \uee31  \uee32  \uee33  \uee34  \uee35  \uee36
ed9w2in6 commented 8 months ago

Please read the first issue of this project: https://github.com/sebastiencs/icons-in-terminal/issues/1

This is duplicated.

In short you will need both fontconfig and double clicking the font install to Apple's font book for macos. For kitty I configure sth like this: symbol_map U+E000-U+EEA0 icons-in-terminal.

Use an alternative script in https://github.com/sebastiencs/icons-in-terminal/issues/1 for testing. It should still work, see my answer here: https://github.com/sebastiencs/icons-in-terminal/issues/52#issuecomment-1786613456