Move Zed config to Ansible template with 1Password secrets
This commit is contained in:
20
ansible/tasks/workstations/zed.yml
Normal file
20
ansible/tasks/workstations/zed.yml
Normal file
@@ -0,0 +1,20 @@
|
||||
---
|
||||
- name: Zed Configuration
|
||||
block:
|
||||
- name: Set user home directory
|
||||
ansible.builtin.set_fact:
|
||||
user_home: "{{ ansible_env.HOME if ansible_user_id == 'root' else lookup('env', 'HOME') }}"
|
||||
|
||||
- name: Ensure Zed config directory exists
|
||||
ansible.builtin.file:
|
||||
path: "{{ user_home }}/.config/zed"
|
||||
state: directory
|
||||
mode: "0755"
|
||||
|
||||
- name: Template Zed settings with 1Password secrets
|
||||
ansible.builtin.template:
|
||||
src: zed.jsonc.j2
|
||||
dest: "{{ user_home }}/.config/zed/settings.json"
|
||||
mode: "0644"
|
||||
tags:
|
||||
- zed
|
||||
Reference in New Issue
Block a user