Added Git
This commit is contained in:
@@ -1,4 +1,13 @@
|
||||
{{ $shell := promptBoolOnce . "features.shell" "Do you want to install the Fish shell?" true }}
|
||||
{{- $email := promptStringOnce . "email" "What's your email?" }}
|
||||
{{- $git_name := promptStringOnce . "git_name" "What's your Git name?" }}
|
||||
|
||||
{{- $shell := promptBoolOnce . "features.shell" "Do you want to install the Fish shell?" true }}
|
||||
{{- $git := promptBoolOnce . "features.git" "Do you want to install Git?" true }}
|
||||
|
||||
[data]
|
||||
email = {{ $email | quote }}
|
||||
git_name = {{ $git_name | quote }}
|
||||
|
||||
[data.features]
|
||||
shell = {{ $shell }}
|
||||
git = {{ $git }}
|
||||
|
@@ -1,3 +1,6 @@
|
||||
{{- if not .features.shell }}
|
||||
.config/fish
|
||||
{{- end }}
|
||||
{{- if not .features.git }}
|
||||
.config/git
|
||||
{{- end }}
|
||||
|
9
home/private_dot_config/git/config.tmpl
Normal file
9
home/private_dot_config/git/config.tmpl
Normal file
@@ -0,0 +1,9 @@
|
||||
[user]
|
||||
email = {{ .email }}
|
||||
name = {{ .git_name }}
|
||||
|
||||
[init]
|
||||
defaultBranch = main
|
||||
|
||||
[merge]
|
||||
ff = true
|
@@ -25,3 +25,5 @@
|
||||
roles:
|
||||
- role: shell
|
||||
when: features.shell == true
|
||||
- role: git
|
||||
when: features.git == true
|
||||
|
5
setup-script/roles/git/tasks/main.yaml
Normal file
5
setup-script/roles/git/tasks/main.yaml
Normal file
@@ -0,0 +1,5 @@
|
||||
- name: Install Git on Arch
|
||||
become: true
|
||||
ansible.builtin.pacman:
|
||||
name: git
|
||||
when: chezmoi.osRelease.id == "arch"
|
Reference in New Issue
Block a user