30 lines
625 B
YAML

---
- set_fact:
config_dir: '{{ansible_env.HOME}}/.hammerspoon'
- name: create config directory
file:
state: directory
path: '{{config_dir}}'
- name: install config file
template:
src: init.lua
dest: '{{config_dir}}/init.lua'
- name: install homebrew package
homebrew:
state: latest
name: hammerspoon
- name: create spoons directory
file:
state: directory
path: '{{config_dir}}/Spoons'
- name: install SpoonInstall Spoon
unarchive:
src: https://github.com/Hammerspoon/Spoons/raw/master/Spoons/SpoonInstall.spoon.zip
dest: '{{config_dir}}/Spoons'
remote_src: yes