Can anyone do a simple config for the foot terminal?

Earlier I posted this Linux & Tech news 📰 - #1253 by Colin which has a link to the 26 Best Free Linux Terminal Emulators.

I decided to give the foot terminal a try...

... and I'm highly impressed with how few resources it uses - it uses <1% of my CPU and only 23MB RAM. Here's a btop screenshot showing foot's frugality:

This is one of the few YouTube videos I found about it:

I've had a look at how it should be configured...

https://man.archlinux.org/man/foot.ini.5.en

...but it has left me baffled.

Can anyone sort the following config file for use with Garuda? I'm not looking for anything complex, just the basics.

# -*- conf -*-

# shell=$SHELL (if set, otherwise user's default shell from /etc/passwd)
# term=foot (or xterm-256color if built with -Dterminfo=disabled)
# login-shell=no

# app-id=foot
# title=foot
# locked-title=no

# font=monospace:size=8
# font-bold=<bold variant of regular font>
# font-italic=<italic variant of regular font>
# font-bold-italic=<bold+italic variant of regular font>
# font-size-adjustment=0.5
# line-height=<font metrics>
# letter-spacing=0
# horizontal-letter-offset=0
# vertical-letter-offset=0
# underline-offset=<font metrics>
# underline-thickness=<font underline thickness>
# box-drawings-uses-font-glyphs=no
# dpi-aware=auto

# initial-window-size-pixels=700x500  # Or,
# initial-window-size-chars=<COLSxROWS>
# initial-window-mode=windowed
# pad=0x0                             # optionally append 'center'
# resize-delay-ms=100

# notify=notify-send -a ${app-id} -i ${app-id} ${title} ${body}

# bold-text-in-bright=no
# word-delimiters=,│`|:"'()[]{}<>
# selection-target=primary
# workers=<number of logical CPUs>
# utempter=/usr/lib/utempter/utempter

[environment]
# name=value

[bell]
# urgent=no
# notify=no
# command=
# command-focused=no

[scrollback]
# lines=1000
# multiplier=3.0
# indicator-position=relative
# indicator-format=""

[url]
# launch=xdg-open ${url}
# label-letters=sadfjklewcmpgh
# osc8-underline=url-mode
# protocols=http, https, ftp, ftps, file, gemini, gopher
# uri-characters=abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789-_.,~:;/?#@!$&%*+="'()[]

[cursor]
# style=block
# color=<inverse foreground/background>
# blink=no
# beam-thickness=1.5
# underline-thickness=<font underline thickness>

[mouse]
# hide-when-typing=no
# alternate-scroll-mode=yes

[colors]
# alpha=1.0
# background=002b36
# foreground=839496

## Normal/regular colors (color palette 0-7)
# regular0=073642  # black
# regular1=dc322f  # red
# regular2=859900  # green
# regular3=b58900  # yellow
# regular4=268bd2  # blue
# regular5=d33682  # magenta
# regular6=2aa198  # cyan
# regular7=eee8d5  # white

## Bright colors (color palette 8-15)
# bright0=08404f   # bright black
# bright1=e35f5c   # bright red
# bright2=9fb700   # bright green
# bright3=d9a400   # bright yellow
# bright4=4ba1de   # bright blue
# bright5=dc619d   # bright magenta
# bright6=32c1b6   # bright cyan
# bright7=ffffff   # bright white

## dimmed colors (see foot.ini(5) man page)
# dim0=<not set>
# ...
# dim7=<not-set>

## The remaining 256-color palette
# 16 = <256-color palette #16>
# ...
# 255 = <256-color palette #255>

## Misc colors
# selection-foreground=<inverse foreground/background>
# selection-background=<inverse foreground/background>
# jump-labels=<regular0> <regular3>          # black-on-yellow
# scrollback-indicator=<regular0> <bright4>  # black-on-bright-blue
# search-box-no-match=<regular0> <regular1>  # black-on-red
# search-box-match=<regular0> <regular3>     # black-on-yellow
# urls=<regular3>

[csd]
# preferred=server
# size=26
# font=<primary font>
# color=<foreground color>
# hide-when-typing=no
# border-width=0
# border-color=<csd.color>
# button-width=26
# button-color=<background color>
# button-minimize-color=<regular4>
# button-maximize-color=<regular2>
# button-close-color=<regular1>

[key-bindings]
# scrollback-up-page=Shift+Page_Up
# scrollback-up-half-page=none
# scrollback-up-line=none
# scrollback-down-page=Shift+Page_Down
# scrollback-down-half-page=none
# scrollback-down-line=none
# clipboard-copy=Control+Shift+c XF86Copy
# clipboard-paste=Control+Shift+v XF86Paste
# primary-paste=Shift+Insert
# search-start=Control+Shift+r
# font-increase=Control+plus Control+equal Control+KP_Add
# font-decrease=Control+minus Control+KP_Subtract
# font-reset=Control+0 Control+KP_0
# spawn-terminal=Control+Shift+n
# minimize=none
# maximize=none
# fullscreen=none
# pipe-visible=[sh -c "xurls | fuzzel | xargs -r firefox"] none
# pipe-scrollback=[sh -c "xurls | fuzzel | xargs -r firefox"] none
# pipe-selected=[xargs -r firefox] none
# show-urls-launch=Control+Shift+u
# show-urls-copy=none
# show-urls-persistent=none
# prompt-prev=Control+Shift+z
# prompt-next=Control+Shift+x
# unicode-input=none
# noop=none

