diff --git a/roles/home-cli/files/gitconfig b/roles/home-cli/files/gitconfig deleted file mode 100644 index 98743d5..0000000 --- a/roles/home-cli/files/gitconfig +++ /dev/null @@ -1,26 +0,0 @@ -[pull] - rebase = true -[push] - default = simple -[color] - ui = auto -[credential] - helper = store -[alias] - ci = commit - co = checkout - ff = merge --ff-only - graph = log --graph --oneline --all - l1 = log --pretty=oneline - last = log -1 HEAD --pretty=fuller - unstage = reset HEAD -- - up = pull --rebase -[gui] - encoding = utf-8 - recentrepo = /home/acp/data/he - -[guitool "Rebase"] - cmd = rebase -[user] - name = Anthony Perkins - email = anthony@acperkins.com diff --git a/roles/home-cli/tasks/dotfiles.yml b/roles/home-cli/tasks/dotfiles.yml index e1c7a69..e4d074d 100644 --- a/roles/home-cli/tasks/dotfiles.yml +++ b/roles/home-cli/tasks/dotfiles.yml @@ -3,10 +3,6 @@ copy: src: gemrc dest: "{{ ansible_env.HOME }}/.gemrc" -- name: Copy .gitconfig - copy: - src: gitconfig - dest: "{{ ansible_env.HOME }}/.gitconfig" - name: Remove .hushlogin file: path: "{{ ansible_env.HOME }}/.hushlogin" diff --git a/roles/home-cli/tasks/gitconfig.yml b/roles/home-cli/tasks/gitconfig.yml new file mode 100644 index 0000000..5f56820 --- /dev/null +++ b/roles/home-cli/tasks/gitconfig.yml @@ -0,0 +1,76 @@ +--- +- name: pull.rebase + git_config: + name: pull.rebase + value: true + scope: global +- name: push.default + git_config: + name: push.default + value: simple + scope: global +- name: color.ui + git_config: + name: color.ui + value: auto + scope: global +- name: credential.helper + git_config: + name: credential.helper + value: store + scope: global +- name: gui.encoding + git_config: + name: gui.encoding + value: utf-8 + scope: global +- name: guitool.Rebase.cmd + git_config: + name: guitool.Rebase.cmd + value: rebase + scope: global +- name: user.name + git_config: + name: user.name + value: Anthony Perkins + scope: global +- name: alias.ci + git_config: + name: alias.ci + value: commit + scope: global +- name: alias.co + git_config: + name: alias.co + value: checkout + scope: global +- name: alias.ff + git_config: + name: alias.ff + value: merge --ff-only + scope: global +- name: alias.graph + git_config: + name: alias.graph + value: log --graph --oneline --all + scope: global +- name: alias.l1 + git_config: + name: alias.l1 + value: log --pretty=oneline + scope: global +- name: alias.last + git_config: + name: alias.last + value: log -1 HEAD --pretty=fuller + scope: global +- name: alias.unstage + git_config: + name: alias.unstage + value: reset HEAD -- + scope: global +- name: alias.up + git_config: + name: alias.up + value: pull --rebase + scope: global diff --git a/roles/home-cli/tasks/main.yml b/roles/home-cli/tasks/main.yml index 2ddd5a0..53a2114 100644 --- a/roles/home-cli/tasks/main.yml +++ b/roles/home-cli/tasks/main.yml @@ -3,5 +3,6 @@ - include: dotfiles.yml - include: shell.yml +- include: gitconfig.yml - include: vim.yml - include: ssh-authorized-keys.yml