From 6f537bd04b1b76f7df78ddc6403c94f5b76192ae Mon Sep 17 00:00:00 2001 From: eoli3n Date: Sun, 1 Dec 2019 16:29:03 +0100 Subject: [PATCH] major update --- .gitignore | 1 + README.md | 219 +++---- hosts | 11 +- hosts.template | 3 + install.yml | 15 +- roles/authorized_keys/tasks/main.yml | 2 +- roles/compton/tasks/main.yml | 24 - roles/cursor/tasks/main.yml | 13 - roles/dpms/files/dpms.sh | 3 + roles/dpms/tasks/main.yml | 5 + roles/fish/files/config.fish | 4 + roles/fish/files/laptop.fish | 4 + roles/fish/tasks/main.yml | 46 ++ roles/fzf/files/fzf.zsh | 14 - roles/fzf/tasks/main.yml | 10 - roles/gtk/files/Trolltech.conf | 23 + roles/{cursor => gtk}/files/cursor | 0 roles/gtk/files/settings.ini | 6 +- roles/gtk/tasks/main.yml | 53 +- roles/i3-wm/tasks/main.yml | 23 +- roles/i3-wm/templates/by_host/osz/config.j2 | 23 +- roles/i3-wm/templates/by_host/work/config.j2 | 40 +- roles/i3-wm/templates/config.j2 | 40 +- roles/neofetch/tasks/main.yml | 21 +- roles/neovim/files/init.vim | 29 + roles/neovim/tasks/main.yml | 12 + .../tasks/by_os/archlinux/main.yml | 9 - .../tasks/by_os/centos/main.yml | 8 +- roles/packages-common/tasks/main.yml | 19 +- roles/packages-desktop/handlers/main.yml | 2 - .../tasks/by_host/arch-itect/main.yml | 4 - .../tasks/by_host/osz/main.yml | 4 - .../tasks/by_os/archlinux/main.yml | 27 +- roles/packages-desktop/tasks/main.yml | 31 +- roles/packages-laptop/tasks/main.yml | 4 +- .../files/compton => picom/files/picom} | 10 +- roles/picom/files/picom.sh | 1 + roles/picom/files/picom.vagrant.sh | 1 + roles/picom/tasks/main.yml | 22 + roles/polybar/README.md | 54 +- roles/polybar/files/bars/bottom | 38 ++ roles/polybar/files/bars/top | 51 ++ roles/polybar/files/bars/top_light | 51 ++ roles/polybar/files/config | 58 ++ roles/polybar/files/modules/backlight | 18 + roles/polybar/files/modules/battery | 33 ++ roles/polybar/files/modules/cpu | 16 + roles/polybar/files/modules/date | 15 + roles/polybar/files/modules/eth | 13 + roles/polybar/files/modules/filesystem-home | 5 + roles/polybar/files/modules/filesystem-slash | 7 + roles/polybar/files/modules/i3 | 39 ++ roles/polybar/files/modules/jgmenu | 5 + roles/polybar/files/modules/memory | 18 + roles/polybar/files/modules/networkspeeddown | 7 + roles/polybar/files/modules/networkspeedup | 7 + roles/polybar/files/modules/pkg | 9 + roles/polybar/files/modules/powermenu | 33 ++ roles/polybar/files/modules/redshift | 9 + roles/polybar/files/modules/temperature | 18 + roles/polybar/files/modules/volume | 28 + roles/polybar/files/modules/vpncheck | 8 + roles/polybar/files/modules/wlan | 22 + roles/polybar/files/modules/xkeyboard | 13 + roles/polybar/files/modules/xwindow | 3 + roles/polybar/files/pkg.sh | 8 +- roles/polybar/tasks/main.yml | 56 +- roles/polybar/templates/by_host/osz/launch.j2 | 3 +- .../templates/by_host/osz/modules-bottom.j2 | 3 - .../templates/by_host/osz/modules-top.j2 | 3 - .../polybar/templates/by_host/work/launch.j2 | 7 +- .../templates/by_host/work/modules-bottom.j2 | 3 - .../templates/by_host/work/modules-def.j2 | 19 - .../templates/by_host/work/modules-top.j2 | 3 - roles/polybar/templates/config.j2 | 558 ------------------ roles/polybar/templates/launch.j2 | 4 +- roles/rofi/files/powermenu.sh | 12 +- roles/rofi/files/rofi | 3 +- roles/rofi/tasks/main.yml | 27 +- roles/screen/tasks/main.yml | 9 +- roles/ssh-agent/files/ssh-add.sh | 2 + roles/ssh-agent/tasks/main.yml | 9 +- roles/terminfo/tasks/by_os/archlinux/main.yml | 4 - roles/terminfo/tasks/by_os/common/main.yml | 12 +- roles/terminfo/tasks/main.yml | 3 +- roles/termite/tasks/main.yml | 17 +- roles/vagrant/files/wallpaper.sh | 1 + roles/vagrant/tasks/main.yml | 17 +- roles/variety/files/variety.conf | 216 +++++++ roles/variety/files/variety.sh | 1 + roles/variety/tasks/main.yml | 17 + roles/vim/files/pathogen.vim | 289 --------- roles/vim/tasks/main.yml | 49 -- roles/vim/templates/vimrc | 34 -- roles/weechat/README.md | 7 +- roles/weechat/files/weechat.sh | 1 + roles/weechat/tasks/main.yml | 31 +- roles/xbindkeys/files/.xbindkeysrc | 71 +++ roles/xbindkeys/files/xbindkeys.sh | 1 + roles/xbindkeys/tasks/main.yml | 18 +- roles/xprofile/files/xprofile | 1 + roles/xprofile/tasks/main.yml | 10 + roles/zsh/README.md | 2 + 103 files changed, 1450 insertions(+), 1445 deletions(-) create mode 100644 hosts.template delete mode 100644 roles/compton/tasks/main.yml delete mode 100644 roles/cursor/tasks/main.yml create mode 100644 roles/dpms/files/dpms.sh create mode 100644 roles/dpms/tasks/main.yml create mode 100644 roles/fish/files/config.fish create mode 100644 roles/fish/files/laptop.fish create mode 100644 roles/fish/tasks/main.yml delete mode 100644 roles/fzf/files/fzf.zsh delete mode 100644 roles/fzf/tasks/main.yml rename roles/{cursor => gtk}/files/cursor (100%) create mode 100644 roles/neovim/files/init.vim create mode 100644 roles/neovim/tasks/main.yml delete mode 100644 roles/packages-common/tasks/by_os/archlinux/main.yml delete mode 100644 roles/packages-desktop/handlers/main.yml delete mode 100644 roles/packages-desktop/tasks/by_host/arch-itect/main.yml delete mode 100644 roles/packages-desktop/tasks/by_host/osz/main.yml rename roles/{compton/files/compton => picom/files/picom} (93%) create mode 100644 roles/picom/files/picom.sh create mode 100644 roles/picom/files/picom.vagrant.sh create mode 100644 roles/picom/tasks/main.yml create mode 100644 roles/polybar/files/bars/bottom create mode 100644 roles/polybar/files/bars/top create mode 100644 roles/polybar/files/bars/top_light create mode 100644 roles/polybar/files/config create mode 100644 roles/polybar/files/modules/backlight create mode 100644 roles/polybar/files/modules/battery create mode 100644 roles/polybar/files/modules/cpu create mode 100644 roles/polybar/files/modules/date create mode 100644 roles/polybar/files/modules/eth create mode 100644 roles/polybar/files/modules/filesystem-home create mode 100644 roles/polybar/files/modules/filesystem-slash create mode 100644 roles/polybar/files/modules/i3 create mode 100644 roles/polybar/files/modules/jgmenu create mode 100644 roles/polybar/files/modules/memory create mode 100644 roles/polybar/files/modules/networkspeeddown create mode 100644 roles/polybar/files/modules/networkspeedup create mode 100644 roles/polybar/files/modules/pkg create mode 100644 roles/polybar/files/modules/powermenu create mode 100644 roles/polybar/files/modules/redshift create mode 100644 roles/polybar/files/modules/temperature create mode 100644 roles/polybar/files/modules/volume create mode 100644 roles/polybar/files/modules/vpncheck create mode 100644 roles/polybar/files/modules/wlan create mode 100644 roles/polybar/files/modules/xkeyboard create mode 100644 roles/polybar/files/modules/xwindow delete mode 100644 roles/polybar/templates/by_host/osz/modules-bottom.j2 delete mode 100644 roles/polybar/templates/by_host/osz/modules-top.j2 delete mode 100644 roles/polybar/templates/by_host/work/modules-bottom.j2 delete mode 100644 roles/polybar/templates/by_host/work/modules-def.j2 delete mode 100644 roles/polybar/templates/by_host/work/modules-top.j2 delete mode 100644 roles/polybar/templates/config.j2 create mode 100644 roles/ssh-agent/files/ssh-add.sh delete mode 100644 roles/terminfo/tasks/by_os/archlinux/main.yml create mode 100644 roles/vagrant/files/wallpaper.sh create mode 100644 roles/variety/files/variety.conf create mode 100644 roles/variety/files/variety.sh create mode 100644 roles/variety/tasks/main.yml delete mode 100644 roles/vim/files/pathogen.vim delete mode 100644 roles/vim/tasks/main.yml delete mode 100644 roles/vim/templates/vimrc create mode 100644 roles/weechat/files/weechat.sh create mode 100644 roles/xbindkeys/files/.xbindkeysrc create mode 100644 roles/xbindkeys/files/xbindkeys.sh create mode 100644 roles/xprofile/files/xprofile create mode 100644 roles/xprofile/tasks/main.yml diff --git a/.gitignore b/.gitignore index 0526218..eb92652 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1,3 @@ .vagrant *.swp +.hosts diff --git a/README.md b/README.md index 93e35e0..32aa915 100644 --- a/README.md +++ b/README.md @@ -21,25 +21,112 @@ ![alt tag](https://github.com/eoli3n/dotfiles/blob/master/screenshots/connman-gtk.png) -## How to +## Why using Ansible ? Ansible allows to duplicate this Desktop Environment over multiple hosts with specific configuration (dualscreen, packages...). +All your nodes will have access to all configurations if +- your git repo is accessible from every nodes +- your current node ssh keys is authorized on all nodes -**Fork Me!** Please look at ``roles/*/README.md`` if exists for specific hosts configuration. - -**!!! Use as is, you will add my SSH key in your authorized_keys !!!** - -To disable that role, please run : -``` -cd dotfiles -sed -i 's/^\(.*authorized_keys.*\)$/#\1/' install.yml -``` +You should be able to edit and push from/to any managed hosts. ## Test VMs|Containers Please check ``vagrant/*/README.md`` and ``docker/*/README.md`` +## How to + +** Use carefully** backup your home before using ! Ansible will backup any existing conf file before overriding. + +# 1° Fork Me! + +# 2° Clone your repo on a personnal host +``` +git clone --recursive https://github.com/[your_repo]/dotfiles +cd dotfiles +``` +# 3° Generate ssh keys +``` +ssh-keygen -t rsa +``` +# 4° Replace your ssh key in ``authorized_keys`` role +**!!! Use as is, you will add my SSH key in your authorized_keys !!!** +``` +cp ~/.ssh/id_rsa.pub dotfiles/roles/authorized_keys/id_rsa.pub +``` +# 5° Generate hosts file with your managed hosts +``hosts`` file is defaultly gitignored. +``` +cd dotfiles +mv hosts.template hosts +``` +Add your hosts in right sections +- server : install only cli tools +- desktop : install graphic environment +- laptop: install desktop + some extra packages + +Please explicitly define an ``ansible_user`` which will receive configurations +``` +[server] +server1 ansible_user=root +[laptop] +host1 ansible_user=user +[desktop] +host2 ansible_user=user2 +``` +Remove useless groups and hosts + +# 6° Copy your SSH keys on all nodes : node per node if password differ between users +It add your public ssh keys on hosts +``` +ansible-playbook install.yml -t init_ssh -l host1 -K +ansible-playbook install.yml -t init_ssh -l host2 -K +ansible-playbook install.yml -t init_ssh -l host3 -K +``` + +# 7° Run ansible-playbook + +For runs on hosts configured with root user +You can use without providing extra passwords +``` +ansible-playbook install.yml -l server +``` +For hosts configured with non-root user +User needs to be in sudoers. +You need to use -K to ask sudo password, and -l to limit to that host +``` +ansible-playbook install.yml -l host1 -K +``` + +# Extra commands +To list tasks and tags +``` +ansible-playbook install.yml --list-tasks +``` +To limit to a tag +``` +ansible-playbook install.yml -K -t +``` +To dry-run and print files diff on all declared hosts +``` +ansible-playbook install.yml -l host1 -CDK +``` + +# Local run +Add localhost line and user in right hosts file section +``` +[server] +[laptop] +localhost ansible_connection=local ansible_user=user +[desktop] +``` +# then +ansible-playbook install.yml -l localhost -K +``` + +Please look at ``roles/*/README.md`` if exists for specific hosts configuration. + ## Desktop/Laptop Environment -Don't use as ``root``. +Should not be used as ``root``. ### Supported OS @@ -48,84 +135,34 @@ Don't use as ``root``. ### Dependencies - ansible >= 2.4 -- packer - -``` -sudo pacman -S jshon ansible -curl -o PKGBUILD https://aur.archlinux.org/cgit/aur.git/plain/PKGBUILD?h=packer-git; makepkg PKGBUILD --install --needed --noconfirm -``` ### Role list - packages-common -- screen -- ssh-agent -- authorized_keys +- fish +- neovim - terminfo -- vim -- zsh +- screen +- authorized_keys - packages-desktop -- compton -- cursor - gtk - i3-wm -- neofetch +- picom - polybar +- variety - rofi +- neofetch - termite - weechat +- ssh-agent +- dpms - packages-laptop [only laptop tag] - xbindkeys [only laptop tag] -### Installation -[WARNING] Use carefully, backup your home before using ! -Ansible will backup any existing conf file before erasing it (.zshrc, .i3/config, etc...) -``` -git clone --recursive https://github.com/eoli3n/dotfiles -cd dotfiles - -# edit hosts, then add your hostnames in right section -# test connectivity -ansible all -m ping - -# To list tasks and tags -ansible-playbook install.yml --list-tasks - -# To dry-run and print files diff on all declared hosts -ansible-playbook install.yml -CDK - -# To run the whole playbook for all hosts -ansible-playbook install.yml -K - -# To install 1 tag on 1 host -ansible-playbook install.yml -K -l -t - -# To install for a specific user on 1 host -ansible-playbook install.yml -u user -K -l - -# To run only locally, add your hostname in right hosts file section -# you can replace server with -echo << EOF > hosts -[server] -localhost ansible_connection=local -EOF -# then -ansible-playbook install.yml -``` - -### Manual configurations - -**Google chrome** - -Open this link to set lighter scrollbar -``` -chrome://flags/#overlay-scrollbars -``` -To use dark theme, go to graphical configuration and click ``Use GTK+ Theme`` - ## Server Environment -``server`` tag limits to install/configure cli tools. It could be run as ``root``. +Only cli tools +It could be run as ``root``. ### Supported OS @@ -141,44 +178,12 @@ To use dark theme, go to graphical configuration and click ``Use GTK+ Theme`` ### Role list - packages-common -- screen +- fish +- neovim - terminfo -- vim -- zsh +- screen - authorized_keys -## Installation - -``` -git clone --recursive https://github.com/eoli3n/dotfiles -cd dotfiles - -# edit hosts, then add your hostnames in right section -# test connectivity -ansible all -m ping - -# To list tasks and tags -ansible-playbook install.yml --list-tasks - -# To dry-run and print files diff on all declared hosts -ansible-playbook install.yml -CDK - -# To run the whole playbook for all hosts -ansible-playbook install.yml -K - -# To install 1 tag on 1 host -ansible-playbook install.yml -K -l -t - -# To run only locally, add your hostname in right hosts file section -# you can replace server with -echo << EOF > hosts -[server] -localhost ansible_connection=local -EOF -# then -ansible-playbook install.yml -``` - # Previously * [i3-gaps Dark Solarized](https://github.com/eoli3n/dotfiles/tree/zsh-agnoster-solarized) diff --git a/hosts b/hosts index b59cb40..a294022 100644 --- a/hosts +++ b/hosts @@ -1,7 +1,10 @@ [server] -cesium ansible_user=root -neon ansible_user=root +prodpeda-cesium +tspeda-kvm [laptop] -osz ansible_user=user -work ansible_user=userarch +osz become_user=user +localhost ansible_connection=local ansible_user=user + +[desktop] +work become_user=user diff --git a/hosts.template b/hosts.template new file mode 100644 index 0000000..e6daf79 --- /dev/null +++ b/hosts.template @@ -0,0 +1,3 @@ +[server] +[laptop] +[desktop] diff --git a/install.yml b/install.yml index e8eb57e..d988785 100644 --- a/install.yml +++ b/install.yml @@ -1,4 +1,8 @@ --- +- hosts: all + roles: + - { role: authorized_keys, tags: init_ssh } + - hosts: server tags: limit tasks: @@ -26,25 +30,26 @@ - hosts: server:desktop:laptop roles: - { role: packages-common, tags: packages-common } - - { role: zsh, tags: zsh } - - { role: vim, tags: vim } + - { role: fish, tags: fish } + - { role: neovim, tags: neovim } - { role: terminfo, tags: terminfo } - { role: screen, tags: screen } - - { role: authorized_keys, tags: authorized_keys } - hosts: desktop:laptop roles: + - { role: xprofile, tags: xprofile } - { role: packages-desktop, tags: packages-desktop } - - { role: cursor, tags: cursor } - { role: gtk, tags: gtk } - { role: i3-wm, tags: i3-wm } - - { role: compton, tags: compton } + - { role: picom, tags: picom } - { role: polybar, tags: polybar } + - { role: variety, tags: variety } - { role: rofi, tags: rofi } - { role: neofetch, tags: neofetch } - { role: termite, tags: termite } - { role: weechat, tags: weechat } - { role: ssh-agent, tags: ssh-agent } + - { role: dpms, tags: dpms } tasks: - include_role: name: vagrant diff --git a/roles/authorized_keys/tasks/main.yml b/roles/authorized_keys/tasks/main.yml index e7b6eeb..889fd33 100644 --- a/roles/authorized_keys/tasks/main.yml +++ b/roles/authorized_keys/tasks/main.yml @@ -1,5 +1,5 @@ --- -- name: authorize eoli3n key +- name: authorize keys authorized_key: user: "{{ ansible_user_id }}" state: present diff --git a/roles/compton/tasks/main.yml b/roles/compton/tasks/main.yml deleted file mode 100644 index d8df70c..0000000 --- a/roles/compton/tasks/main.yml +++ /dev/null @@ -1,24 +0,0 @@ ---- -- name: Install compton - aur: name=compton-git use=makepkg - -- name: Configure compton - copy: src=files/compton dest=~/.compton backup=yes - -- name: Init compton in .xprofile - blockinfile: - path: ~/.xprofile - create: True - marker: "### {mark} DOTFILES compton ###" - content: | - compton --backend glx --vsync opengl-swc -GCb --config ~/.compton & - when: ansible_user_id != "vagrant" - -- name: Init compton in .xprofile [Vagrant] - blockinfile: - path: ~/.xprofile - create: True - marker: "### {mark} DOTFILES compton ###" - content: | - compton -GCb --config ~/.compton & - when: ansible_user_id == "vagrant" diff --git a/roles/cursor/tasks/main.yml b/roles/cursor/tasks/main.yml deleted file mode 100644 index 270bcd9..0000000 --- a/roles/cursor/tasks/main.yml +++ /dev/null @@ -1,13 +0,0 @@ ---- -- name: Install Cursors - aur: name=capitaine-cursors use=makepkg - -- name: Create .Xresources.d dir - file: path=~/.Xresources.d state=directory - -- name: Configure Cursors - copy: src=files/cursor dest=~/.Xresources.d/cursor - -- name: Init Cursors in .Xresources - lineinfile: path=~/.Xresources create=yes state=present line='#include ".Xresources.d/cursor"' - diff --git a/roles/dpms/files/dpms.sh b/roles/dpms/files/dpms.sh new file mode 100644 index 0000000..c6a0c52 --- /dev/null +++ b/roles/dpms/files/dpms.sh @@ -0,0 +1,3 @@ +#dpms and screen saver 60s +xset s 60 60 +xset dpms 60 60 60 diff --git a/roles/dpms/tasks/main.yml b/roles/dpms/tasks/main.yml new file mode 100644 index 0000000..2bc5a54 --- /dev/null +++ b/roles/dpms/tasks/main.yml @@ -0,0 +1,5 @@ +--- +- name: configure dpms in xprofile + copy: + src: dpms.sh + dest: ~/.xprofile.d/ diff --git a/roles/fish/files/config.fish b/roles/fish/files/config.fish new file mode 100644 index 0000000..362151b --- /dev/null +++ b/roles/fish/files/config.fish @@ -0,0 +1,4 @@ +set -x LANG 'fr_FR.UTF-8' +set -x EDITOR 'neovim' +set -x VISUAL 'neovim' +set -x PAGER 'most' diff --git a/roles/fish/files/laptop.fish b/roles/fish/files/laptop.fish new file mode 100644 index 0000000..0d3e1fc --- /dev/null +++ b/roles/fish/files/laptop.fish @@ -0,0 +1,4 @@ +set -gx PATH $HOME/bin $PATH +set -x BROWSER 'google-chrome-stable' +set -x VAGRANT_DEFAULT_PROVIDER 'libvirt' +set -x XDG_CURRENT_DESKTOP 'i3-gaps' diff --git a/roles/fish/tasks/main.yml b/roles/fish/tasks/main.yml new file mode 100644 index 0000000..0ffd443 --- /dev/null +++ b/roles/fish/tasks/main.yml @@ -0,0 +1,46 @@ +--- +- name: Install fish + package: + name: fish + state: present + ignore_errors: True + become: yes + +- name: Install oh-my-fish + shell: curl -L https://get.oh-my.fish | fish + args: + creates: ~/.config/fish/conf.d/omf.fish + +- name: Install pureprompt plugin + shell: | + omf install pure + ln -s $OMF_PATH/themes/pure/conf.d/pure.fish ~/.config/fish/conf.d/pure.fish + ln -s $OMF_PATH/themes/pure/conf.d/_pure_init.fish ~/.config/fish/conf.d/pure_init.fish + args: + creates: ~/.config/fish/conf.d/pure.fish + +- name: check git plugin install + shell: grep git ~/.config/fish/fish_variables + register: gitcheck + ignore_errors: True + changed_when: false + +- name: Install git plugin + shell: omf install https://github.com/jhillyerd/plugin-git + when: gitcheck is failed + +- name: Globale fish configuration + copy: + src: config.fish + dest: ~/.config/fish/ + backup: yes + +- name: Laptops fish configuration + copy: + src: laptop.fish + dest: ~/.config/fish/conf.d/ + backup: yes + when: "'laptop' in {{ group_names }}" + +- debug: + msg: "Do not forget to 'chsh /usr/bin/fish'" diff --git a/roles/fzf/files/fzf.zsh b/roles/fzf/files/fzf.zsh deleted file mode 100644 index 5b9592f..0000000 --- a/roles/fzf/files/fzf.zsh +++ /dev/null @@ -1,14 +0,0 @@ -# Setup fzf -# --------- -if [[ ! "$PATH" == */home/user/.fzf/bin* ]]; then - export PATH="$PATH:/home/user/.fzf/bin" -fi - -# Auto-completion -# --------------- -[[ $- == *i* ]] && source "/home/user/.fzf/shell/completion.zsh" 2> /dev/null - -# Key bindings -# ------------ -source "/home/user/.fzf/shell/key-bindings.zsh" - diff --git a/roles/fzf/tasks/main.yml b/roles/fzf/tasks/main.yml deleted file mode 100644 index 4a29ca0..0000000 --- a/roles/fzf/tasks/main.yml +++ /dev/null @@ -1,10 +0,0 @@ ---- - -- name: clone fzf - git: - repo: https://github.com/junegunn/fzf.git - dest: ~/.fzf - depth: 1 - -- name: create config file - copy: src=files/fzf.zsh dest=~/.fzf.zsh diff --git a/roles/gtk/files/Trolltech.conf b/roles/gtk/files/Trolltech.conf index e148896..3910bc7 100644 --- a/roles/gtk/files/Trolltech.conf +++ b/roles/gtk/files/Trolltech.conf @@ -1,2 +1,25 @@ [Qt] style=GTK+ + +[Qt%20Plugin%20Cache%204.8.false] +usr\lib\qt4\plugins\inputmethods\libqimsw-multi.so=40807, 0, x86_64 linux g++-4 full-config, 2019-01-16T15:16:39 +usr\lib\qt4\plugins\imageformats\libqgif.so=40807, 0, x86_64 linux g++-4 full-config, 2019-01-16T15:16:39 +usr\lib\qt4\plugins\imageformats\libqico.so=40807, 0, x86_64 linux g++-4 full-config, 2019-01-16T15:16:39 +usr\lib\qt4\plugins\imageformats\libqjpeg.so=40807, 0, x86_64 linux g++-4 full-config, 2019-01-16T15:16:39 +usr\lib\qt4\plugins\imageformats\libqmng.so=40807, 0, x86_64 linux g++-4 full-config, 2019-01-16T15:16:39 +usr\lib\qt4\plugins\imageformats\libqsvg.so=40807, 0, x86_64 linux g++-4 full-config, 2019-01-16T15:16:39 +usr\lib\qt4\plugins\imageformats\libqtiff.so=40807, 0, x86_64 linux g++-4 full-config, 2019-01-16T15:16:39 +usr\lib\qt4\plugins\iconengines\libqsvgicon.so=40807, 0, x86_64 linux g++-4 full-config, 2019-01-16T15:16:39 +opt\teamviewer\tv_bin\RTlib\plugins\systemtrayicon\libsni-qt.so=40806, 1, i386 linux g++-4 full-config, 2018-01-06T13:04:51 + +[Qt%20Factory%20Cache%204.8] +com.trolltech.Qt.QInputContextFactoryInterface%3A\usr\lib\qt4\plugins\inputmethods\libqimsw-multi.so=2019-01-16T15:16:39, imsw-multi +com.trolltech.Qt.QImageIOHandlerFactoryInterface%3A\usr\lib\qt4\plugins\imageformats\libqgif.so=2019-01-16T15:16:39, gif +com.trolltech.Qt.QImageIOHandlerFactoryInterface%3A\usr\lib\qt4\plugins\imageformats\libqico.so=2019-01-16T15:16:39, ico +com.trolltech.Qt.QImageIOHandlerFactoryInterface%3A\usr\lib\qt4\plugins\imageformats\libqjpeg.so=2019-01-16T15:16:39, jpeg, jpg +com.trolltech.Qt.QImageIOHandlerFactoryInterface%3A\usr\lib\qt4\plugins\imageformats\libqmng.so=2019-01-16T15:16:39, mng +com.trolltech.Qt.QImageIOHandlerFactoryInterface%3A\usr\lib\qt4\plugins\imageformats\libqsvg.so=2019-01-16T15:16:39, svg, svgz +com.trolltech.Qt.QImageIOHandlerFactoryInterface%3A\usr\lib\qt4\plugins\imageformats\libqtiff.so=2019-01-16T15:16:39, tiff, tif +com.trolltech.Qt.QIconEngineFactoryInterfaceV2%3A\usr\lib\qt4\plugins\iconengines\libqsvgicon.so=2019-01-16T15:16:39, svg, svgz, svg.gz +com.trolltech.Qt.QIconEngineFactoryInterface%3A\usr\lib\qt4\plugins\iconengines\libqsvgicon.so=2019-01-16T15:16:39 +com.nokia.qt.QSystemTrayIconSysFactoryInterface%3A\opt\teamviewer\tv_bin\RTlib\plugins\systemtrayicon\libsni-qt.so=2018-01-06T13:04:51, default diff --git a/roles/cursor/files/cursor b/roles/gtk/files/cursor similarity index 100% rename from roles/cursor/files/cursor rename to roles/gtk/files/cursor diff --git a/roles/gtk/files/settings.ini b/roles/gtk/files/settings.ini index 04ebb17..2fdcca2 100644 --- a/roles/gtk/files/settings.ini +++ b/roles/gtk/files/settings.ini @@ -1,8 +1,8 @@ [Settings] -gtk-theme-name=Numix-DarkBlue -gtk-icon-theme-name=Vibrancy-Colors-Full-Dark +gtk-theme-name=Equilux +gtk-icon-theme-name=Paper-Mono-Dark gtk-font-name=Sans 10 -gtk-cursor-theme-name=Capitaine +gtk-cursor-theme-name=Adwaita gtk-cursor-theme-size=0 gtk-toolbar-style=GTK_TOOLBAR_BOTH gtk-toolbar-icon-size=GTK_ICON_SIZE_LARGE_TOOLBAR diff --git a/roles/gtk/tasks/main.yml b/roles/gtk/tasks/main.yml index 01e9822..27f7c13 100644 --- a/roles/gtk/tasks/main.yml +++ b/roles/gtk/tasks/main.yml @@ -1,21 +1,54 @@ --- -- name: Install Numix Theme - aur: name={{item}} use=makepkg - with_items: - - numix-themes-darkblue - - vibrancy-colors +- name: Install Themes and Icons + aur: + name: + - equilux-theme + - paper-icon-theme + skip_installed: yes - name: Create gtk conf dir - file: path=~/.config/gtk-3.0/ state=directory + file: + path: ~/.config/gtk-3.0/ + state: directory - name: Configure GTK - copy: src=files/settings.ini dest=~/.config/gtk-3.0/settings.ini backup=yes + copy: + src: settings.ini + dest: ~/.config/gtk-3.0/ + backup: yes - name: Configure Qt as GTK theme - copy: src=files/Trolltech.conf dest=~/.config/Trolltech.conf backup=yes + copy: + src: Trolltech.conf + dest: ~/.config/ + backup: yes - name: Update font cache - shell: creates=.Xdefaults fc-cache -f + shell: fc-cache -f + args: + creates: .Xdefaults + changed_when: false - name: Link Xdefaults - file: src=~/.Xresources dest=~/.Xdefaults state=link force=yes + file: + src: ~/.Xresources + dest: ~/.Xdefaults + state: link + force: yes + +- name: Create .Xresources.d dir + file: + path: ~/.Xresources.d + state: directory + +- name: Configure Cursors + copy: + src: cursor + dest: ~/.Xresources.d/ + +- name: Init Cursors in .Xresources + lineinfile: + path: ~/.Xresources + create: yes + state: present + line: '#include ".Xresources.d/cursor"' diff --git a/roles/i3-wm/tasks/main.yml b/roles/i3-wm/tasks/main.yml index 2a47202..cbc25f4 100644 --- a/roles/i3-wm/tasks/main.yml +++ b/roles/i3-wm/tasks/main.yml @@ -1,32 +1,37 @@ --- - name: Install i3-wm - aur: name={{item}} use=makepkg - with_items: - - i3-gaps - - i3lock + aur: + name: + - i3-gaps + - i3lock + skip_installed: yes - name: Clone i3lock-fancy-multimonitor git: repo: https://github.com/guimeira/i3lock-fancy-multimonitor dest: ~/.i3/i3lock-fancy-multimonitor - force: yes + update: no - name: Configure i3lock blur lineinfile: path: ~/.i3/i3lock-fancy-multimonitor/lock regexp: '^BLURTYPE="2x8"' line: '#BLURTYPE="2x8"' - ignore_errors: True - name: Configure i3lock blur bis lineinfile: path: ~/.i3/i3lock-fancy-multimonitor/lock regexp: '^#BLURTYPE="5x3"' line: 'BLURTYPE="5x3"' - ignore_errors: True - name: Configure xinitrc - copy: src=files/xinitrc dest=~/.xinitrc backup=yes + copy: + src: xinitrc + dest: ~/.xinitrc + backup: yes - name: Template config file - template: src=templates/config.j2 dest=~/.i3/config backup=yes + template: + src: config.j2 + dest: ~/.i3/config + backup: yes diff --git a/roles/i3-wm/templates/by_host/osz/config.j2 b/roles/i3-wm/templates/by_host/osz/config.j2 index 5b36258..2908730 100644 --- a/roles/i3-wm/templates/by_host/osz/config.j2 +++ b/roles/i3-wm/templates/by_host/osz/config.j2 @@ -1,22 +1,4 @@ -#assign osz -assign [class="Google-chrome"] $tag1 -assign [class="Thunderbird"] $tag3 -assign [class="Lollypop"] $tag5 -for_window [class="Lollypop"] focus -assign [class="Code"] $tag6 -for_window [class="Code"] focus -assign [class="WebTorrent"] $tag7 -for_window [class="WebTorrent"] focus -assign [class="Nicotine"] $tag9 -for_window [class="Nicotine"] focus - -#bindsym osz -bindsym $mod+Control+Left exec ~/dev/git/mpris-ctrl/mpris-ctrl.sh Lollypop prev -bindsym $mod+Control+Down exec ~/dev/git/mpris-ctrl/mpris-ctrl.sh Lollypop play-pause -bindsym $mod+Control+Right exec ~/dev/git/mpris-ctrl/mpris-ctrl.sh Lollypop next -bindsym $mod+Control+Prior exec "cd ~/dev/git/interfaceliftdownloader/ ; ./interfacelift.sh -c ./wallpaper.conf" -bindsym $mod+Control+Next exec "~/dev/git/interfaceliftdownloader/interfacelift.sh -sc ~/dev/git/interfaceliftdownloader/wallpaper.conf" - +#INCLUDE#################################################### #assign workspace to screens workspace $tag1 output DP-1-1 workspace $tag2 output eDP-1 @@ -30,7 +12,8 @@ workspace $tag9 output eDP-1 workspace $tag10 output eDP-1 # exec startup apps -exec --no-startup-id i3-msg 'exec thunderbird' exec --no-startup-id i3-msg 'exec google-chrome-stable' +exec --no-startup-id i3-msg 'exec google-chrome-stable --app="https://gmail.com"' exec --no-startup-id i3-msg 'workspace $tag4; exec termite -e "screen -rd weechat &"' exec --no-startup-id i3-msg 'workspace $tag2; exec termite' +#INCLUDE#################################################### diff --git a/roles/i3-wm/templates/by_host/work/config.j2 b/roles/i3-wm/templates/by_host/work/config.j2 index 343c950..f0f76b0 100644 --- a/roles/i3-wm/templates/by_host/work/config.j2 +++ b/roles/i3-wm/templates/by_host/work/config.j2 @@ -1,37 +1,15 @@ -#assign work -assign [class="Google-chrome"] $tag1 -assign [class="Thunderbird"] $tag3 -assign [class="Code"] $tag6 -for_window [class="Code"] focus -assign [class="Virt-manager"] $tag8 -for_window [class="Virt-manager"] focus -assign [class="VirtualBox"] $tag8 -for_window [class="VirtualBox"] focus -assign [class="Connman-gtk"] $tag10 -for_window [class="Connman-gtk"] focus - -#class confs -for_window [class="Cssh"] floating enable, border normal -for_window [class="XTerm"] floating enable, border normal -for_window [class="feh"] floating enable, border normal -for_window [class="Wine"] move to workspace $tag6 -for_window [class="Pidgin"] move to workspace $tag5 -for_window [class="retroarch"] move to scratchpad - -#bindsym work -bindsym $mod+Control+Prior exec "cd ~/dev/git/interfaceliftdownloader/ ; ./interfacelift.sh -c ./wallpaper.conf" -bindsym $mod+Control+Next exec "~/dev/git/interfaceliftdownloader/interfacelift.sh -sc ~/dev/git/interfaceliftdownloader/wallpaper.conf" - +#INCLUDE#################################################### #assign workspace to screens -workspace $tag1 output HDMI-1 -workspace $tag2 output HDMI-2 -workspace $tag3 output HDMI-2 -workspace $tag4 output HDMI-2 -workspace $tag5 output HDMI-2 +workspace $tag1 output HDMI2 HDMI3 +workspace $tag2 output HDMI3 +workspace $tag3 output HDMI1 +workspace $tag4 output HDMI1 +workspace $tag5 output HDMI3 # exec startup apps - -exec --no-startup-id i3-msg 'exec thunderbird' +exec --no-startup-id i3-msg 'exec google-chrome-stable --app=http://mail.umontpellier.fr &' +exec --no-startup-id i3-msg 'exec google-chrome-stable --app=https://gmail.com &' exec --no-startup-id i3-msg 'exec google-chrome-stable &' exec --no-startup-id i3-msg 'workspace $tag4; exec termite -e "screen -rd weechat &"' exec --no-startup-id i3-msg 'workspace $tag2; exec termite' +#INCLUDE#################################################### diff --git a/roles/i3-wm/templates/config.j2 b/roles/i3-wm/templates/config.j2 index 00f00c6..88ac7f8 100644 --- a/roles/i3-wm/templates/config.j2 +++ b/roles/i3-wm/templates/config.j2 @@ -17,7 +17,7 @@ bindsym $mod+Return exec termite # start drofi dmenu bindsym $mod+Tab exec --no-startup-id rofi -show window bindsym $mod+Shift+d exec --no-startup-id rofi -show run -bindsym $mod+d exec --no-startup-id rofi -show drun +bindsym $mod+d exec --no-startup-id rofi -modi drun -show drun # Use Mouse+$mod to drag floating windows to their wanted position floating_modifier $mod @@ -96,9 +96,9 @@ set $tag10 "10:" #colors # class border backgr. text indicator child_border -client.focused #FFFFFF #FFFFFF #000000 #000000 #000000 -client.focused_inactive #333333 #5f676a #ffffff #484e50 #000000 -client.unfocused #333333 #222222 #888888 #292d2e #222222 +client.focused #222222 #5A5A5A #E1E1E1 #000000 #000000 +client.focused_inactive #222222 #5A5A5A #E1E1E1 #484e50 #000000 +client.unfocused #222222 #323232 #888888 #292d2e #222222 client.urgent #2f343a #900000 #ffffff #900000 #900000 client.placeholder #000000 #0c0c0c #ffffff #000000 #0c0c0c @@ -115,15 +115,7 @@ bindsym $mod+Shift+q exec ~/.config/rofi/powermenu.sh # apps bindsym $mod+Control+t exec thunar bindsym $mod+Control+n exec connman-gtk - -# by class -## floatings -for_window [class="XTerm"] floating enable, border normal -for_window [class="feh"] floating enable, border normal - -# assigns focus -assign [class="Connman-gtk"] $tag10 -for_window [class="Connman-gtk"] focus +bindsym $mod+Control+p exec pavucontrol #toggle workspace's display screen bindsym $mod+less move workspace to output right @@ -153,6 +145,28 @@ bindsym $mod+Shift+underscore move container to workspace $tag8 bindsym $mod+Shift+ccedilla move container to workspace $tag9 bindsym $mod+Shift+agrave move container to workspace $tag10 +# floatings +for_window [class="XTerm"] floating enable, border normal +for_window [class="feh"] floating enable, border normal +for_window [class="Gpick"] floating enable, border pixel 1 +for_window [title="Images de Variety"] floating enable, border pixel 1, move left 647px + +# assigns focus +assign [class="Connman-gtk"] $tag10 +for_window [class="Connman-gtk"] focus +assign [class="Transmission-gtk"] $tag9 +assign [title=".*mail.*"] $tag3 +assign [class="Google-chrome"] $tag1 +assign [class="spotify"] $tag5 +for_window [class="spotify"] focus +assign [class="Code"] $tag6 +for_window [class="Code"] focus + +#bindsym spotify +bindsym $mod+Control+Left exec ~/dev/git/mpris-ctrl/mpris-ctrl.sh spotify prev +bindsym $mod+Control+Down exec ~/dev/git/mpris-ctrl/mpris-ctrl.sh spotify play-pause +bindsym $mod+Control+Right exec ~/dev/git/mpris-ctrl/mpris-ctrl.sh spotify next + {% include 'by_host/' + ansible_hostname + '/config.j2' ignore missing %} {% include 'by_os/' + ansible_distribution|lower + '/config.j2' ignore missing %} diff --git a/roles/neofetch/tasks/main.yml b/roles/neofetch/tasks/main.yml index 96bc7ce..b785165 100644 --- a/roles/neofetch/tasks/main.yml +++ b/roles/neofetch/tasks/main.yml @@ -1,15 +1,22 @@ --- - name: Install neofetch - aur: name={{item}} use=makepkg - with_items: - - w3m - - neofetch + aur: + name: + - w3m + - neofetch + skip_installed: yes - name: creates neofetch conf dir - file: path=~/.config/neofetch state=directory + file: + path: ~/.config/neofetch + state: directory - name: Configure neofetch - copy: src=files/config.conf dest=~/.config/neofetch/config.conf + copy: + src: config.conf + dest: ~/.config/neofetch/ - name: Copy neofetch archlinux img - copy: src=files/archlinux.png dest=~/.config/neofetch/archlinux.png + copy: + src: archlinux.png + dest: ~/.config/neofetch/ diff --git a/roles/neovim/files/init.vim b/roles/neovim/files/init.vim new file mode 100644 index 0000000..df95692 --- /dev/null +++ b/roles/neovim/files/init.vim @@ -0,0 +1,29 @@ +" Plugins will be downloaded under the specified directory. +call plug#begin('~/.vim/plugged') + +" Declare the list of plugins. +Plug 'tpope/vim-sensible' +Plug 'vim-airline/vim-airline' +Plug 'vim-airline/vim-airline-themes' + +" List ends here. Plugins become visible to Vim after this call. +call plug#end() + +" Configure autoindent +set tabstop=4 softtabstop=2 expandtab shiftwidth=2 autoindent + +" remember last cursor place +au BufReadPost * if line("'\"") > 0|if line("'\"") <= line("$")|exe("norm '\"")|else|exe "norm $"|endif|endif + +" Configure Airline +let g:airline_powerline_fonts = 1 +if !exists('g:airline_symbols') + let g:airline_symbols = {} +endif +let g:airline_symbols.space = "\ua0" +let g:airline#extensions#tabline#enabled = 1 +let g:airline#extensions#tabline#show_buffers = 0 +let g:airline_theme = 'minimalist' + +" Default term cursor +set guicursor= diff --git a/roles/neovim/tasks/main.yml b/roles/neovim/tasks/main.yml new file mode 100644 index 0000000..34b413b --- /dev/null +++ b/roles/neovim/tasks/main.yml @@ -0,0 +1,12 @@ +--- +- name: Install neovim + package: + name: neovim + state: present + become: True + +- name: Copy neovim conf file + copy: + src: init.vim + dest: ~/.config/nvim/ + notify: trigger plug install diff --git a/roles/packages-common/tasks/by_os/archlinux/main.yml b/roles/packages-common/tasks/by_os/archlinux/main.yml deleted file mode 100644 index 19287c2..0000000 --- a/roles/packages-common/tasks/by_os/archlinux/main.yml +++ /dev/null @@ -1,9 +0,0 @@ ---- -- name: Install common packages [Archlinux] - pacman: - state: present - name: - - expac - - jshon - - pygmentize - become: True diff --git a/roles/packages-common/tasks/by_os/centos/main.yml b/roles/packages-common/tasks/by_os/centos/main.yml index 540e731..884033e 100644 --- a/roles/packages-common/tasks/by_os/centos/main.yml +++ b/roles/packages-common/tasks/by_os/centos/main.yml @@ -1,8 +1,12 @@ --- - name: Add EPEL repository - yum: name=epel-release state=present + yum: + name: epel-release + state: present become: True - name: Install pip package - yum: name=python-pip state=present + yum: + name: python-pip + state: present become: True diff --git a/roles/packages-common/tasks/main.yml b/roles/packages-common/tasks/main.yml index ed0c1fc..ef20d1f 100644 --- a/roles/packages-common/tasks/main.yml +++ b/roles/packages-common/tasks/main.yml @@ -1,13 +1,17 @@ --- - name: Install common packages - package: name={{item}} state=present - with_items: - - curl - - wget - become: True + package: + name: + - curl + - wget + - jq + - most + - fzf + state: present - name: Test host packages file - stat: path="{{ role_path }}/tasks/by_host/{{ ansible_hostname }}/main.yml" + stat: + path: "{{ role_path }}/tasks/by_host/{{ ansible_hostname }}/main.yml" register: host_file - name: Include host packages @@ -15,7 +19,8 @@ when: host_file.stat.exists - name: Test distribution packages file - stat: path="{{ role_path }}/tasks/by_os/{{ ansible_distribution|lower }}/main.yml" + stat: + path: "{{ role_path }}/tasks/by_os/{{ ansible_distribution|lower }}/main.yml" register: distribution_file - name: Include distribution packages diff --git a/roles/packages-desktop/handlers/main.yml b/roles/packages-desktop/handlers/main.yml deleted file mode 100644 index 82e8c2d..0000000 --- a/roles/packages-desktop/handlers/main.yml +++ /dev/null @@ -1,2 +0,0 @@ -- name: clean tmp packer - shell: rm -Rf /tmp/packer* diff --git a/roles/packages-desktop/tasks/by_host/arch-itect/main.yml b/roles/packages-desktop/tasks/by_host/arch-itect/main.yml deleted file mode 100644 index 35353d2..0000000 --- a/roles/packages-desktop/tasks/by_host/arch-itect/main.yml +++ /dev/null @@ -1,4 +0,0 @@ ---- -- name: Install arch-itect packages - pacman: name=thunderbird state=present - become: True diff --git a/roles/packages-desktop/tasks/by_host/osz/main.yml b/roles/packages-desktop/tasks/by_host/osz/main.yml deleted file mode 100644 index 580f4b1..0000000 --- a/roles/packages-desktop/tasks/by_host/osz/main.yml +++ /dev/null @@ -1,4 +0,0 @@ ---- -- name: Install osz packages - pacman: name=geary state=present - become: True diff --git a/roles/packages-desktop/tasks/by_os/archlinux/main.yml b/roles/packages-desktop/tasks/by_os/archlinux/main.yml index a19c5f3..d3df26e 100644 --- a/roles/packages-desktop/tasks/by_os/archlinux/main.yml +++ b/roles/packages-desktop/tasks/by_os/archlinux/main.yml @@ -1,17 +1,12 @@ --- -- name: add unifont gpg missing key - shell: gpg --recv-keys 1A09227B1F435A33 - -- name: Install Desktop packages [Archlinux] - aur: name={{item}} use=makepkg - with_items: - - google-chrome - - connman-gtk - - gnome-ssh-askpass2 - - ttf-font-awesome-4 - - ttf-unifont - - ttf-font-icons - notify: clean tmp packer - -- name: Flush handlers to clean /tmp - meta: flush_handlers +- name: Install Desktop aur packages [Archlinux] + aur: + name: + - trizen + - google-chrome + - connman-gtk + - gnome-ssh-askpass2 + - ttf-font-awesome-4 + - ttf-unifont + - ttf-font-icons + skip_installed: yes diff --git a/roles/packages-desktop/tasks/main.yml b/roles/packages-desktop/tasks/main.yml index 39069ba..00d6987 100644 --- a/roles/packages-desktop/tasks/main.yml +++ b/roles/packages-desktop/tasks/main.yml @@ -1,22 +1,22 @@ --- - name: Install Desktop packages - package: name={{item}} state=present - with_items: - - xorg-server - - xorg-xinit - - lxappearance - - slop - - maim - - feh - - xclip - - xorg-xrdb - - xorg-xfd - - connman - - ttf-hack + package: + name: + - xorg-server + - xorg-xinit + - lxappearance + - feh + - xclip + - xorg-xrdb + - xorg-xfd + - connman + - ttf-hack + state: present become: True - name: Test host packages file - stat: path="{{ role_path }}/tasks/by_host/{{ ansible_hostname }}/main.yml" + stat: + path: "{{ role_path }}/tasks/by_host/{{ ansible_hostname }}/main.yml" register: host_file - name: Include distribution packages @@ -24,7 +24,8 @@ when: host_file.stat.exists - name: Test distribution packages file - stat: path="{{ role_path }}/tasks/by_os/{{ ansible_distribution|lower }}/main.yml" + stat: + path: "{{ role_path }}/tasks/by_os/{{ ansible_distribution|lower }}/main.yml" register: distribution_file - name: Include distribution packages diff --git a/roles/packages-laptop/tasks/main.yml b/roles/packages-laptop/tasks/main.yml index ff62336..2be6439 100644 --- a/roles/packages-laptop/tasks/main.yml +++ b/roles/packages-laptop/tasks/main.yml @@ -1,4 +1,6 @@ --- - name: Install backlight controller package - aur: name=light-git use=makepkg + aur: + name: light-git + skip_installed: yes when: ansible_os_family == "Archlinux" diff --git a/roles/compton/files/compton b/roles/picom/files/picom similarity index 93% rename from roles/compton/files/compton rename to roles/picom/files/picom index e276205..c176a3f 100644 --- a/roles/compton/files/compton +++ b/roles/picom/files/picom @@ -1,7 +1,7 @@ # Shadow shadow = false; -no-dnd-shadow = true; -no-dock-shadow = true; +# no-dnd-shadow = true; +# no-dock-shadow = true; clear-shadow = true; shadow-radius = 7; shadow-offset-x = -7; @@ -15,7 +15,9 @@ shadow-exclude = [ "class_g = 'Conky'", "class_g ?= 'Notify-osd'", "class_g = 'Cairo-clock'", - "_GTK_FRAME_EXTENTS@:c" + "_GTK_FRAME_EXTENTS@:c", + "name = 'jgmenu'", + "class_g = 'jgmenu'" ]; # shadow-exclude = "n:e:Notification"; # shadow-exclude-reg = "x10+0+0"; @@ -32,7 +34,7 @@ alpha-step = 0.06; # inactive-dim-fixed = true; # blur-background = true; # blur-background-frame = true; -blur-kern = "3x3box" +# blur-kern = "3x3box" # blur-kern = "5,5,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1" # blur-background-fixed = true; blur-background-exclude = [ diff --git a/roles/picom/files/picom.sh b/roles/picom/files/picom.sh new file mode 100644 index 0000000..ce6dbca --- /dev/null +++ b/roles/picom/files/picom.sh @@ -0,0 +1 @@ +picom --backend glx --vsync -GCb --config ~/.picom & diff --git a/roles/picom/files/picom.vagrant.sh b/roles/picom/files/picom.vagrant.sh new file mode 100644 index 0000000..8d3d8e2 --- /dev/null +++ b/roles/picom/files/picom.vagrant.sh @@ -0,0 +1 @@ +picom --config ~/.picom & diff --git a/roles/picom/tasks/main.yml b/roles/picom/tasks/main.yml new file mode 100644 index 0000000..dd3512b --- /dev/null +++ b/roles/picom/tasks/main.yml @@ -0,0 +1,22 @@ +--- +- name: Install compton + package: + name: picom + +- name: Configure picom + copy: + src: picom + dest: ~/.picom + backup: yes + +- name: Init compton in .xprofile + copy: + src: picom.sh + dest: ~/.xprofile.d/ + when: ansible_user_id != "vagrant" + +- name: Init compton in .xprofile [Vagrant] + copy: + src: picom.vagrant.sh + dest: ~/.xprofile.d/ + when: ansible_user_id == "vagrant" diff --git a/roles/polybar/README.md b/roles/polybar/README.md index 0c29b3e..fc60e05 100644 --- a/roles/polybar/README.md +++ b/roles/polybar/README.md @@ -3,7 +3,11 @@ - \~/.config/polybar/launch.sh - \~/.config/polybar/pkg.sh -# Dualscreen configuration +# Managed dirs +- \~/.config/polybar/modules +- \~/.config/polybar/bars + +# Dualscreen configuration by host Add a dir named as hostname to include specific host configuration for multiple screen launch ``` mkdir templates/$(hostname) @@ -13,51 +17,3 @@ MONITOR=HDMI2 polybar top & MONITOR=HDMI2 polybar bottom & EOF ``` - -It will uncomment monitor values in config.j2 too - -# Modules configuration by host -``` -mkdir templates/by_host/$(hostname) -# Top modules configuration -echo <<\EOF > templates/$(hostname)/modules-top.j2 -modules-left = i3 xwindow -modules-center = -modules-right = backlight volume pkg wlan vpncheck battery date -EOF - -# Bottom modules configuration -echo <<\EOF > templates/by_host/$(hostname)/modules-bottom.j2 -modules-left = -modules-center = networkspeedup networkspeeddown -modules-right = temperature filesystem-slash filesystem-home cpu memory -EOF -``` - -# Modules definition - -## By host - -``` -echo <<\EOF > templates/by_host/$(hostname)/modules-def.j2 -[module/example] -type = custom/script -interval = 1200 -format =