mirror of
https://github.com/dustinkirkland/byobu
synced 2025-08-22 06:23:19 -07:00
* usr/bin/byobu-select-session:
- Handle `screen -ls' returning 1. (LP: #1098341)
This commit is contained in:
parent
258202d9ea
commit
2f7cbaf4ab
2 changed files with 14 additions and 2 deletions
7
debian/changelog
vendored
7
debian/changelog
vendored
|
@ -1,7 +1,12 @@
|
|||
byobu (5.26) unreleased; urgency=low
|
||||
byobu (5.26) UNRELEASED; urgency=low
|
||||
|
||||
[ Dustin Kirkland ]
|
||||
* UNRELEASED
|
||||
|
||||
[ Iain Lane ]
|
||||
* usr/bin/byobu-select-session:
|
||||
- Handle `screen -ls' returning 1. (LP: #1098341)
|
||||
|
||||
-- Dustin Kirkland <kirkland@ubuntu.com> Wed, 09 Jan 2013 15:17:43 -0600
|
||||
|
||||
byobu (5.25-0ubuntu1) raring; urgency=low
|
||||
|
|
|
@ -41,7 +41,14 @@ def get_sessions():
|
|||
sessions = []
|
||||
i = 0
|
||||
if BYOBU_BACKEND == "screen":
|
||||
output = subprocess.check_output(["screen", "-ls"])
|
||||
try:
|
||||
output = subprocess.check_output(["screen", "-ls"])
|
||||
except subprocess.CalledProcessError as cpe:
|
||||
# screen -ls seems to always return 1
|
||||
if cpe.returncode != 1:
|
||||
raise
|
||||
else:
|
||||
output = cpe.output
|
||||
output = output.decode(sys.stdout.encoding)
|
||||
if output:
|
||||
for s in output.splitlines():
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue