fix ansible conf
This commit is contained in:
@ -67,4 +67,4 @@ aur_packages:
|
|||||||
- pgformatter-git
|
- pgformatter-git
|
||||||
# - jetbrains-toolbox
|
# - jetbrains-toolbox
|
||||||
|
|
||||||
config_dir: "{{ ansible_facts.env.HOME }}/.config"
|
config_dir: "/home/johannes/.config"
|
||||||
|
|||||||
14
playbook.yml
14
playbook.yml
@ -8,13 +8,13 @@
|
|||||||
# roles:
|
# roles:
|
||||||
# - zsh
|
# - zsh
|
||||||
|
|
||||||
pre_tasks:
|
# pre_tasks:
|
||||||
- name: Create btrfs snapshot before changes
|
# - name: Create btrfs snapshot before changes
|
||||||
shell: |
|
# shell: |
|
||||||
sudo btrfs subvolume snapshot / /.snapshots/before-dotfiles-$(date +%Y%m%d-%H%M%S)
|
# btrfs subvolume snapshot / /.snapshots/before-dotfiles-$(date +%Y%m%d-%H%M%S)
|
||||||
tags: [snapshot]
|
# tags: [snapshot]
|
||||||
become: true
|
# become: true
|
||||||
become_method: sudo
|
# become_method: sudo
|
||||||
|
|
||||||
tasks:
|
tasks:
|
||||||
- name: Install enabled roles
|
- name: Install enabled roles
|
||||||
|
|||||||
@ -1,8 +1,40 @@
|
|||||||
---
|
---
|
||||||
- name: Symlink hyprland
|
- name: Check if hypr path is a symlink
|
||||||
|
stat:
|
||||||
|
path: "{{ config_dir }}/hypr"
|
||||||
|
register: hypr_stat
|
||||||
|
|
||||||
|
- name: Remove existing hypr symlink if present
|
||||||
file:
|
file:
|
||||||
src: "{{ role_path }}/files/hypr"
|
path: "{{ config_dir }}/hypr"
|
||||||
dest: "{{ config_dir }}/hypr"
|
state: absent
|
||||||
|
when: hypr_stat.stat.exists and hypr_stat.stat.islnk
|
||||||
|
|
||||||
|
- name: Create hypr config directory
|
||||||
|
file:
|
||||||
|
path: "{{ config_dir }}/hypr"
|
||||||
|
state: directory
|
||||||
|
mode: '0755'
|
||||||
|
owner: johannes
|
||||||
|
group: johannes
|
||||||
|
|
||||||
|
- name: Symlink hyprland config files
|
||||||
|
file:
|
||||||
|
src: "{{ role_path }}/files/hypr/{{ item }}"
|
||||||
|
dest: "{{ config_dir }}/hypr/{{ item }}"
|
||||||
|
state: link
|
||||||
|
force: true
|
||||||
|
loop:
|
||||||
|
- hyprland.conf
|
||||||
|
- hyprlock.conf
|
||||||
|
- hyprpaper.conf
|
||||||
|
- workspaces.conf
|
||||||
|
- scripts
|
||||||
|
|
||||||
|
- name: Symlink host-specific monitors.conf
|
||||||
|
file:
|
||||||
|
src: "{{ role_path }}/files/hypr/monitors_{{ ansible_hostname }}.conf"
|
||||||
|
dest: "{{ config_dir }}/hypr/monitors.conf"
|
||||||
state: link
|
state: link
|
||||||
force: true
|
force: true
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user