From d22796053cd4fe174501cc841386787eb705db8b Mon Sep 17 00:00:00 2001 From: Paul Lecuq Date: Mon, 26 Dec 2022 10:13:15 +0100 Subject: [PATCH] updated tmux state --- states/tmux/config.sls | 11 +++++++++++ states/tmux/init.sls | 17 +++-------------- states/tmux/install.sls | 5 +++++ 3 files changed, 19 insertions(+), 14 deletions(-) create mode 100644 states/tmux/config.sls create mode 100644 states/tmux/install.sls diff --git a/states/tmux/config.sls b/states/tmux/config.sls new file mode 100644 index 0000000..47686dc --- /dev/null +++ b/states/tmux/config.sls @@ -0,0 +1,11 @@ +--- +{%- from "tmux/map.jinja" import tmux with context %} +tmux-config: + file.managed: + - name: /etc/tmux.conf + - source: salt://tmux/tmux.conf.j2 + - user: root + - group: root + - template: jinja + - require: + - pkg: tmux-pkg diff --git a/states/tmux/init.sls b/states/tmux/init.sls index e2e3c83..d507940 100644 --- a/states/tmux/init.sls +++ b/states/tmux/init.sls @@ -1,15 +1,4 @@ --- -{%- from "tmux/map.jinja" import tmux with context %} -tmux-pkg: - pkg.latest: - - name: tmux - -tmux-config: - file.managed: - - name: /etc/tmux.conf - - source: salt://tmux/tmux.conf.j2 - - user: root - - group: root - - template: jinja - - require: - - pkg: tmux-pkg \ No newline at end of file +include: + - .install + - .config diff --git a/states/tmux/install.sls b/states/tmux/install.sls new file mode 100644 index 0000000..0862e6d --- /dev/null +++ b/states/tmux/install.sls @@ -0,0 +1,5 @@ +--- +{%- from "tmux/map.jinja" import tmux with context %} +tmux-pkg: + pkg.installed: + - name: tmux