name new byobu sessions, only select byobu sessions

Bug #599334 reported by Dustin Kirkland 
12
This bug affects 2 people
Affects Status Importance Assigned to Milestone
byobu
Fix Released
Wishlist
Unassigned
byobu (Ubuntu)
Fix Released
Wishlist
Unassigned

Bug Description

I'm currently using byobu on launch on my home Atom system. I want to set up a separate screen session using crontab @reboot for running irssi, but while this works fine and connects me to IRC on reboot, when I try login to the system's CLI, byobu just reconnects me to the screen/IRC session.

Would it be easy/more sensible to make byobu only work with its own named sessions (byobu, byobu_1, byobu_2 etc) so that I can have separate "long-lived" sessions established automatically on a reboot, as opposed to byobu which will only launch the first time I login to the CLI after a reboot. This could also avoid the prompt asking me which screen session I want to connect to when I SSH in with both screen/IRC and byobu running.

Alternatively, can I run byobu on @reboot so that byobu is launched straightaway and make irssi a subwindow of byobu? I'd prefer to keep the separate screen session however as I like to have the CLI and IRC open in separate windows and this wouldn't be possible with IRC running in byobu...

Revision history for this message
Dustin Kirkland  (kirkland) wrote :

Thanks for the question. I have converted this to a bug report.

I think it would be a good idea to name byobu sessions accordingly, and only select against byobu-named sessions. This would allow byobu to run beside screen a little cleaner. Committing a fix to this effect now.

Changed in byobu:
status: New → In Progress
importance: Undecided → Wishlist
status: In Progress → Fix Committed
Revision history for this message
Dustin Kirkland  (kirkland) wrote :

As for the @reboot cronjob, this is working just fine for me in my user's crontab:

@reboot byobu -d -m top

When I rebooted, and logged in (with byobu set to auto launch), I launched directly into a byobu session running 'top'.

Dustin

Revision history for this message
Gavin Chappell (g-a-c) wrote :

Now how's that for service, hadn't even had chance to go home and open some of the byobu-* shell scripts and see if there's any changes I could make :)

As I said, I'd prefer it if I could run irssi outsibe of byobu, byobu is a nice way of managing windows now I've figured out how it works but it's preferable to be able to keep IRC visible as well as the command line which wouldn't be possible with irssi in a byobu window. How do I pick up these changes on a 10.04 system? Is there a byobu PPA where I'll be able to get this patched version once it's released?

Revision history for this message
Dustin Kirkland  (kirkland) wrote : Re: [Bug 599334] Re: name new byobu sessions, only select byobu sessions

I aim to please ;-)

I keep ppa:byobu/ppa up to date for Lucid (and other releases) at each
byobu release. I'll drop a new version today or tomorrow with these
fixes. You're welcome to track that PPA (many people do). It's
pretty stable.

Dustin

Revision history for this message
Gavin Chappell (g-a-c) wrote :

Thanks, have added that PPA and picked up one update already although I assume it's not the fix related to this as it's not "Fix Released" yet.

Revision history for this message
Dustin Kirkland  (kirkland) wrote :

Right, let me solidify this release just a bit....

Changed in byobu:
status: Fix Committed → Fix Released
Revision history for this message
Gavin Chappell (g-a-c) wrote :

Package: byobu
New: yes
State: installed
Automatically installed: yes
Version: 3.8-0ubuntu1~ppa4

Hi, I have the version posted above on my (previously Lucid, now Maverick) system and this behaviour seems to been reverted? When I try and connect to this system, I get the old menu where I'm asked to choose between a byobu session and my irssi session. Was this intentional? :)

Revision history for this message
Dustin Kirkland  (kirkland) wrote :

Erg, yeah, it was sort of intentional, trying to fix Bug #630673.

Seems I can't make both camps happy.

Some people want to see all sessions (in particular, the ones that they name). Others don't want to see some sessions.

Revision history for this message
Dustin Kirkland  (kirkland) wrote :

What if byobu supported "hiding" of sessions by naming them in a particular way? Perhaps with a leading "." period.

You could, for instance:

screen -S .irssi

And I could have byobu filter these out, and document it accordingly in the manpage.

Would that suffice?

Revision history for this message
Gavin Chappell (g-a-c) wrote :

I don't see why not. The main problem which caused me to post this bug hasn't reappeared (way back when I started this, if I had my irssi session open with screen but no byobu session open, then byobu would attach me to irssi when I SSHed in) so if this change was intentional then I can live with it, the current behaviour isn't stopping me from getting a command line like the original problem was.

If it's easy to support hiding of sessions (leading period seems sensible to me as it's a long-standing Unix/Linux convention) then I'd be interested to see if that manages to please both types of users, however that depends on how much you feel like adding it. Having read the other bug report I can see why in certain circumstances this behaviour might be preferable and as I said, it's not a total regression for me as it's not stopping me getting to a command line as it was originally.

Revision history for this message
Dustin Kirkland  (kirkland) wrote :

I'll reopen this bug and support "hiding" sessions from byobu by prepending a "." on the name. Thanks!

Changed in byobu:
status: Fix Released → Triaged
Revision history for this message
Dustin Kirkland  (kirkland) wrote :

Fix committed. Will be in 3.20.

Changed in byobu:
status: Triaged → Fix Committed
Changed in byobu (Ubuntu):
status: New → Fix Committed
importance: Undecided → Wishlist
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package byobu - 3.20-0ubuntu1

---------------
byobu (3.20-0ubuntu1) natty; urgency=low

  * usr/lib/byobu/network: drop unnecessary unit=kbps
  * usr/bin/byobu: allow for -xS or the like, LP: #684926
  * usr/bin/byobu-select-session, usr/share/man/man1/byobu.1,
    usr/share/man/man1/byobu-select-session.1: support "hiding"
    sessions, by prepending a "." to the session name, LP: #599334
  * usr/share/man/man1/byobu-launcher.1: update documentation
  * usr/bin/byobu-launcher-install, usr/share/man/man1/byobu-launcher-
    install.1, usr/share/man/man1/byobu-launcher-uninstall.1,
    usr/share/man/man1/Makefile.am:
    - add an option for -n|--no-logout to byobu-launcher-install,
      document changes in new manpages, LP: #604931
  * usr/lib/byobu/cpu_temp: find the temp monitor, LP: #676080
  * usr/lib/byobu/battery, usr/share/man/man1/byobu.1: allow for
    overriding detected BATTERY, LP: #693560
  * usr/lib/byobu/cpu_temp: test that file exists, is readable, and has
    size > 0, LP: #696071
 -- Dustin Kirkland <email address hidden> Tue, 28 Dec 2010 00:05:13 -0600

Changed in byobu (Ubuntu):
status: Fix Committed → Fix Released
Changed in byobu:
status: Fix Committed → Fix Released
Revision history for this message
Gavin Chappell (g-a-c) wrote :

I just tried this version of byobu on a system and it seems to work fine, my .irssi screen session (started @reboot) is ignored by byobu and I get dropped straight into the "normal" byobu shell with my normal windows, .irssi is ignored. Thanks Dustin!

Revision history for this message
Dustin Kirkland  (kirkland) wrote : Re: [Bug 599334] Re: name new byobu sessions, only select byobu sessions

Great! Thanks for sticking with me on this one, Gavin ;-)

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Related questions

Remote bug watches

Bug watches keep track of this bug in other bug trackers.