-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathtest_lua.sh
More file actions
executable file
·45 lines (39 loc) · 1.18 KB
/
test_lua.sh
File metadata and controls
executable file
·45 lines (39 loc) · 1.18 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
#!/bin/bash
# Test Hammerspoon Lua Scripts
echo "🎯 Testing Automation Assassin Lua Scripts"
echo "=========================================="
# Check if Hammerspoon is installed
if ! command -v hs &> /dev/null; then
echo "⚠️ Hammerspoon not installed!"
echo "Install with: brew install --cask hammerspoon"
exit 1
fi
echo "✅ Hammerspoon found"
echo ""
# Test the generated Lua scripts
echo "📝 Testing Lua scripts..."
echo ""
# Run the test script
if [ -f "test_hammerspoon.lua" ]; then
echo "Running test suite..."
hs test_hammerspoon.lua
else
echo "❌ test_hammerspoon.lua not found"
exit 1
fi
echo ""
echo "✨ Tests complete!"
echo ""
echo "To install the scripts:"
echo " 1. cp automations/*.lua ~/.hammerspoon/"
echo " 2. Add to ~/.hammerspoon/init.lua:"
echo ""
echo " -- Automation Assassin"
echo " local splitScreen = require('split_screen_optimizer')"
echo " local focusMode = require('focus_mode')"
echo ""
echo " -- Hotkeys"
echo " hs.hotkey.bind({'cmd', 'alt'}, 'F', focusMode.toggle)"
echo " hs.hotkey.bind({'cmd', 'alt'}, 'S', splitScreen.arrange)"
echo ""
echo " 3. Reload Hammerspoon (menubar icon → Reload Config)"