Set the owner of Git repos on Windows
The `win_git` module clones repos as the current user, which since its an admin login is the admin. This patch adjusts the `win_owner` to so that repos are owned by the correct user when being used in a non-admin capacity.
This commit is contained in:
@@ -1,9 +1,16 @@
|
||||
---
|
||||
- set_fact:
|
||||
powershell_config_dir:
|
||||
'{{ansible_env.USERPROFILE}}/Documents/WindowsPowerShell'
|
||||
|
||||
- name: clone config repos
|
||||
win_git:
|
||||
repo: git@code.infektor.net:config/WindowsPowerShell.git
|
||||
dest: '{{ansible_env.USERPROFILE}}/Documents/WindowsPowerShell'
|
||||
dest: '{{powershell_config_dir}}'
|
||||
branch: master
|
||||
- win_owner:
|
||||
path: '{{powershell_config_dir}}'
|
||||
user: Benie
|
||||
|
||||
- name: install chocolatey package
|
||||
win_chocolatey:
|
||||
@@ -28,3 +35,9 @@
|
||||
name: PsReadline
|
||||
state: latest
|
||||
accept_license: true
|
||||
|
||||
- name: install posh-git module
|
||||
win_psmodule:
|
||||
name: posh-git
|
||||
state: latest
|
||||
accept_license: true
|
||||
|
||||
Reference in New Issue
Block a user