mirror of
https://github.com/dustinkirkland/byobu
synced 2025-08-22 22:34:23 -07:00
* etc/byobu/socketdir, usr/bin/byobu-config, usr/bin/byobu-janitor,
usr/bin/byobu-select-profile: increase portability to other distros, create socketdir conffile and SOCKETDIR variable for users who don't use /var/run/screen as the socket directory, LP: #535378 * usr/bin/byobu-config: change a sample reference from "bash" to "shell" again for portability, LP: #xxxxxx
This commit is contained in:
parent
ca95d8bfbe
commit
924206534f
5 changed files with 30 additions and 6 deletions
8
debian/changelog
vendored
8
debian/changelog
vendored
|
@ -1,6 +1,12 @@
|
|||
byobu (2.63) unreleased; urgency=low
|
||||
|
||||
* UNRELEASED
|
||||
* etc/byobu/socketdir, usr/bin/byobu-config, usr/bin/byobu-janitor,
|
||||
usr/bin/byobu-select-profile: increase portability to other distros,
|
||||
create socketdir conffile and SOCKETDIR variable for users who don't
|
||||
use /var/run/screen as the socket directory, LP: #535378
|
||||
* usr/bin/byobu-config: change a sample reference from "bash" to "shell"
|
||||
again for portability, LP: #xxxxxx
|
||||
|
||||
|
||||
-- Dustin Kirkland <kirkland@ubuntu.com> Tue, 09 Mar 2010 14:53:10 -0600
|
||||
|
||||
|
|
10
etc/byobu/socketdir
Normal file
10
etc/byobu/socketdir
Normal file
|
@ -0,0 +1,10 @@
|
|||
# Set the location of the socket directory that byobu will use.
|
||||
# On Debian/Ubuntu systems, this is in /var/run/screen, but on
|
||||
# other distros, it might be elsewhere, such as /tmp
|
||||
#
|
||||
# This file will be sourced by both shell scripts and python code,
|
||||
# so please ensure that:
|
||||
# * the variable name is SOCKETDIR
|
||||
# * there is no space around the "="
|
||||
# * and that the path value is quoted
|
||||
SOCKETDIR="/var/run/screen"
|
|
@ -37,7 +37,13 @@ if not os.path.exists(DOC):
|
|||
DOC = "%s/.%s/%s" % (HOME, PKG, DOC)
|
||||
DEF_ESC="A"
|
||||
RELOAD = "If you are using the default set of keybindings, press\n<F5> or <ctrl-a-R> to activate these changes.\n\nOtherwise, exit this screen session and start a new one."
|
||||
RELOAD_FLAG="/var/run/screen/S-"+USER+"/"+PKG+".reload-required"
|
||||
SOCKETDIR="/var/run/screen"
|
||||
if os.path.exists("/etc/%s/socketdir" % PKG):
|
||||
try:
|
||||
execfile(i)
|
||||
except:
|
||||
SOCKETDIR="/var/run/screen"
|
||||
RELOAD_FLAG="%s/S-%s/%s.reload-required" % (SOCKETDIR, USER, PKG)
|
||||
RELOAD_CMD="screen -X at 0 source $HOME/."+PKG+"/profile"
|
||||
ESC = ''
|
||||
snack.hotkeys[ESC] = ord(ESC)
|
||||
|
@ -183,9 +189,9 @@ def switch_keybindings(set):
|
|||
commands.getoutput("sed -i -e 's:^source .*$:source "+SHARE+"/keybindings/"+set+":' "+HOME+"/."+PKG+"/keybindings")
|
||||
|
||||
def newwindow(screen, size):
|
||||
title=Entry(8, text="bash", returnExit=1)
|
||||
title=Entry(8, text="shell", returnExit=1)
|
||||
titlel=Label(_("Title: "))
|
||||
command=Entry(20, text="/bin/bash", returnExit=1)
|
||||
command=Entry(20, text="/bin/sh", returnExit=1)
|
||||
commandl=Label(_("Command: "))
|
||||
|
||||
rl=Label(_("Presets: "))
|
||||
|
|
|
@ -20,7 +20,8 @@
|
|||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
PKG="byobu"
|
||||
RUN="/var/run/screen/S-$USER"
|
||||
[ -r "/etc/$PKG/socketdir" ] && . "/etc/$PKG/socketdir" || SOCKETDIR="/var/run/screen"
|
||||
RUN="$SOCKETDIR/S-$USER"
|
||||
FLAG="$RUN/$PKG.reload-required"
|
||||
|
||||
# Exit immediately, if we're not forced, and there is no reload flag
|
||||
|
|
|
@ -23,6 +23,7 @@
|
|||
# ./debian/rules get-po
|
||||
|
||||
PKG="byobu"
|
||||
[ -r "/etc/$PKG/socketdir" ] && . "/etc/$PKG/socketdir" || SOCKETDIR="/var/run/screen"
|
||||
|
||||
TEXTDOMAIN="$PKG"
|
||||
|
||||
|
@ -175,7 +176,7 @@ setcolor() {
|
|||
fi
|
||||
[ "$MONOCHROME" = "1" ] || MONOCHROME=0
|
||||
printf "FOREGROUND=$FOREGROUND\nBACKGROUND=$BACKGROUND\nMONOCHROME=$MONOCHROME" > $FILE
|
||||
touch "/var/run/screen/S-$USER/$PKG.reload-required"
|
||||
touch "$SOCKETDIR/S-$USER/$PKG.reload-required"
|
||||
}
|
||||
|
||||
if [ $# -eq 0 ]; then
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue