<feed xmlns='http://www.w3.org/2005/Atom'>
<title>mirrors/foot.git/main.c, branch 1.18.0</title>
<subtitle>A fast, lightweight and minimalistic Wayland terminal emulator</subtitle>
<id>https://git.0x0f.dev/mirrors/foot.git/atom?h=1.18.0</id>
<link rel='self' href='https://git.0x0f.dev/mirrors/foot.git/atom?h=1.18.0'/>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/'/>
<updated>2024-08-02T06:28:13Z</updated>
<entry>
<title>Remove a number of unused includes</title>
<updated>2024-08-02T06:28:13Z</updated>
<author>
<name>Daniel Eklöf</name>
<email>daniel@ekloef.se</email>
</author>
<published>2024-08-01T18:11:04Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=a9e462d952ca1e0367e9e6eb6ee00a0cda7e8c9b'/>
<id>urn:sha1:a9e462d952ca1e0367e9e6eb6ee00a0cda7e8c9b</id>
<content type='text'>
</content>
</entry>
<entry>
<title>osc: kitty notifications: cleanup and update to latest version of spec</title>
<updated>2024-08-02T06:07:13Z</updated>
<author>
<name>Daniel Eklöf</name>
<email>daniel@ekloef.se</email>
</author>
<published>2024-08-02T06:07:13Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=ea2f0e7c3f29f2ba83ad71e36c6751bb571f826f'/>
<id>urn:sha1:ea2f0e7c3f29f2ba83ad71e36c6751bb571f826f</id>
<content type='text'>
* Don't store a list of unfinished notifications. Use a single one. If
  the notification ID of the 'current' notification doesn't match the
  previous, unfinished one, the 'current' notification replaces the
  previous one, instead of updating it.

* Update xstrjoin() to take an optional delimiter (for example ','),
  and use that when joining categories and 'alive IDs'.

* Rename ${action-arg} to ${action-argument}

* Update handling of the 'n' parameter (symbolic icon name); the spec
  allows it to be used multiple times, and the terminal is supposed to
  pick the first one it can resolve. Foot can't resolve icons at all,
  neither can 'notify-send' or 'fyi' (which is what foot typically
  executes to display a notification); it's the notification daemon that
  resolves icons.

  The spec _could_ be interpreted to mean the terminal should lookup
  .desktop files, and use the value of the 'Icon' key from the first
  matching .desktop files. But foot doesn't read .desktop files, and I
  don't intend to implement XDG directory scanning and parsing of
  .desktop files just to figure out which icon to use.

  Instead, use a simple heuristics; use the *shortest* symbolic
  names. The idea is pretty simple: plain icon names are typically
  shorter than .desktop file IDs.
</content>
</entry>
<entry>
<title>main/config: replace some uses of xasprintf() with xstrjoin()</title>
<updated>2024-03-16T20:17:53Z</updated>
<author>
<name>Craig Barnes</name>
<email>craigbarnes@protonmail.com</email>
</author>
<published>2024-03-16T20:17:53Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=853be450bb95cb7b022f6dad4263e4a92bf18e4b'/>
<id>urn:sha1:853be450bb95cb7b022f6dad4263e4a92bf18e4b</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Add support for opening an existing PTY</title>
<updated>2024-03-14T06:31:03Z</updated>
<author>
<name>Alyssa Ross</name>
<email>hi@alyssa.is</email>
</author>
<published>2021-12-10T17:40:59Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=86894a1cd29f8fb3e5a8487b4ce2d2c1b4cf57a9'/>
<id>urn:sha1:86894a1cd29f8fb3e5a8487b4ce2d2c1b4cf57a9</id>
<content type='text'>
Virtual machine monitor programs (e.g. QEMU, Cloud Hypervisor) expose
guest consoles as PTYs.  With this patch, foot can access these guest
consoles.

Usually, the program used for accessing these PTYs is screen, but
screen is barely developed, doesn't support resizing, and has a bunch
of other unrelated stuff going on.  It would be nice to have a
terminal emulator that properly supported opening an existing PTY.
The VMM controls the master end of the PTY, so to the other end (in
this case foot), it just behaves like any application running in a
directly-opened PTY, and all that's needed is to change foot's code to
support opening an existing PTY rather than creating one.

