Merge pull request #69 from nektro/patch-1 #37
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: textmate | |
on: push | |
jobs: | |
test: | |
runs-on: macos-latest | |
steps: | |
- name: Install dependencies | |
run: | | |
brew install --cask textmate | |
brew install coreutils zig | |
- name: Textmate load success | |
run: | | |
# "install" bundle | |
mkdir -p "$HOME/Library/Application Support/TextMate/Bundles/" | |
ln -s "$PWD" "$HOME/Library/Application Support/TextMate/Bundles/Zig.tmbundle" | |
# run TextMate, capture output | |
/Applications/TextMate.app/Contents/MacOS/TextMate | tee textmate.out & | |
# don't expect the bundle to be mentioned in output as that would indicate an error | |
! grep Zig.tmbundle textmate.out | |
# open a sample source | |
mate hello.zig | |
# use Build command via keyboard shortcut | |
osascript -e 'activate application "TextMate"' -e 'tell application "System Events" to keystroke "b" using command down' | |
# wait for binary to be built | |
gtimeout 30 /bin/sh -c 'while ! ls hello 2>/dev/null; do sleep 1; done' | |
./hello | |
# debugging | |
# screencapture test.png; cat test.png | base64 | |
osascript -e 'tell application "TextMate" to quit' |