[search-bindings]
# cancel=Control+g Control+c Escape
# commit=Return
# find-prev=Control+r
# find-next=Control+s
# cursor-left=Left Control+b
# cursor-left-word=Control+Left Mod1+b
# cursor-right=Right Control+f
# cursor-right-word=Control+Right Mod1+f
# cursor-home=Home Control+a
# cursor-end=End Control+e
# delete-prev=BackSpace
# delete-prev-word=Mod1+BackSpace Control+BackSpace
# delete-next=Delete
# delete-next-word=Mod1+d Control+Delete
# extend-to-word-boundary=Control+w
# extend-to-next-whitespace=Control+Shift+w
# clipboard-paste=Control+v Control+Shift+v Control+y XF86Paste
# primary-paste=Shift+Insert
# unicode-input=none

[url-bindings]
# cancel=Control+g Control+c Control+d Escape
# toggle-url-visible=t

[text-bindings]
# \x03=Mod4+c  # Map Super+c -> Ctrl+c

[mouse-bindings]
# selection-override-modifiers=Shift
# primary-paste=BTN_MIDDLE
# select-begin=BTN_LEFT
# select-begin-block=Control+BTN_LEFT
# select-extend=BTN_RIGHT
# select-extend-character-wise=Control+BTN_RIGHT
# select-word=BTN_LEFT-2
# select-word-whitespace=Control+BTN_LEFT-2
# select-row=BTN_LEFT-3

# vim: ft=dosini

You don't really need to configure anything to use Foot--you can run it as-is.

All those commented lines in the config file are the default settings the terminal will use. If you want to change something, then you would go in and uncomment that line and set the value you would prefer to use.

As an example, the default configuration has the setting font=monospace:size=8, which is super small on my laptop screen so I have uncommented that line and changed it to font=DejaVuSansMono:size=11.

Another example would be they recently changed the default colors of the terminal (the background is kind of green, and the font colors are different), but I had grown to really like the old color scheme so I uncommented those values in ~/.config/foot/foot.ini and set them to the old values:

[colors]
 alpha=1.0
 foreground=dcdccc
 background=111111

## Normal/regular colors (color palette 0-7)
 regular0=222222  # black
 regular1=cc9393  # red
 regular2=7f9f7f  # green
 regular3=d0bf8f  # yellow
 regular4=6ca0a3  # blue
 regular5=dc8cc3  # magenta
 regular6=93e0e3  # cyan
 regular7=dcdccc  # white

## Bright colors (color palette 8-15)
 bright0=666666   # bright black
 bright1=dca3a3   # bright red
 bright2=bfebbf   # bright green
 bright3=f0dfaf   # bright yellow
 bright4=8cd0d3   # bright blue
 bright5=fcace3   # bright magenta
 bright6=b3ffff   # bright cyan
 bright7=ffffff   # bright white

Basically, the only options you need to configure are the ones that you wish to be different from the defaults.

I would say go ahead and start using it, and if you run into any features you don't like then read through the documentation for that feature and figure out what you need to set in the config file to get the results you want.

Here is the page for the project:

2 Likes

Thanks for your quick reply.

All I'm looking for is for foot to use fish like the Garuda terminal does, but I'm not sure what to modify.

If you want Fish to be the default shell no matter what terminal you are using, you can use the chsh command like so:

chsh -s /bin/fish

That will change the default shell for the user running the command, so whenever that user opens a terminal it will automatically be the Fish shell.

If you wish to set a default shell in Foot, but leave the user-specific shell default alone, set it in the foot.ini in the "shell" option (one of the first few lines).

Change

# shell=$SHELL (if set, otherwise user's default shell from /etc/passwd)

to

shell=/bin/fish
2 Likes

Many thanks for the advice.

foot now works as required and I think I'll be sticking with it.

1 Like

Foot is a pretty great terminal, it's highly configurable and super fast--nearly as fast as the GPU-accelerated terminals, but as you point out it has very modest resource usage.

It also has built-in Sixel support, so you can print pictures right in the terminal--even over SSH. Check out these great Sixel projects that work out of the box with the Foot terminal:

1 Like

Thanks for the info.

You got me curious so I had a look for some benchmarks, and here’s some:

It is apparently so fast because it uses Wayland’s method of putting data on-screen rather than the old Xorg method.

Your mention of images also got me curious as to whether foot could display Fastfetch like images like…

…because it’s fantastic eye candy.

It looks like it can when the hidden gem notcurses is used…

…notcurses isn’t restricted to the foot terminal, others such as Kitty can use it. The technical stuff is way over my head, but the results of its use speak for themselves.

1 Like

In this article the Foot dev explains why it is so fast:

He puts it head-to-head with Alacritty, which is also Wayland-native but is GPU-rendered. In cases where the entire window needs to be redrawn, Alacritty comes out ahead (as expected), but in some of the other tests Foot is actually faster. :flushed:

2 Likes

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.