mirror of
https://github.com/dustinkirkland/byobu
synced 2025-08-22 14:24:39 -07:00
search and use a shared dir when possible
This commit is contained in:
parent
14c14778f2
commit
493f8445c8
2 changed files with 7 additions and 8 deletions
1
debian/changelog
vendored
1
debian/changelog
vendored
|
@ -18,6 +18,7 @@ byobu (4.43) unreleased; urgency=low
|
||||||
- ensure launcher command removed from each file before installing
|
- ensure launcher command removed from each file before installing
|
||||||
* usr/lib/byobu/.dirs:
|
* usr/lib/byobu/.dirs:
|
||||||
- use /dev/shm for cache, LP: #872551
|
- use /dev/shm for cache, LP: #872551
|
||||||
|
- search and use a shared dir when possible
|
||||||
|
|
||||||
[ Daniel Hahler ]
|
[ Daniel Hahler ]
|
||||||
* usr/bin/byobu, usr/bin/byobu-launcher-install, usr/bin/byobu-
|
* usr/bin/byobu, usr/bin/byobu-launcher-install, usr/bin/byobu-
|
||||||
|
|
|
@ -40,14 +40,12 @@ fi
|
||||||
# Create and export the runtime cache directory
|
# Create and export the runtime cache directory
|
||||||
if [ -w /dev/shm ]; then
|
if [ -w /dev/shm ]; then
|
||||||
# Use shm for performance, if possible
|
# Use shm for performance, if possible
|
||||||
if [ -z "$BYOBU_RUN_DIR" ]; then
|
for i in /dev/shm/$PKG-$USER-*; do
|
||||||
for i in /dev/shm/$PKG-$USER-*; do
|
if [ -d "$i" ] && [ -O "$i" ]; then
|
||||||
if [ -d "$i" ] && [ -O "$i" ]; then
|
export BYOBU_RUN_DIR="$i"
|
||||||
export BYOBU_RUN_DIR="$i"
|
break
|
||||||
break
|
fi
|
||||||
fi
|
done
|
||||||
done
|
|
||||||
fi
|
|
||||||
# Still empty, make a new one
|
# Still empty, make a new one
|
||||||
if [ ! -d "$BYOBU_RUN_DIR" ] || [ ! -O "$BYOBU_RUN_DIR" ]; then
|
if [ ! -d "$BYOBU_RUN_DIR" ] || [ ! -O "$BYOBU_RUN_DIR" ]; then
|
||||||
export BYOBU_RUN_DIR=$(mktemp -d /dev/shm/$PKG-$USER-XXXXXXXX)
|
export BYOBU_RUN_DIR=$(mktemp -d /dev/shm/$PKG-$USER-XXXXXXXX)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue