From 9db923856c0de04aa00ce0906f253a283854be85 Mon Sep 17 00:00:00 2001 From: Oliver Davies Date: Tue, 31 May 2022 01:22:36 +0100 Subject: [PATCH] feat(role): add tmuxinator Install tmuxinator via gem and create its configuration directory and files. --- group_vars/all | 1 + roles/tmuxinator/tasks/main.yml | 21 +++++++++++++++++++++ 2 files changed, 22 insertions(+) create mode 100644 roles/tmuxinator/tasks/main.yml diff --git a/group_vars/all b/group_vars/all index eb08167..3c25042 100644 --- a/group_vars/all +++ b/group_vars/all @@ -23,5 +23,6 @@ default_roles: - tldr - tree - tmux + - tmuxinator - zsh - zsh-antigen diff --git a/roles/tmuxinator/tasks/main.yml b/roles/tmuxinator/tasks/main.yml new file mode 100644 index 0000000..3cd7243 --- /dev/null +++ b/roles/tmuxinator/tasks/main.yml @@ -0,0 +1,21 @@ +--- +- name: Install + community.general.gem: + bindir: "{{ ansible_user_dir }}/.local/bin" + name: tmuxinator + state: latest + +- name: Configuration + ansible.builtin.file: + path: "{{ ansible_user_dir }}/.config/tmuxinator" + state: directory + +- name: Copy configuration files + copy: + content: "{{ tmuxinator_config_file.value }}" + dest: "{{ ansible_user_dir }}/.config/tmuxinator/{{ tmuxinator_config_file.key }}.yml" + mode: 0644 + loop_control: + loop_var: tmuxinator_config_file + no_log: true + with_items: "{{ tmuxinator_config | default({}) | dict2items }}"