Co-authored-by: tanto &lt;tanto@ccc.ac&gt;
</content>
</entry>
<entry>
<title>Don't use fancy Unicode quotes, stick to ASCII</title>
<updated>2024-02-06T11:36:45Z</updated>
<author>
<name>Daniel Eklöf</name>
<email>daniel@ekloef.se</email>
</author>
<published>2024-02-06T11:36:45Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=7999975016a57cc0a2c2e20bc55f29de32df7044'/>
<id>urn:sha1:7999975016a57cc0a2c2e20bc55f29de32df7044</id>
<content type='text'>
</content>
</entry>
<entry>
<title>util: add streq() function and use in place of strcmp(...) == 0</title>
<updated>2024-02-05T11:09:52Z</updated>
<author>
<name>Craig Barnes</name>
<email>craigbarnes@protonmail.com</email>
</author>
<published>2024-01-24T23:17:28Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=e0f3703ae6c4084f9275cfc78d87e5604cc27a10'/>
<id>urn:sha1:e0f3703ae6c4084f9275cfc78d87e5604cc27a10</id>
<content type='text'>
</content>
</entry>
<entry>
<title>main: correct short option case in help output for disabling syslog</title>
<updated>2023-10-27T14:20:23Z</updated>
<author>
<name>Jan Palus</name>
<email>jpalus@fastmail.com</email>
</author>
<published>2023-10-26T20:20:38Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=ee02e7b07d3814e7e20def899599683f19a2ec9d'/>
<id>urn:sha1:ee02e7b07d3814e7e20def899599683f19a2ec9d</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Codespell fixes</title>
<updated>2023-10-03T12:11:55Z</updated>
<author>
<name>Daniel Eklöf</name>
<email>daniel@ekloef.se</email>
</author>
<published>2023-10-03T12:11:55Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=58d967b2f31ebe1f16bd0915f28ec93919d3fddc'/>
<id>urn:sha1:58d967b2f31ebe1f16bd0915f28ec93919d3fddc</id>
<content type='text'>
</content>
</entry>
<entry>
<title>wayland: cursor-shape-v1 is now always available</title>
<updated>2023-08-07T14:53:19Z</updated>
<author>
<name>Daniel Eklöf</name>
<email>daniel@ekloef.se</email>
</author>
<published>2023-07-31T14:33:16Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=698c5b54f32c885304d5e2ff55580ce7f52b5da7'/>
<id>urn:sha1:698c5b54f32c885304d5e2ff55580ce7f52b5da7</id>
<content type='text'>
Since we're requiring wayland-protocols &gt;= 1.32
</content>
</entry>
<entry>
<title>wayland: fractional-scale-v1 is now always available</title>
<updated>2023-08-07T14:53:19Z</updated>
<author>
<name>Daniel Eklöf</name>
<email>daniel@ekloef.se</email>
</author>
<published>2023-07-31T14:32:53Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=7eee415b7573f5a20852c6e29001945149e920a2'/>
<id>urn:sha1:7eee415b7573f5a20852c6e29001945149e920a2</id>
<content type='text'>
Since we're requiring wayland-protocols &gt;= 1.32
</content>
</entry>
<entry>
<title>main: “title%s” -&gt; “title=%s”</title>
<updated>2023-08-05T05:23:11Z</updated>
<author>
<name>Daniel Eklöf</name>
<email>daniel@ekloef.se</email>
</author>
<published>2023-08-05T05:23:11Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=be22736f230f4aa3d2052e0e7a918365c40ac4b1'/>
<id>urn:sha1:be22736f230f4aa3d2052e0e7a918365c40ac4b1</id>
<content type='text'>
Fix regression of --title,-T option. This broken when command line
parsing was switched to using overrides, in
0b4f1b4af20cea0afae39a2c1c4e42c22962dcde.

Closes #1457
</content>
</entry>
<entry>
<title>main: translate command line options to overrides</title>
<updated>2023-07-31T14:26:17Z</updated>
<author>
<name>Daniel Eklöf</name>
<email>daniel@ekloef.se</email>
</author>
<published>2023-07-31T14:26:17Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=0b4f1b4af20cea0afae39a2c1c4e42c22962dcde'/>
<id>urn:sha1:0b4f1b4af20cea0afae39a2c1c4e42c22962dcde</id>
<content type='text'>
Instead of special casing configuration affecting command line
options (like --font, --fullscreen, --maximized etc), translate them
to overrides, and let the configuration system handle them.

