Skip to content

Commit

Permalink
tmux-ipk: Add tmux configuration file to tmux IPK
Browse files Browse the repository at this point in the history
* Create a directory for tmux configuration files in /usr/share/tmux/conf.d
* Add a /etc/tmux.conf file with default lock command
* Add a line to source all files in /usr/share/tmux/conf.d in /etc/tmux.conf
  * -q is to ignore errors if the directory is empty
* This allows snac mode to add a conf file to this location without modifying the main tmux.conf file

Signed-off-by: Mark Silva <[email protected]>

tmux-bbappend: Add conf.d directory
  • Loading branch information
texasaggie97 authored and chaitu236 committed Aug 23, 2024
1 parent a3fbdd4 commit b09f844
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 0 deletions.
3 changes: 3 additions & 0 deletions recipes-extended/tmux/files/tmux.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
set -g lock-command vlock
bind X lock-session
source-file -q /usr/share/tmux/conf.d/*
15 changes: 15 additions & 0 deletions recipes-extended/tmux/tmux_3.%.bbappend
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
FILESEXTRAPATHS:prepend := "${THISDIR}/files:"

SRC_URI += "\
file://tmux.conf \
"

do_install:append() {
install -d ${D}${sysconfdir}
install -m 644 ${WORKDIR}/tmux.conf ${D}${sysconfdir}/tmux.conf
install -d ${D}/usr/share/tmux/conf.d
}

FILES:${PN} += "${sysconfdir}/tmux.conf"
CONFFILES:${PN} += "${sysconfdir}/tmux.conf"
RDEPENDS:${PN}:append = " vlock"

0 comments on commit b09f844

Please sign in to comment.