I'm running Emacs in terminal with -nw option over i3 in Ubuntu 22.04. I use emacs server to start automatically in background and create more emacs-clients from more parent gnome-shell terminals. It works fine, but over i3 I need rofi program that reads only terminal title. Rofi program doesn't see child process started from terminal such as Emacs frames. I need to change automatically parent gnome-shell title after the current buffer of its child Emacs frame. Unfortunately, the xterm-title package is no longer maintained. I tried something with
(suspend-emacs "set-title (buffer-name) && fg) but it didn't work. Sometime, suspend-emacs asks to close the other opened emacs-clients. Sometime if it changes the gnome-shell title, when it returns in Emacs, the title remain unchanged. Has somebody got a great idea to solve this awkward situation? I know there is an i3 Emacs mode that change the behavior of i3 when on the current i3 window run Emacs frame, but I want to avoid a mess. Combining i3 with Emacs is a real mess, and for my clearness I want to use i3 totally independent from Emacs frame. For Vim buffer was simple to solve, I added some lines in .vimrc file and it changes its parent gnome-shell title perfectly.