mirror of
https://github.com/geerlingguy/mac-dev-playbook
synced 2024-11-22 03:43:06 +00:00
Fixes #29: Split out custom preferences-related tasks to make them configurable.
This commit is contained in:
parent
f34f1a1f18
commit
0a07340e9c
5 changed files with 23 additions and 19 deletions
|
@ -2,7 +2,7 @@
|
|||
downloads: ~/.ansible-downloads/
|
||||
|
||||
configure_sudoers: yes
|
||||
configure_prefs: yes
|
||||
configure_terminal: yes
|
||||
configure_osx: yes
|
||||
|
||||
dotfiles_repo: https://github.com/geerlingguy/dotfiles.git
|
||||
|
|
13
main.yml
13
main.yml
|
@ -18,11 +18,12 @@
|
|||
|
||||
tasks:
|
||||
- include: tasks/ansible-setup.yml
|
||||
- include: tasks/preferences.yml
|
||||
when: configure_prefs
|
||||
|
||||
# TODO: Use sudo once .osx can be run via root with no user interaction.
|
||||
- name: Run .osx dotfiles.
|
||||
shell: ~/.osx --no-restart
|
||||
changed_when: false
|
||||
- include: tasks/sudoers.yml
|
||||
when: configure_sudoers
|
||||
|
||||
- include: tasks/terminal.yml
|
||||
when: configure_terminal
|
||||
|
||||
- include: tasks/osx.yml
|
||||
when: configure_osx
|
||||
|
|
5
tasks/osx.yml
Normal file
5
tasks/osx.yml
Normal file
|
@ -0,0 +1,5 @@
|
|||
---
|
||||
# TODO: Use sudo once .osx can be run via root with no user interaction.
|
||||
- name: Run .osx dotfiles.
|
||||
shell: ~/.osx --no-restart
|
||||
changed_when: false
|
10
tasks/sudoers.yml
Normal file
10
tasks/sudoers.yml
Normal file
|
@ -0,0 +1,10 @@
|
|||
---
|
||||
# Sudoers configuration (enables more convenient Vagrant usage).
|
||||
- name: Copy sudoers configuration into place.
|
||||
copy:
|
||||
src: files/etc/sudoers
|
||||
dest: /etc/sudoers
|
||||
mode: 0440
|
||||
validate: 'visudo -cf %s'
|
||||
become: yes
|
||||
when: configure_sudoers
|
|
@ -19,15 +19,3 @@
|
|||
- defaults write com.apple.terminal 'Startup Window Settings' -string JJG-Term
|
||||
changed_when: false
|
||||
when: "'JJG-Term' not in terminal_theme.stdout"
|
||||
|
||||
# Sudoers configuration (enables more convenient Vagrant usage).
|
||||
- name: Copy sudoers configuration into place.
|
||||
copy:
|
||||
src: files/etc/sudoers
|
||||
dest: /etc/sudoers
|
||||
mode: 0440
|
||||
validate: 'visudo -cf %s'
|
||||
become: yes
|
||||
when: configure_sudoers
|
||||
|
||||
# TODO: Configure Sublime Text (see templates/sublime/*).
|
Loading…
Reference in a new issue