diff options
author | Egor Tensin <Egor.Tensin@gmail.com> | 2023-01-25 14:40:44 +0100 |
---|---|---|
committer | Egor Tensin <Egor.Tensin@gmail.com> | 2023-01-25 14:40:44 +0100 |
commit | b02a8c40c76cb2e61c7a664ec156407101201a24 (patch) | |
tree | 0e046b783331db1bbba78bee75dbdac2e67e420a /roles/etckeeper/tasks | |
parent | linting (diff) | |
download | maintenance-b02a8c40c76cb2e61c7a664ec156407101201a24.tar.gz maintenance-b02a8c40c76cb2e61c7a664ec156407101201a24.zip |
move tool existence conditionals to role common
Diffstat (limited to '')
-rw-r--r-- | roles/etckeeper/tasks/main.yml | 31 |
1 files changed, 12 insertions, 19 deletions
diff --git a/roles/etckeeper/tasks/main.yml b/roles/etckeeper/tasks/main.yml index 3e37ed1..0339c61 100644 --- a/roles/etckeeper/tasks/main.yml +++ b/roles/etckeeper/tasks/main.yml @@ -1,22 +1,15 @@ - become: true block: - - name: Check if /etc is versioned - stat: - path: /etc/.git/config - register: etc_versioned + - name: Set user.name + community.general.git_config: + scope: local + repo: /etc + name: user.name + value: '{{ git_name }}' - - when: etc_versioned - block: - - name: Set user.name - community.general.git_config: - scope: local - repo: /etc - name: user.name - value: '{{ git_name }}' - - - name: Set user.email - community.general.git_config: - scope: local - repo: /etc - name: user.email - value: '{{ git_email }}' + - name: Set user.email + community.general.git_config: + scope: local + repo: /etc + name: user.email + value: '{{ git_email }}' |