This also fixes an issue where -f,--font did not set csd.font, if
csd.font were otherwise unset.
</content>
</entry>
<entry>
<title>main/client: add a version feature flag for cursor-shape</title>
<updated>2023-07-03T12:36:33Z</updated>
<author>
<name>Daniel Eklöf</name>
<email>daniel@ekloef.se</email>
</author>
<published>2023-06-29T14:12:54Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=a361d7917b311cad2def1ef42e740670cbddd7b1'/>
<id>urn:sha1:a361d7917b311cad2def1ef42e740670cbddd7b1</id>
<content type='text'>
</content>
</entry>
<entry>
<title>feature: add a feature flag (for --version) for fractional scaling</title>
<updated>2023-06-29T13:38:24Z</updated>
<author>
<name>Daniel Eklöf</name>
<email>daniel@ekloef.se</email>
</author>
<published>2023-06-26T16:00:01Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=9db92bd942706d6d0ca0250d6011c49ec88f4051'/>
<id>urn:sha1:9db92bd942706d6d0ca0250d6011c49ec88f4051</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Fix non UTF-8 locale complaint</title>
<updated>2023-06-01T10:12:49Z</updated>
<author>
<name>Phillip Susi</name>
<email>phill@thesusis.net</email>
</author>
<published>2023-05-30T19:49:01Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=8859e134efa422d50e53c0bbb0e83d07ddf66091'/>
<id>urn:sha1:8859e134efa422d50e53c0bbb0e83d07ddf66091</id>
<content type='text'>
If the locale isn't UTF-8, foot tries to fall back to C.UTF-8 and
prints a warning.  The warning was garbled because the name of the
original locale is no longer valid after calling setlocale() a
second time.  Use strdup to stash the original string.

Closes #1362
</content>
</entry>
<entry>
<title>.desktop: remove StartupWMClass from server, use distinct StartupWMClass for foot and footclient</title>
<updated>2023-05-22T16:57:54Z</updated>
<author>
<name>jdevdevdev</name>
<email>jdevdevdev@noreply.codeberg.org</email>
</author>
<published>2023-05-01T15:53:01Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=134b54dfe0e4d142ac4b6b7fe25e84485ba63387'/>
<id>urn:sha1:134b54dfe0e4d142ac4b6b7fe25e84485ba63387</id>
<content type='text'>
For this to work, the default app-id of footclient has been changed
from ‘foot’ to ‘footclient’.

By using distinct StartupWMClasses, the compositor can connect a
running foot/footclient instance to the correct .desktop-file. This
ensures the correct icon is being used in e.g. docks, and that actions
like “open another window” works correctly.

Note that the user can override the app-id, either by setting app-id
in foot.ini, or with the -a,--app-id command line option.

Closes #1355
</content>
</entry>
<entry>
<title>main: Graceful fallback if user has configured an invalid locale</title>
<updated>2022-12-16T07:38:37Z</updated>
<author>
<name>Joakim Nohlgård</name>
<email>joakim@nohlgard.se</email>
</author>
<published>2022-12-16T07:38:37Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=7bb5c80d04be5e5297fb6259e487fe0105e85935'/>
<id>urn:sha1:7bb5c80d04be5e5297fb6259e487fe0105e85935</id>
<content type='text'>
</content>
</entry>
<entry>
<title>change default log level to WARNING</title>
<updated>2022-11-22T15:22:22Z</updated>
<author>
<name>Antoine Beaupré</name>
<email>anarcat@debian.org</email>
</author>
<published>2022-11-18T16:07:16Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=b80c7f75fea0c1a69471d1f67aa97b584d3e48b2'/>
<id>urn:sha1:b80c7f75fea0c1a69471d1f67aa97b584d3e48b2</id>
<content type='text'>
The default foot output looks like this, in Debian testing "bookworm"
at the time of writing:

    anarcat@angela:pubpaste$ foot true
    info: main.c:421: version: 1.13.1 +pgo +ime +graphemes -assertions
    info: main.c:428: arch: Linux x86_64/64-bit
    info: main.c:440: locale: fr_CA.UTF-8
    info: config.c:3003: loading configuration from /home/anarcat/.config/foot/foot.ini
    info: fcft.c:338: fcft: 3.1.5 +graphemes -runs +svg(nanosvg) -assertions
    info: fcft.c:377: fontconfig: 2.13.1, freetype: 2.12.1, harfbuzz: 5.2.0
    info: fcft.c:838: /home/anarcat/.local/share/fonts/Fira-4.202/otf/FiraMono-Regular.otf: size=8.00pt/8px, dpi=75.00
    info: wayland.c:1353: eDP-1: 2256x1504+0x0@60Hz 0x095F 13.32" scale=2 PPI=205x214 (physical) PPI=136x143 (logical), DPI=271.31
    info: wayland.c:1509: requesting SSD decorations
    info: fcft.c:838: /home/anarcat/.local/share/fonts/Fira-4.202/otf/FiraMono-Bold.otf: size=24.00pt/32px, dpi=96.00
    info: fcft.c:838: /home/anarcat/.local/share/fonts/Fira-4.202/otf/FiraMono-Regular.otf: size=24.00pt/32px, dpi=96.00
    info: fcft.c:838: /home/anarcat/.local/share/fonts/Fira-4.202/otf/FiraMono-Bold.otf: size=24.00pt/32px, dpi=96.00
    info: fcft.c:838: /home/anarcat/.local/share/fonts/Fira-4.202/otf/FiraMono-Regular.otf: size=24.00pt/32px, dpi=96.00
    info: terminal.c:700: cell width=19, height=39
    info: terminal.c:588: using 16 rendering threads
    info: wayland.c:859: using SSD decorations
    info: main.c:680: goodbye
    anarcat@angela:pubpaste$

