diff --git a/ansible/laptop.yml b/ansible/laptop.yml new file mode 100644 index 0000000..090f024 --- /dev/null +++ b/ansible/laptop.yml @@ -0,0 +1,10 @@ +tasks: + - file: path={{ ansible_env.HOME }}/Applications state=directory + # - homebrew: name=caskroom/cask/brew-cask state=upgraded + - command: brew install caskroom/cask/brew-cask + - homebrew_cask: name={{ item }} state=installed + with_items: + - slimbatterymonitor + - shell: ioreg -n IOHIDKeyboard -r | grep -e VendorID\" -e ProductID | ruby -e 'print ARGF.read.scan(/\d+/).join(?-)' + register: keyboard_id + - command: defaults -currentHost write -g com.apple.keyboard.modifiermapping.{{ keyboard_id.stdout }}-0 -array-add 'HIDKeyboardModifierMappingDst2HIDKeyboardModifierMappingSrc0' diff --git a/ansible/roles/osx/tasks/defaults.yml b/ansible/roles/osx/tasks/defaults.yml index dfb351b..8ca3e01 100644 --- a/ansible/roles/osx/tasks/defaults.yml +++ b/ansible/roles/osx/tasks/defaults.yml @@ -4,10 +4,6 @@ sudo: True - command: defaults write {{ item }} with_items: osx_defaults -- shell: ioreg -n IOHIDKeyboard -r | grep -e VendorID\" -e ProductID | ruby -e 'print ARGF.read.scan(/\d+/).join(?-)' - register: keyboard_id -- debug: var=keyboard_id.stdout -- command: defaults -currentHost write -g com.apple.keyboard.modifiermapping.{{ keyboard_id.stdout }}-0 -array-add 'HIDKeyboardModifierMappingDst2HIDKeyboardModifierMappingSrc0' - command: killall {{ item }} with_items: - Finder diff --git a/ansible/roles/osx/vars/casks.yml b/ansible/roles/osx/vars/casks.yml index 74a0316..1486c7f 100644 --- a/ansible/roles/osx/vars/casks.yml +++ b/ansible/roles/osx/vars/casks.yml @@ -17,7 +17,6 @@ casks: - qlstephen - quicklook-csv - quicklook-json - # - slimbatterymonitor - steam - things - transmission