Cambio paradigma: cartelle configurazioni linkate.

This commit is contained in:
Emiliano Vavassori 2024-12-26 00:23:39 +01:00
parent 795f2192be
commit 38bff506f7
4 changed files with 14 additions and 10 deletions

View File

@ -1,4 +1,5 @@
--- ---
additional_user: syntaxerrormmm additional_user: syntaxerrormmm
dotfdir: "{{ lookup('ansible.builtin.env', 'HOME') }}/.dotfiles" dotfdir: "{{ lookup('ansible.builtin.env', 'HOME') }}/.dotfiles"
kitty_configdir: "{{ lookup('ansible.builtin.env', 'HOME') }}/.config/kitty" userconfigdir: "{{ lookup('ansible.builtin.env', 'HOME') }}/.config"
kitty_configdir: "{{ userconfigdir }}/kitty"

View File

@ -3,10 +3,11 @@
- name: Create configuration directory - name: Create configuration directory
ansible.builtin.file: ansible.builtin.file:
path: "{{ kitty_configdir }}" path: "{{ userconfigdir }}"
state: directory state: directory
- name: Linking configuration - name: Linking configuration
ansible.builtin.copy: ansible.builtin.file:
src: "{{ dotfdir }}/kitty/kitty.conf" src: "{{ dotfdir }}/kitty"
dest: "{{ kitty_configdir }}/kitty.conf" dest: "{{ kitty_configdir }}"
state: link

View File

@ -1,4 +1,5 @@
--- ---
additional_user: syntaxerrormmm additional_user: syntaxerrormmm
dotfdir: "{{ lookup('ansible.builtin.env', 'HOME') }}/.dotfiles" dotfdir: "{{ lookup('ansible.builtin.env', 'HOME') }}/.dotfiles"
nix_configdir: "{{ lookup('ansible.builtin.env', 'HOME') }}/.config/nix" userconfigdir: "{{ lookup('ansible.builtin.env', 'HOME') }}/.config"
nix_configdir: "{{ userconfigdir }}/nix"

View File

@ -3,10 +3,11 @@
- name: Create configuration directory - name: Create configuration directory
ansible.builtin.file: ansible.builtin.file:
path: "{{ nix_configdir }}" path: "{{ userconfigdir }}"
state: directory state: directory
- name: Linking configuration - name: Linking configuration
ansible.builtin.copy: ansible.builtin.file:
src: "{{ dotfdir }}/nix/nix.conf" src: "{{ dotfdir }}/nix"
dest: "{{ nix_configdir }}/nix.conf" dest: "{{ nix_configdir }}"
state: link