That's 17 lines of output that are *mostly* useless for most use
cases. I might understand having this output during the project's
startup, when it's helpful for diagnostics, but now Foot just mostly
works everywhere, and I've never had a use for any of that stuff in
the (arguably short) time I've been using Foot so far.

And if I do, there's the `--log-level` commandline option to tweak
this. At first, I looked at tweaking the log level through the config
file. But as explained in this issue:

https://codeberg.org/dnkl/foot/issues/1142

... there's a chicken and egg problem there that makes it hard to
implement and possibly confusing for users as well.

There's also the possibility for users to change the shortcut with
which they start foot, for example a `.desktop` file so that menu
systems that support those start foot properly. But that only works in
that environment, and not through the so many things that will just
call `foot` and hope it will do the right thing.

In my case, I have `foot` hardcoded in a lot of places now, between
sway and waybar, and this is only going to grow. Others have suggested
adding the flag to a $TERMINAL global variable, but that won't help
.desktop users.

So, instead of playing whack-a-mole with the log levels, just make it
so that, by default, foot is silent. This is actually one of the
[basics of UNIX philosophy][1]:

&gt; Rule of Silence: When a program has nothing surprising to say, it
&gt; should say nothing.

And yes, I am aware I am severely violating that principle by writing
a way too long commit log for a one-line patch, but there you go, I
figured it was good to document the why of this properly.

[1]: https://web.archive.org/web/20031102053334/http://www.faqs.org/docs/artu/ch01s06.html
</content>
</entry>
<entry>
<title>main/client: use $PWD for cwd, when $PWD is valid</title>
<updated>2022-10-02T18:11:16Z</updated>
<author>
<name>Daniel Eklöf</name>
<email>daniel@ekloef.se</email>
</author>
<published>2022-09-26T17:09:33Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=90ce4f3008a7c7f01dcdee4504b9c512c96a41d1'/>
<id>urn:sha1:90ce4f3008a7c7f01dcdee4504b9c512c96a41d1</id>
<content type='text'>
If $PWD is set, and its resolved path matches the *actual* working
directory, use $PWD for cwd when instantiating the terminal.

This makes a difference when $PWD refers to a symlink; before this
patch, we’d instantiate the terminal in the *resolved* path. Now it’ll
use the symlink instead.
</content>
</entry>
<entry>
<title>main: minor rewording of non-UTF8 locale warnings and errors</title>
<updated>2022-05-14T07:14:57Z</updated>
<author>
<name>Daniel Eklöf</name>
<email>daniel@ekloef.se</email>
</author>
<published>2022-05-14T07:14:57Z</published>
<link rel='alternate' type='text/html' href='https://git.0x0f.dev/mirrors/foot.git/commit/?id=7e8b5f961037e15f1ccb76c6058616a03b317c82'/>
<id>urn:sha1:7e8b5f961037e15f1ccb76c6058616a03b317c82</id>
<content type='text'>
</content>
</entry>
</feed>
