mirror of
https://github.com/dustinkirkland/byobu
synced 2025-08-22 06:23:19 -07:00
* byobu-status, debian/rules: migrate existing screen-profiles config
dir smoothly by linking the old screen-profiles-status script to the new byobu-status, and add a migrate function to that script Signed-off-by: Dustin Kirkland <kirkland@canonical.com>
This commit is contained in:
parent
a5fe5a84df
commit
882b1e652f
3 changed files with 24 additions and 1 deletions
19
byobu-status
19
byobu-status
|
@ -28,6 +28,25 @@
|
|||
|
||||
PKG="byobu"
|
||||
|
||||
migrate() {
|
||||
OLDPKG="screen-profiles"
|
||||
# Rename the config dir
|
||||
mv "$HOME/.$OLDPKG" "$HOME/.$PKG"
|
||||
ln -s "$HOME/.$PKG" "$HOME/.$OLDPKG"
|
||||
# Replace all instances of the old package name with the new
|
||||
find "$HOME/.$PKG" -type f | xargs sed -i "s/$OLDPKG/$PKG/g"
|
||||
# Fix the chosen profile symlink
|
||||
if [ -h "$HOME/.$PKG/profile" ]; then
|
||||
# Determine the chosen profile color
|
||||
profile=`stat "$HOME/.$PKG/profile" | head -n1 | sed "s:^.*[/-]::" | sed "s:'$::"`
|
||||
# Try to set that color, if it exists, otherwise default to light
|
||||
select-screen-profile -s "$profile" || select-screen-profile -s "light"
|
||||
fi
|
||||
}
|
||||
|
||||
# If the old config dir exists, but the new one doesn't, provide a migration mechanism
|
||||
[ -d "$HOME/.$OLDPKG" -a ! -d "$HOME/.$PKG" ] && migrate
|
||||
|
||||
if [ -d "$HOME/.$PKG/bin" ]; then
|
||||
DIR="$HOME/.$PKG/bin"
|
||||
elif [ -d "/usr/lib/$PKG" ]; then
|
||||
|
|
5
debian/changelog
vendored
5
debian/changelog
vendored
|
@ -1,6 +1,9 @@
|
|||
byobu (2.1) unreleased; urgency=low
|
||||
|
||||
* byobu-export: touch an empty .byobu/profile, silence error message
|
||||
* byobu-status, debian/rules: migrate existing screen-profiles config
|
||||
dir smoothly by linking the old screen-profiles-status script to the
|
||||
new byobu-status, and add a migrate function to that script
|
||||
|
||||
Tranform byobu-status --detail to use vim's folding feature
|
||||
* byobu-status: output text compatible with vim's folding feature
|
||||
|
@ -23,7 +26,7 @@ byobu (2.1) unreleased; urgency=low
|
|||
* bin/users: grep out the grep statement in the ps
|
||||
* bin/whoami: print /etc/passwd info on --detail
|
||||
|
||||
-- Dustin Kirkland <kirkland@ubuntu.com> Wed, 06 May 2009 21:01:56 -0500
|
||||
-- Dustin Kirkland <kirkland@ubuntu.com> Thu, 07 May 2009 00:11:51 -0500
|
||||
|
||||
byobu (2.0-0ubuntu1) karmic; urgency=low
|
||||
|
||||
|
|
1
debian/rules
vendored
1
debian/rules
vendored
|
@ -49,6 +49,7 @@ install: build install-po
|
|||
dh_testroot
|
||||
dh_clean -k
|
||||
dh_link usr/bin/byobu usr/bin/screen
|
||||
dh_link usr/bin/byobu-status usr/bin/screen-profiles-status
|
||||
dh_install -X.bzr
|
||||
|
||||
# Everything else is handled by dh_install
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue