diff --git a/ansible.cfg b/ansible.cfg deleted file mode 100644 index 68ac724..0000000 --- a/ansible.cfg +++ /dev/null @@ -1,4 +0,0 @@ -[defaults] -inventory = hosts -host_key_checking=False -roles = roles diff --git a/deploy.yml b/deploy.yml deleted file mode 100644 index 534146c..0000000 --- a/deploy.yml +++ /dev/null @@ -1,6 +0,0 @@ ---- -- hosts: all - roles: - - dotfiles - become: yes - become_user: root diff --git a/hosts b/hosts deleted file mode 100644 index 2302eda..0000000 --- a/hosts +++ /dev/null @@ -1 +0,0 @@ -localhost ansible_connection=local diff --git a/prepare.sh b/prepare.sh new file mode 100644 index 0000000..0be2b0c --- /dev/null +++ b/prepare.sh @@ -0,0 +1,70 @@ +#!/bin/sh + +# copying all the needed stuff in place. +DOTFILES=${HOME}/.dotfiles + +# copying zshrc file +if [[ ! -f "$HOME/.zshrc" ]]; then + # no first setup done + + # Determining operating system so we can quickly setup basic configuration + if grep -qi 'debian' /proc/version; then + # Debian + sudo apt install -y zsh-autosuggestions zsh-syntax-highlighting + ln -sf ${DOTFILES}/zsh/distro/debian.base.zsh ${DOTFILES}/zsh/distro.base.zsh + fi + if grep -qi 'ubuntu' /proc/version; then + # TODO: complete instructions for Ubuntu + ln -sf ${DOTFILES}/zsh/distro/ubuntu.base.zsh ${DOTFILES}/zsh/distro.base.zsh + fi + if grep -qi 'manjaro' /proc/version; then + # TODO: complete instructions for Manjaro + pamac install manjaro-zsh-config + ln -sf ${DOTFILES}/zsh/distro/manjaro.base.zsh ${DOTFILES}/zsh/distro.base.zsh + fi + if grep -qi 'archlinux' /proc/version; then + pacman -S zsh-autosuggestions zsh-syntax-highlighting + ln -sf ${DOTFILES}/zsh/distro/archlinux.base.zsh ${DOTFILES}/zsh/distro.base.zsh + fi + if grep -qi 'voidlinux' /proc/version; then + xbps-install -S zsh + ln -sf ${DOTFILES}/zsh/distro/void.base.zsh ${DOTFILES}/zsh/distro.base.zsh + fi + if [[ -f /etc/redhat-release ]] && grep -qi centos /etc/redhat-release; then + # TODO: installation on centos. + ln -sf ${DOTFILES}/zsh/distro/centos.base.zsh ${DOTFILES}/zsh/distro.base.zsh + fi + + cp "${DOTFILES}/zshrc" "$HOME/.zshrc" + + if [[ -f ${DOTFILES}/zsh/antibody_plugins.txt ]]; then + # Installing natively on archlinux, manjaro + if grep -i archlinux /proc/version || grep -i manjaro /proc/version; then + yay -S --no-confirm zsh-antidote + else + git clone --depth=1 https://github.com/mattmc3/antidote.git ${ZDOTDIR:-$HOME}/.antidote + fi + + mkdir -p ~/.zsh/conf.d + source /usr/share/zsh-antidote/antidote.zsh + antidote bundle < ${DOTFILES}/zsh/antibody_plugins.txt > ~/.zsh/conf.d/000_antidote.zsh +fi + +# Copying tmux configuration file and initialize plugins. +if [[ ! -f "$HOME/.tmux.conf" ]]; then + mkdir -p ${HOME}/.config/tmux/plugins + git clone https://github.com/tmux-plugins/tpm ${HOME}/.config/tmux/plugins/tpm + ln -sf "${DOTFILES}/tmux.conf" "$HOME/.config/tmux/tmux.conf" + echo "Please, open Tmux and run 'prefix I'." +fi + +# Vim - configure vundle and install plugins. +if [[ ! -f "${HOME}/.vimrc" ]]; then + ln -sf ${DOTFILES}/vimrc ${HOME}/.vimrc + ln -sf ${DOTFILES}/vim ${HOME}/.vim + # Installing vim-plug + curl -fLo ~/.vim/autoload/plug.vim --create-dirs \ + https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim + # Installing vim-plug and relative plugins + vim +PlugInstall +qall +fi diff --git a/roles/antidote/defaults/main.yml b/roles/antidote/defaults/main.yml deleted file mode 100644 index acd7660..0000000 --- a/roles/antidote/defaults/main.yml +++ /dev/null @@ -1,2 +0,0 @@ ---- -dotfdir: "{{ lookup('ansible.builtin.env', 'HOME' ) }}/.dotfiles" diff --git a/roles/antidote/tasks/configuration.yml b/roles/antidote/tasks/configuration.yml deleted file mode 100644 index 91269f3..0000000 --- a/roles/antidote/tasks/configuration.yml +++ /dev/null @@ -1,17 +0,0 @@ ---- -# Configuring zsh bundles - -- name: Assuring the conf.d folder exists - ansible.builtin.file: - dest: "{{ lookup('ansible.builtin.env', 'HOME' ) }}/.zsh/conf.d" - state: directory - owner: syntaxerrormmm - group: syntaxerrormmm - mode: '0755' - -- name: Building lazy-loading list - ansible.builtin.shell: >- - source ~/.zsh/antidote/antidote.zsh; - antidote bundle < {{ dotfdir }}/zsh/antibody_plugins.txt > ~/.zsh/conf.d/000_antidote.zsh - args: - executable: /usr/bin/zsh diff --git a/roles/antidote/tasks/installation.yml b/roles/antidote/tasks/installation.yml deleted file mode 100644 index 49c5849..0000000 --- a/roles/antidote/tasks/installation.yml +++ /dev/null @@ -1,16 +0,0 @@ ---- -# Installing antidote. - -- name: Creating destination folder - ansible.builtin.file: - dest: "{{ lookup('ansible.builtin.env', 'HOME' ) }}/.zsh/antidote" - state: directory - owner: syntaxerrormmm - group: syntaxerrormmm - mode: "0755" - -- name: Installing antidote with git - ansible.builtin.git: - repo: "https://github.com/mattmc3/antidote.git" - dest: "{{ lookup('ansible.builtin.env','HOME' ) }}/.zsh/antidote" - depth: 1 diff --git a/roles/antidote/tasks/main.yml b/roles/antidote/tasks/main.yml deleted file mode 100644 index 4f7f199..0000000 --- a/roles/antidote/tasks/main.yml +++ /dev/null @@ -1,14 +0,0 @@ ---- -# Deploying antidote - -- name: Installing antidote - ansible.builtin.import_tasks: installation.yml - tags: - - antidote - - antidote-install - -- name: Configuring antidote - ansible.builtin.import_tasks: configuration.yml - tags: - - antidote - - antidote-config diff --git a/roles/dotfiles/meta/main.yml b/roles/dotfiles/meta/main.yml deleted file mode 100644 index 874aef6..0000000 --- a/roles/dotfiles/meta/main.yml +++ /dev/null @@ -1,12 +0,0 @@ ---- -dependencies: - - git - - fzf - - pip - - rsync - - rclone - - zsh - - antidote - - tmux - - vim - - vim-plug diff --git a/roles/fzf/tasks/install/alpine.yml b/roles/fzf/tasks/install/alpine.yml deleted file mode 100644 index da5d29d..0000000 --- a/roles/fzf/tasks/install/alpine.yml +++ /dev/null @@ -1,9 +0,0 @@ ---- -# FZF on alpine - -- name: (alp) FZF installation - community.general.apk: - name: fzf - state: present - update_cache: true - become: true diff --git a/roles/fzf/tasks/install/archlinux.yml b/roles/fzf/tasks/install/archlinux.yml deleted file mode 100644 index 4400a01..0000000 --- a/roles/fzf/tasks/install/archlinux.yml +++ /dev/null @@ -1,9 +0,0 @@ ---- -# FZF on Arch - -- name: (arch) FZF install - community.general.pacman: - name: fzf - state: present - update_cache: true - become: true diff --git a/roles/fzf/tasks/install/debian.yml b/roles/fzf/tasks/install/debian.yml deleted file mode 100644 index a5a222f..0000000 --- a/roles/fzf/tasks/install/debian.yml +++ /dev/null @@ -1,9 +0,0 @@ ---- -# FZF on Debian - -- name: (deb) FZF install - ansible.builtin.apt: - name: fzf - state: present - update_cache: true - become: true diff --git a/roles/fzf/tasks/install/redhat.yml b/roles/fzf/tasks/install/redhat.yml deleted file mode 100644 index be10a09..0000000 --- a/roles/fzf/tasks/install/redhat.yml +++ /dev/null @@ -1,21 +0,0 @@ ---- -# FZF on RedHat -# reverting to installation from git repo - -- name: (rHa) FZF - Build directory - ansible.builtin.file: - dest: "{{ lookup('ansible.builtin.env', 'HOME' ) }}/.fzf" - state: directory - owner: syntaxerrormmm - group: syntaxerrormmm - mode: '0755' - -- name: (rHa) FZF - clone from git - ansible.builtin.git: - repo: https://github.com/junegunn/fzf.git - depth: 1 - dest: "{{ lookup('ansible.builtin.env', 'HOME' ) }}/.fzf" - -- name: (rHa) FZF - Installing - ansible.builtin.command: >- - {{ lookup('ansible.builtin.env', 'HOME' ) }}/.fzf/install diff --git a/roles/fzf/tasks/install/void.yml b/roles/fzf/tasks/install/void.yml deleted file mode 100644 index 78dbb0d..0000000 --- a/roles/fzf/tasks/install/void.yml +++ /dev/null @@ -1,9 +0,0 @@ ---- -# FZF - install on Void - -- name: (void) FZF - install - community.general.xbps: - name: fzf - state: present - update_cache: true - become: true diff --git a/roles/fzf/tasks/main.yml b/roles/fzf/tasks/main.yml deleted file mode 100644 index deb6a7e..0000000 --- a/roles/fzf/tasks/main.yml +++ /dev/null @@ -1,13 +0,0 @@ ---- -# Installation of fzf - -- name: Installation - ansible.builtin.include_tasks: "install/{{ ansible_os_family | lower }}.yml" - args: - apply: - tags: - - fzf - - fzf-install - tags: - - fzf - - fzf-install diff --git a/roles/git/tasks/configuration.yml b/roles/git/tasks/configuration.yml deleted file mode 100644 index 50d0c84..0000000 --- a/roles/git/tasks/configuration.yml +++ /dev/null @@ -1,14 +0,0 @@ ---- -# Configuring git - -- name: Configuring git username - ansible.builtin.git_config: - name: user.name - scope: global - value: "Emiliano Vavassori" - -- name: Configuring git email - ansible.builtin.git_config: - name: user.email - scope: global - value: syntaxerrormmm@gmail.com diff --git a/roles/git/tasks/install/alpine.yml b/roles/git/tasks/install/alpine.yml deleted file mode 100644 index 6d98dcc..0000000 --- a/roles/git/tasks/install/alpine.yml +++ /dev/null @@ -1,9 +0,0 @@ ---- -# git on alpine - -- name: (alp) installing git - community.general.apk: - name: git - state: present - update_cache: true - become: true diff --git a/roles/git/tasks/install/archlinux.yml b/roles/git/tasks/install/archlinux.yml deleted file mode 100644 index 3a3d7ec..0000000 --- a/roles/git/tasks/install/archlinux.yml +++ /dev/null @@ -1,9 +0,0 @@ ---- -# git on Archlinux - -- name: (arch) installing git - community.general.pacman: - name: git - state: present - update_cache: true - become: true diff --git a/roles/git/tasks/install/debian.yml b/roles/git/tasks/install/debian.yml deleted file mode 100644 index facc765..0000000 --- a/roles/git/tasks/install/debian.yml +++ /dev/null @@ -1,9 +0,0 @@ ---- -# git on Debian - -- name: (deb) installing git - ansible.builtin.apt: - name: git - state: present - update_cache: true - become: true diff --git a/roles/git/tasks/install/redhat.yml b/roles/git/tasks/install/redhat.yml deleted file mode 100644 index 2b57073..0000000 --- a/roles/git/tasks/install/redhat.yml +++ /dev/null @@ -1,9 +0,0 @@ ---- -# git on RedHat - -- name: (rHa) installing git - ansible.builtin.yum: - name: git - state: present - update_cache: true - become: true diff --git a/roles/git/tasks/install/void.yml b/roles/git/tasks/install/void.yml deleted file mode 100644 index b4f4f6b..0000000 --- a/roles/git/tasks/install/void.yml +++ /dev/null @@ -1,9 +0,0 @@ ---- -# git on void - -- name: (void) installing git - community.general.xbps: - name: git - state: present - update_cache: true - become: true diff --git a/roles/git/tasks/main.yml b/roles/git/tasks/main.yml deleted file mode 100644 index a124777..0000000 --- a/roles/git/tasks/main.yml +++ /dev/null @@ -1,19 +0,0 @@ ---- -# Installing and configuring git - -- name: Installation - ansible.builtin.include_tasks: "install/{{ ansible_os_family | lower }}.yml" - args: - apply: - tags: - - git - - git-install - tags: - - git - - git-install - -- name: Configuring git - ansible.builtin.import_tasks: configuration.yml - tags: - - git - - git-config diff --git a/roles/pip/tasks/install/alpine.yml b/roles/pip/tasks/install/alpine.yml deleted file mode 100644 index 0552d0c..0000000 --- a/roles/pip/tasks/install/alpine.yml +++ /dev/null @@ -1,11 +0,0 @@ ---- -# pip on alpine - -- name: (alp) installing pip - community.general.apk: - name: - - py3-pip - - py3-virtualenv - state: present - update_cache: true - become: true diff --git a/roles/pip/tasks/install/archlinux.yml b/roles/pip/tasks/install/archlinux.yml deleted file mode 100644 index c21f876..0000000 --- a/roles/pip/tasks/install/archlinux.yml +++ /dev/null @@ -1,11 +0,0 @@ ---- -# pip on Archlinux - -- name: (arch) installing pip - community.general.pacman: - name: - - python-pip - - python-virtualenv - state: present - update_cache: true - become: true diff --git a/roles/pip/tasks/install/debian.yml b/roles/pip/tasks/install/debian.yml deleted file mode 100644 index f9dd2e8..0000000 --- a/roles/pip/tasks/install/debian.yml +++ /dev/null @@ -1,11 +0,0 @@ ---- -# Pip on debian - -- name: (deb) installing pip - ansible.builtin.apt: - name: - - python3-pip - - python3-virtualenv - state: present - update_cache: true - become: true diff --git a/roles/pip/tasks/install/redhat.yml b/roles/pip/tasks/install/redhat.yml deleted file mode 100644 index af3eb73..0000000 --- a/roles/pip/tasks/install/redhat.yml +++ /dev/null @@ -1,11 +0,0 @@ ---- -# pip on redhat - -- name: (rHa) installing pip - ansible.builtin.yum: - name: - - python3-pip - - python-virtualenv - state: present - update_cache: true - become: true diff --git a/roles/pip/tasks/install/void.yml b/roles/pip/tasks/install/void.yml deleted file mode 100644 index 78f0ce6..0000000 --- a/roles/pip/tasks/install/void.yml +++ /dev/null @@ -1,11 +0,0 @@ ---- -# pip on void - -- name: (void) installing pip - community.general.xbps: - name: - - python-pip - - python3-virtualenv - state: present - update_cache: true - become: true diff --git a/roles/pip/tasks/main.yml b/roles/pip/tasks/main.yml deleted file mode 100644 index e19b281..0000000 --- a/roles/pip/tasks/main.yml +++ /dev/null @@ -1,13 +0,0 @@ ---- -# Verifying pip is installed. - -- name: Installing pip - ansible.builtin.include_tasks: "install/{{ ansible_os_family | lower }}.yml" - args: - apply: - tags: - - pip - - pip-install - tags: - - pip - - pip-install diff --git a/roles/rclone/tasks/install/alpine.yml b/roles/rclone/tasks/install/alpine.yml deleted file mode 100644 index e13d291..0000000 --- a/roles/rclone/tasks/install/alpine.yml +++ /dev/null @@ -1,7 +0,0 @@ ---- -- name: (alp) installing rclone - community.general.apk: - name: rclone - state: present - update_cache: true - become: true diff --git a/roles/rclone/tasks/install/archlinux.yml b/roles/rclone/tasks/install/archlinux.yml deleted file mode 100644 index 30b8b42..0000000 --- a/roles/rclone/tasks/install/archlinux.yml +++ /dev/null @@ -1,7 +0,0 @@ ---- -- name: (arch) installing rclone - community.general.pacman: - name: rclone - state: present - update_cache: true - become: true diff --git a/roles/rclone/tasks/install/debian.yml b/roles/rclone/tasks/install/debian.yml deleted file mode 100644 index 0e47d19..0000000 --- a/roles/rclone/tasks/install/debian.yml +++ /dev/null @@ -1,7 +0,0 @@ ---- -- name: (deb) installing rclone - ansible.builtin.apt: - name: rclone - state: present - update_cache: true - become: true diff --git a/roles/rclone/tasks/install/redhat.yml b/roles/rclone/tasks/install/redhat.yml deleted file mode 100644 index d22be90..0000000 --- a/roles/rclone/tasks/install/redhat.yml +++ /dev/null @@ -1,7 +0,0 @@ ---- -- name: (rHa) installing rclone - ansible.builtin.yum: - name: rclone - state: present - update_cache: true - become: true diff --git a/roles/rclone/tasks/install/void.yml b/roles/rclone/tasks/install/void.yml deleted file mode 100644 index 3cfaca3..0000000 --- a/roles/rclone/tasks/install/void.yml +++ /dev/null @@ -1,7 +0,0 @@ ---- -- name: (void) installing rclone - community.general.xbps: - name: rclone - state: present - update_cache: true - become: true diff --git a/roles/rclone/tasks/main.yml b/roles/rclone/tasks/main.yml deleted file mode 100644 index bdbbd33..0000000 --- a/roles/rclone/tasks/main.yml +++ /dev/null @@ -1,13 +0,0 @@ ---- -# Rclone - -- name: Installation - ansible.builtin.include_tasks: "install/{{ ansible_os_family | lower }}.yml" - args: - apply: - tags: - - rclone - - rclone-install - tags: - - rclone - - rclone-install diff --git a/roles/rsync/tasks/install/alpine.yml b/roles/rsync/tasks/install/alpine.yml deleted file mode 100644 index ee814e3..0000000 --- a/roles/rsync/tasks/install/alpine.yml +++ /dev/null @@ -1,9 +0,0 @@ ---- -# rsync - -- name: (alp) installing rsync - community.general.apk: - name: rsync - state: present - update_cache: true - become: true diff --git a/roles/rsync/tasks/install/archlinux.yml b/roles/rsync/tasks/install/archlinux.yml deleted file mode 100644 index 6bbcd1e..0000000 --- a/roles/rsync/tasks/install/archlinux.yml +++ /dev/null @@ -1,7 +0,0 @@ ---- -- name: (arch) installing rsync - community.general.pacman: - name: rsync - state: present - update_cache: true - become: true diff --git a/roles/rsync/tasks/install/debian.yml b/roles/rsync/tasks/install/debian.yml deleted file mode 100644 index 5393a44..0000000 --- a/roles/rsync/tasks/install/debian.yml +++ /dev/null @@ -1,7 +0,0 @@ ---- -- name: (deb) installing rsync - ansible.builtin.apt: - name: rsync - state: present - update_cache: true - become: true diff --git a/roles/rsync/tasks/install/redhat.yml b/roles/rsync/tasks/install/redhat.yml deleted file mode 100644 index 4638c2a..0000000 --- a/roles/rsync/tasks/install/redhat.yml +++ /dev/null @@ -1,7 +0,0 @@ ---- -- name: (rHa) installing rsync - ansible.builtin.yum: - name: rsync - state: present - update_cache: true - become: true diff --git a/roles/rsync/tasks/install/void.yml b/roles/rsync/tasks/install/void.yml deleted file mode 100644 index 97266ae..0000000 --- a/roles/rsync/tasks/install/void.yml +++ /dev/null @@ -1,7 +0,0 @@ ---- -- name: (void) installing rsync - community.general.xbps: - name: rsync - state: present - update_cache: true - become: true diff --git a/roles/rsync/tasks/main.yml b/roles/rsync/tasks/main.yml deleted file mode 100644 index 54a8bc1..0000000 --- a/roles/rsync/tasks/main.yml +++ /dev/null @@ -1,13 +0,0 @@ ---- -# Rsync - -- name: Installation - ansible.builtin.include_tasks: "install/{{ ansible_os_family | lower }}.yml" - args: - apply: - tags: - - rsync - - rsync-install - tags: - - rsync - - rsync-install diff --git a/roles/tmux/defaults/main.yml b/roles/tmux/defaults/main.yml deleted file mode 100644 index acd7660..0000000 --- a/roles/tmux/defaults/main.yml +++ /dev/null @@ -1,2 +0,0 @@ ---- -dotfdir: "{{ lookup('ansible.builtin.env', 'HOME' ) }}/.dotfiles" diff --git a/roles/tmux/tasks/configuration.yml b/roles/tmux/tasks/configuration.yml deleted file mode 100644 index e236519..0000000 --- a/roles/tmux/tasks/configuration.yml +++ /dev/null @@ -1,32 +0,0 @@ ---- -# Tmux standard configuration - -- name: Creating configuration folders - ansible.builtin.file: - path: "{{ lookup('ansible.builtin.env', 'HOME' ) }}/.config/tmux/plugins" - state: directory - owner: syntaxerrormmm - group: syntaxerrormmm - mode: '0755' - -- name: Getting tpm - ansible.builtin.git: - repo: https://github.com/tmux-plugins/tpm.git - depth: 1 - dest: "{{ lookup('ansible.builtin.env', 'HOME' ) }}/.config/tmux/plugins/tpm" - -- name: Linking default configuration file - ansible.builtin.file: - src: "{{ dotfdir }}/tmux.conf" - dest: "{{ lookup('ansible.builtin.env', 'HOME' ) }}/.config/tmux/tmux.conf" - state: link - owner: syntaxerrormmm - group: syntaxerrormmm - -- name: Fallback default old standard - ansible.builtin.file: - src: "{{ lookup('ansible.builtin.env', 'HOME' ) }}/.config/tmux/tmux.conf" - dest: "{{ lookup('ansible.builtin.env', 'HOME' ) }}/.tmux.conf" - state: link - owner: syntaxerrormmm - group: syntaxerrormmm diff --git a/roles/tmux/tasks/install/alpine.yml b/roles/tmux/tasks/install/alpine.yml deleted file mode 100644 index 0166d7b..0000000 --- a/roles/tmux/tasks/install/alpine.yml +++ /dev/null @@ -1,7 +0,0 @@ ---- -- name: (alp) installing tmux - community.general.apk: - name: tmux - state: present - update_cache: true - become: true diff --git a/roles/tmux/tasks/install/archlinux.yml b/roles/tmux/tasks/install/archlinux.yml deleted file mode 100644 index 548d6dd..0000000 --- a/roles/tmux/tasks/install/archlinux.yml +++ /dev/null @@ -1,7 +0,0 @@ ---- -- name: (arch) installing tmux - community.general.pacman: - name: tmux - state: present - update_cache: true - become: true diff --git a/roles/tmux/tasks/install/debian.yml b/roles/tmux/tasks/install/debian.yml deleted file mode 100644 index 70c7a5b..0000000 --- a/roles/tmux/tasks/install/debian.yml +++ /dev/null @@ -1,7 +0,0 @@ ---- -- name: (deb) installing tmux - ansible.builtin.apt: - name: tmux - state: present - update_cache: true - become: true diff --git a/roles/tmux/tasks/install/redhat.yml b/roles/tmux/tasks/install/redhat.yml deleted file mode 100644 index c00d11f..0000000 --- a/roles/tmux/tasks/install/redhat.yml +++ /dev/null @@ -1,7 +0,0 @@ ---- -- name: (rHa) installing tmux - ansible.builtin.yum: - name: tmux - state: present - update_cache: true - become: true diff --git a/roles/tmux/tasks/install/void.yml b/roles/tmux/tasks/install/void.yml deleted file mode 100644 index fc4e64b..0000000 --- a/roles/tmux/tasks/install/void.yml +++ /dev/null @@ -1,7 +0,0 @@ ---- -- name: (void) installing tmux - community.general.xbps: - name: tmux - state: present - update_cache: true - become: true diff --git a/roles/tmux/tasks/main.yml b/roles/tmux/tasks/main.yml deleted file mode 100644 index 58ece0e..0000000 --- a/roles/tmux/tasks/main.yml +++ /dev/null @@ -1,23 +0,0 @@ ---- -# Managing tmux - -- name: Installation - ansible.builtin.include_tasks: "install/{{ ansible_os_family | lower }}.yml" - args: - apply: - tags: - - tmux - - tmux-install - tags: - - tmux - - tmux-install - -- name: Configuration - ansible.builtin.import_tasks: configuration.yml - tags: - - tmux - - tmux-config - -- name: Manual steps - ansible.builtin.debug: - msg: "Please run prefix + I in tmux to install the needed plugins." diff --git a/roles/vim-plug/handlers/main.yml b/roles/vim-plug/handlers/main.yml deleted file mode 100644 index ae9d155..0000000 --- a/roles/vim-plug/handlers/main.yml +++ /dev/null @@ -1,5 +0,0 @@ ---- -- name: repolist - ansible.builtin.command: yum repolist - become: true - become_user: root diff --git a/roles/vim-plug/tasks/depend/alpine.yml b/roles/vim-plug/tasks/depend/alpine.yml deleted file mode 100644 index 953b4a6..0000000 --- a/roles/vim-plug/tasks/depend/alpine.yml +++ /dev/null @@ -1,10 +0,0 @@ ---- -- name: (alp) installing plugin dependencies - community.general.apk: - name: - - nodejs - - npm - - yarn - state: present - update_cache: true - become: true diff --git a/roles/vim-plug/tasks/depend/archlinux.yml b/roles/vim-plug/tasks/depend/archlinux.yml deleted file mode 100644 index 1cc9c63..0000000 --- a/roles/vim-plug/tasks/depend/archlinux.yml +++ /dev/null @@ -1,10 +0,0 @@ ---- -- name: (arch) installing plugin dependencies - community.general.pacman: - name: - - nodejs - - npm - - yarn - state: present - update_cache: true - become: true diff --git a/roles/vim-plug/tasks/depend/debian.yml b/roles/vim-plug/tasks/depend/debian.yml deleted file mode 100644 index 71415cc..0000000 --- a/roles/vim-plug/tasks/depend/debian.yml +++ /dev/null @@ -1,10 +0,0 @@ ---- -- name: (deb) installing plugin dependencies - ansible.builtin.apt: - name: - - nodejs - - npm - - yarnpkg - state: present - update_cache: true - become: true diff --git a/roles/vim-plug/tasks/depend/redhat.yml b/roles/vim-plug/tasks/depend/redhat.yml deleted file mode 100644 index c797243..0000000 --- a/roles/vim-plug/tasks/depend/redhat.yml +++ /dev/null @@ -1,34 +0,0 @@ ---- -- name: (rHa) installing plugin dependencies - ansible.builtin.yum: - name: - - nodejs - - npm - state: present - update_cache: true - become: true - -# Yarn is available in other repository. -- name: (rHa) installing yarn repo - ansible.builtin.get_url: - url: "https://dl.yarnpkg.com/rpm/yarn.repo" - dest: /etc/yum.repos.d/yarn.repo - become: true - notify: repolist - -- name: (rHa) installing yarn gpg key - ansible.builtin.rpm_key: - key: "http://dl.yarnpkg.com/rpm/pubkey.gpg" - state: present - become: true - notify: repolist - -- name: Flushing handlers - ansible.builtin.meta: flush_handlers - -- name: (rHa) installing yarn - ansible.builtin.yum: - name: yarn - state: present - update_cache: true - become: true diff --git a/roles/vim-plug/tasks/depend/void.yml b/roles/vim-plug/tasks/depend/void.yml deleted file mode 100644 index b9b5b16..0000000 --- a/roles/vim-plug/tasks/depend/void.yml +++ /dev/null @@ -1,9 +0,0 @@ ---- -- name: (void) installing plugin dependencies - community.general.xbps: - name: - - nodejs - - yarn-bin - state: present - update_cache: true - become: true diff --git a/roles/vim-plug/tasks/installation.yml b/roles/vim-plug/tasks/installation.yml deleted file mode 100644 index eda335f..0000000 --- a/roles/vim-plug/tasks/installation.yml +++ /dev/null @@ -1,20 +0,0 @@ ---- -# Installation tasks - -- name: Installing plugin dependencies - ansible.builtin.include_tasks: "depend/{{ ansible_os_family | lower }}.yml" - -- name: Creating autoload dir - ansible.builtin.file: - path: "{{ lookup('ansible.builtin.env', 'HOME' ) }}/.vim/autoload" - state: directory - owner: syntaxerrormmm - group: syntaxerrormmm - -- name: Installing vim-plug from git - ansible.builtin.get_url: - url: "https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim" - dest: "{{ lookup('ansible.builtin.env', 'HOME' ) }}/.vim/autoload/plug.vim" - owner: syntaxerrormmm - group: syntaxerrormmm - mode: '0644' diff --git a/roles/vim-plug/tasks/main.yml b/roles/vim-plug/tasks/main.yml deleted file mode 100644 index fbce5b1..0000000 --- a/roles/vim-plug/tasks/main.yml +++ /dev/null @@ -1,12 +0,0 @@ ---- -# Configuring vim-plug - -- name: Installation - ansible.builtin.import_tasks: installation.yml - tags: - - vim-plug - - vim-plug-install - -- name: Configuration - ansible.builtin.shell: >- - vim +PlugInstall +qall diff --git a/roles/vim/defaults/main.yml b/roles/vim/defaults/main.yml deleted file mode 100644 index acd7660..0000000 --- a/roles/vim/defaults/main.yml +++ /dev/null @@ -1,2 +0,0 @@ ---- -dotfdir: "{{ lookup('ansible.builtin.env', 'HOME' ) }}/.dotfiles" diff --git a/roles/vim/tasks/configuration.yml b/roles/vim/tasks/configuration.yml deleted file mode 100644 index 65757c8..0000000 --- a/roles/vim/tasks/configuration.yml +++ /dev/null @@ -1,18 +0,0 @@ ---- -# Configuring vim - -- name: Linking main file - ansible.builtin.file: - src: "{{ dotfdir }}/vimrc" - dest: "{{ lookup('ansible.builtin.env', 'HOME' ) }}/.vimrc" - state: link - owner: syntaxerrormmm - group: syntaxerrormmm - -- name: Linking main folder - ansible.builtin.file: - src: "{{ dotfdir }}/vim" - dest: "{{ lookup('ansible.builtin.env', 'HOME' ) }}/.vim" - state: link - owner: syntaxerrormmm - group: syntaxerrormmm diff --git a/roles/vim/tasks/install/alpine.yml b/roles/vim/tasks/install/alpine.yml deleted file mode 100644 index f4ed425..0000000 --- a/roles/vim/tasks/install/alpine.yml +++ /dev/null @@ -1,7 +0,0 @@ ---- -- name: (alp) installing vim - community.general.apk: - name: vim - state: present - update_cache: true - become: true diff --git a/roles/vim/tasks/install/archlinux.yml b/roles/vim/tasks/install/archlinux.yml deleted file mode 100644 index 9346c34..0000000 --- a/roles/vim/tasks/install/archlinux.yml +++ /dev/null @@ -1,7 +0,0 @@ ---- -- name: (arch) installing vim - community.general.pacman: - name: vim - state: present - update_cache: true - become: true diff --git a/roles/vim/tasks/install/debian.yml b/roles/vim/tasks/install/debian.yml deleted file mode 100644 index 11dd3dd..0000000 --- a/roles/vim/tasks/install/debian.yml +++ /dev/null @@ -1,7 +0,0 @@ ---- -- name: (deb) installing vim - ansible.builtin.apt: - name: vim - state: present - update_cache: true - become: true diff --git a/roles/vim/tasks/install/redhat.yml b/roles/vim/tasks/install/redhat.yml deleted file mode 100644 index 5ccdf0f..0000000 --- a/roles/vim/tasks/install/redhat.yml +++ /dev/null @@ -1,7 +0,0 @@ ---- -- name: (rHa) installing vim - ansible.builtin.yum: - name: vim - state: present - update_cache: true - become: true diff --git a/roles/vim/tasks/install/void.yml b/roles/vim/tasks/install/void.yml deleted file mode 100644 index fa3955f..0000000 --- a/roles/vim/tasks/install/void.yml +++ /dev/null @@ -1,7 +0,0 @@ ---- -- name: (void) installing Vim - community.general.xbps: - name: vim - state: present - update_cache: true - become: true diff --git a/roles/vim/tasks/main.yml b/roles/vim/tasks/main.yml deleted file mode 100644 index 0b704d6..0000000 --- a/roles/vim/tasks/main.yml +++ /dev/null @@ -1,19 +0,0 @@ ---- -# Vim - -- name: Installation - ansible.builtin.include_tasks: "install/{{ ansible_os_family | lower }}.yml" - args: - apply: - tags: - - vim - - vim-install - tags: - - vim - - vim-install - -- name: Configuration - ansible.builtin.import_tasks: configuration.yml - tags: - - vim - - vim-config diff --git a/roles/zsh/defaults/main.yml b/roles/zsh/defaults/main.yml deleted file mode 100644 index b884bf7..0000000 --- a/roles/zsh/defaults/main.yml +++ /dev/null @@ -1,2 +0,0 @@ ---- -dotfdir: "{{ lookup('ansible.builtin.env', 'HOME' }}/.dotfiles" diff --git a/roles/zsh/tasks/config/alpine.yml b/roles/zsh/tasks/config/alpine.yml deleted file mode 100644 index 064a386..0000000 --- a/roles/zsh/tasks/config/alpine.yml +++ /dev/null @@ -1,10 +0,0 @@ ---- -# Configuration for base settings - Alpine - -- name: (alp) - ZSH base configuration - ansible.builtin.file: - src: "{{ dotfdir }}/zsh/distro/alpine.base.zsh" - dest: "{{ dotfdir }}/zsh/distro.base.zsh" - state: link - owner: syntaxerrormmm - group: syntaxerrormmm diff --git a/roles/zsh/tasks/config/archlinux.yml b/roles/zsh/tasks/config/archlinux.yml deleted file mode 100644 index ed90256..0000000 --- a/roles/zsh/tasks/config/archlinux.yml +++ /dev/null @@ -1,20 +0,0 @@ ---- -# Configuration for base settings - Archlinux - -- name: (arch) - ZSH base configuration - ansible.builtin.file: - src: "{{ dotfdir }}/zsh/distro/archlinux.base.zsh" - dest: "{{ dotfdir }}/zsh/distro.base.zsh" - state: link - owner: syntaxerrormmm - group: syntaxerrormmm - when: ansible_lsb == [] or ansible_lsb.description == 'Arch Linux' - -- name: (manj) - ZSH base configuration - ansible.builtin.file: - src: "{{ dotfdir }}/zsh/distro/manjaro.base.zsh" - dest: "{{ dotfdir }}/zsh/distro.base.zsh" - state: link - owner: syntaxerrormmm - group: syntaxerrormmm - when: ansible_lsb != [] and ansible_lsb.description == 'Manjaro Linux' diff --git a/roles/zsh/tasks/config/debian.yml b/roles/zsh/tasks/config/debian.yml deleted file mode 100644 index 11e50f2..0000000 --- a/roles/zsh/tasks/config/debian.yml +++ /dev/null @@ -1,20 +0,0 @@ ---- -# Configuration for base settings - Debian - -- name: (deb) - ZSH base configuration - ansible.builtin.file: - src: "{{ dotfdir }}/zsh/distro/debian.base.zsh" - dest: "{{ dotfdir }}/zsh/distro.base.zsh" - state: link - owner: syntaxerrormmm - group: syntaxerrormmm - when: ansible_distribution == 'Debian' - -- name: (ubu) - ZSH base configuration - ansible.builtin.file: - src: "{{ dotfdir }}/zsh/distro/ubuntu.base.zsh" - dest: "{{ dotfdir }}/zsh/distro.base.zsh" - state: link - owner: syntaxerrormmm - group: syntaxerrormmm - when: ansible_distribution == 'Ubuntu' diff --git a/roles/zsh/tasks/config/main.yml b/roles/zsh/tasks/config/main.yml deleted file mode 100644 index 449314e..0000000 --- a/roles/zsh/tasks/config/main.yml +++ /dev/null @@ -1,26 +0,0 @@ ---- -# Configuring zsh - -- name: Fixing base settings - ansible.builtin.include_tasks: "{{ ansible_os_family | lower }}.yml" - -- name: Set zsh as default shell for syntaxerrormmm - ansible.builtin.user: - name: syntaxerrormmm - shell: /usr/bin/zsh - -- name: Creating personal folder for customization - ansible.builtin.file: - path: "{{ lookup('ansible.builtin.env', 'HOME' ) }}/.zsh/conf.d" - state: directory - owner: syntaxerrormmm - group: syntaxerrormmm - mode: "0755" - -- name: Linking main file - ansible.builtin.file: - src: "{{ dotfdir }}/zshrc" - dest: "{{ lookup('ansible.builtin.env', 'HOME' ) }}/.zshrc" - state: link - owner: syntaxerrormmm - group: syntaxerrormmm diff --git a/roles/zsh/tasks/config/redhat.yml b/roles/zsh/tasks/config/redhat.yml deleted file mode 100644 index 945b57a..0000000 --- a/roles/zsh/tasks/config/redhat.yml +++ /dev/null @@ -1,10 +0,0 @@ ---- -# Configuration for base settings - RedHat - -- name: (rha) - ZSH base configuration - ansible.builtin.file: - src: "{{ dotfdir }}/zsh/distro/centos.base.zsh" - dest: "{{ dotfdir }}/zsh/distro.base.zsh" - state: link - owner: syntaxerrormmm - group: syntaxerrormmm diff --git a/roles/zsh/tasks/config/void.yml b/roles/zsh/tasks/config/void.yml deleted file mode 100644 index a4e6bb1..0000000 --- a/roles/zsh/tasks/config/void.yml +++ /dev/null @@ -1,10 +0,0 @@ ---- -# Configuration for base settings - Void - -- name: (void) - ZSH base configuration - ansible.builtin.file: - src: "{{ dotfdir }}/zsh/distro/void.base.zsh" - dest: "{{ dotfdir }}/zsh/distro.base.zsh" - state: link - owner: syntaxerrormmm - group: syntaxerrormmm diff --git a/roles/zsh/tasks/configuration.yml b/roles/zsh/tasks/configuration.yml deleted file mode 100644 index 28ed259..0000000 --- a/roles/zsh/tasks/configuration.yml +++ /dev/null @@ -1,31 +0,0 @@ ---- -# Configuring zsh - -- name: Set zsh as default shell for syntaxerrormmm - ansible.builtin.user: - name: syntaxerrormmm - shell: /usr/bin/zsh - tags: - - zsh - - omz - - zsh-config - - zsh-config-omz - -- name: Creating personal folder for customization - ansible.builtin.file: - path: "{{ lookup('ansible.builtin.env', 'HOME' ) }}/.zsh/conf.d" - state: directory - owner: syntaxerrormmm - group: syntaxerrormmm - mode: "0755" - -- name: Linking main file - ansible.builtin.file: - src: "{{ dotfdir }}/zshrc" - dest: "{{ lookup('ansible.builtin.env', 'HOME' ) }}/.zshrc" - state: link - owner: syntaxerrormmm - group: syntaxerrormmm - -- name: Fixing base settings - ansible.builtin.include_tasks: "{{ ansible_os_family | lower }}.yml" diff --git a/roles/zsh/tasks/install/alpine.yml b/roles/zsh/tasks/install/alpine.yml deleted file mode 100644 index caff7e6..0000000 --- a/roles/zsh/tasks/install/alpine.yml +++ /dev/null @@ -1,14 +0,0 @@ ---- -- name: (Alpine) Installing packages around zsh - community.general.apk: - name: - - zsh - - zsh-completions - - zsh-autosuggestions - - zsh-syntax-highlighting - - zsh-history-substring-search - - zsh-theme-powerlevel10k - - zsh-vcs - state: present - update_cache: true - become: true diff --git a/roles/zsh/tasks/install/archlinux.yml b/roles/zsh/tasks/install/archlinux.yml deleted file mode 100644 index 7f92288..0000000 --- a/roles/zsh/tasks/install/archlinux.yml +++ /dev/null @@ -1,13 +0,0 @@ ---- -- name: (Arch) Installing packages around zsh - community.general.pacman: - name: - - zsh - - zsh-completions - - zsh-autosuggestions - - zsh-syntax-highlighting - - zsh-history-substring-search - - zsh-theme-powerlevel10k - state: present - update_cache: true - become: true diff --git a/roles/zsh/tasks/install/debian.yml b/roles/zsh/tasks/install/debian.yml deleted file mode 100644 index 184d45c..0000000 --- a/roles/zsh/tasks/install/debian.yml +++ /dev/null @@ -1,25 +0,0 @@ ---- -# Installing zsh and its dependency - -- name: (Deb) Installing packages around zsh - ansible.builtin.apt: - name: - - zsh - - zsh-autosuggestions - - zsh-syntax-highlighting - state: present - update_cache: true - when: ansible_distribution == 'Debian' - become: true - -- name: (ubu) Installing packages around zsh - ansible.builtin.apt: - name: - - zsh - - zsh-autosuggestions - - zsh-syntax-highlighting - - zsh-theme-powerlevel9k - state: present - update_cache: true - when: ansible_distribution == 'Ubuntu' - become: true diff --git a/roles/zsh/tasks/install/redhat.yml b/roles/zsh/tasks/install/redhat.yml deleted file mode 100644 index 255c6d5..0000000 --- a/roles/zsh/tasks/install/redhat.yml +++ /dev/null @@ -1,9 +0,0 @@ ---- -- name: (RH) Installing packages around zsh - ansible.builtin.yum: - name: - - zsh - - zsh-syntax-highlighting - state: present - update_cache: true - become: true diff --git a/roles/zsh/tasks/install/void.yml b/roles/zsh/tasks/install/void.yml deleted file mode 100644 index a1a47c5..0000000 --- a/roles/zsh/tasks/install/void.yml +++ /dev/null @@ -1,14 +0,0 @@ ---- -# Installing zsh and its dependency - -- name: (Void) Installing packages around zsh - community.general.xbps: - name: - - zsh - - zsh-completions - - zsh-autosuggestions - - zsh-syntax-highlighting - - zsh-history-substring-search - state: present - update_cache: true - become: true diff --git a/roles/zsh/tasks/main.yml b/roles/zsh/tasks/main.yml deleted file mode 100644 index bda4393..0000000 --- a/roles/zsh/tasks/main.yml +++ /dev/null @@ -1,19 +0,0 @@ ---- -# Setting up zsh - -- name: Installation - ansible.builtin.include_tasks: "install/{{ ansible_os_family | lower }}.yml" - args: - apply: - tags: - - zsh - - zsh-install - tags: - - zsh - - zsh-install - -- name: Configuration - ansible.builtin.import_tasks: config/main.yml - tags: - - zsh - - zsh-config diff --git a/zsh/antibody_plugins.txt b/zsh/antibody_plugins.txt index 97afe2e..620c39b 100644 --- a/zsh/antibody_plugins.txt +++ b/zsh/antibody_plugins.txt @@ -1,5 +1,6 @@ ohmyzsh/ohmyzsh path:plugins/command-not-found ohmyzsh/ohmyzsh path:plugins/common-aliases +ohmyzsh/ohmyzsh path:plugins/copyfile ohmyzsh/ohmyzsh path:plugins/fzf ohmyzsh/ohmyzsh path:plugins/git ohmyzsh/ohmyzsh path:plugins/pip diff --git a/zshrc b/zshrc index ceb9735..9cbcd10 100644 --- a/zshrc +++ b/zshrc @@ -22,9 +22,6 @@ fi if [[ -f /usr/share/zsh-antidote/antidote.zsh ]]; then source /usr/share/zsh-antidote/antidote.zsh fi -if [[ -f ${HOME}/.zsh/antidote/antidote.zsh ]]; then - source ${HOME}/.zsh/antidote/antidote.zsh -fi # configuring fzf plugin for tmux export ZSH_TMUX_CONFIG=${HOME}/.config/tmux/tmux.conf