--- - name: Install os-specific packages include_tasks: "{{ ansible_os_family | lower }}.yml" - name: Clone dotfiles ansible.builtin.git: repo: "{{ user.config.giturl }}" dest: "/home/{{ user.username }}/.dotfiles" become: true become_user: "{{ user.username }}" - name: stow configs ansible.builtin.command: cmd: stow {{ item }} chdir: "/home/{{ user.username }}/.dotfiles" with_items: "{{ user.config.stowing }}" - name: init neovim import_tasks: neovim.yml when: '"nvim" in user.config.stowing' - name: init vim import_tasks: vim.yml when: '"vim" in user.config.stowing' - name: init sway import_tasks: sway.yml when: '"sway" in user.config.stowing'