Add option to install shell extensions for multiple users
This commit is contained in:
@@ -231,10 +231,6 @@ rpm_ostree_layered_packages:
|
||||
zsh:
|
||||
state: present
|
||||
|
||||
etc_users:
|
||||
flexo:
|
||||
shell: /bin/zsh
|
||||
|
||||
etc_firewalld:
|
||||
syncthing:
|
||||
zone: FedoraWorkstation
|
||||
@@ -248,7 +244,11 @@ etc_sysctl_params:
|
||||
value: 524288
|
||||
state: present
|
||||
|
||||
home_users:
|
||||
users:
|
||||
flexo:
|
||||
shell: /bin/zsh
|
||||
dotfiles: git@git.spa5.dev:flexo/dotfiles
|
||||
update: no
|
||||
|
||||
home_gnome_shell_extensions:
|
||||
'https://github.com/ubuntu/gnome-shell-extension-appindicator':
|
||||
extension_uuid: 'appindicatorsupport@rgcjonas.gmail.com'
|
||||
@@ -4,4 +4,4 @@
|
||||
name: "{{ item.key }}"
|
||||
shell: "{{ item.value.shell }}"
|
||||
become: yes
|
||||
loop: "{{ lookup('dict', etc_users, wantlist=True) }}"
|
||||
loop: "{{ lookup('dict', users, wantlist=True) }}"
|
||||
|
||||
3
roles/home/defaults/main.yml
Normal file
3
roles/home/defaults/main.yml
Normal file
@@ -0,0 +1,3 @@
|
||||
---
|
||||
home_place_dotfiles: false
|
||||
home_configure_gnome: true
|
||||
7
roles/home/handlers/main.yml
Normal file
7
roles/home/handlers/main.yml
Normal file
@@ -0,0 +1,7 @@
|
||||
---
|
||||
- name: Compile glib schemas
|
||||
ansible.builtin.command:
|
||||
cmd: "glib-compile-schemas /home/{{ item[0] }}/.local/share/gnome-shell/extensions/{{ item[1].value.extension_uuid }}/schemas"
|
||||
with_nested:
|
||||
- "{{ users }}"
|
||||
- "{{ home_gnome_shell_extensions | dict2items }}"
|
||||
@@ -0,0 +1,9 @@
|
||||
---
|
||||
- name: Install GNOME Shell Extensions
|
||||
ansible.builtin.git:
|
||||
repo: "{{ item[1].key }}"
|
||||
dest: "/home/{{ item[0] }}/.local/share/gnome-shell/extensions/{{ item[1].value.extension_uuid }}"
|
||||
with_nested:
|
||||
- "{{ users }}"
|
||||
- "{{ home_gnome_shell_extensions | dict2items }}"
|
||||
notify: Compile glib schemas
|
||||
@@ -2,3 +2,7 @@
|
||||
- name: Include dotfiles.yml
|
||||
ansible.builtin.include: dotfiles.yml
|
||||
when: home_place_dotfiles | bool
|
||||
|
||||
- name: Include gnome.yml
|
||||
ansible.builtin.include: gnome.yml
|
||||
when: home_configure_gnome | bool
|
||||
Reference in New Issue
Block a user