I've just encountered this same “Bad CPU type” error with ruby18:
/Users/quinn/Library/Application Support/TextMate/Managed/Bundles/Bundle Support.tmbundle/Support/shared/bin/ruby18: line 43: /Users/quinn/Library/Application Support/TextMate/Ruby/1.8.7/bin/ruby: Bad CPU type in executable /Users/quinn/Library/Application Support/TextMate/Managed/Bundles/Bundle Support.tmbundle/Support/shared/bin/ruby18: line 43: /Users/quinn/Library/Application Support/TextMate/Ruby/1.8.7/bin/ruby: Undefined error: 0
1. I upgraded to a MBP 14", running macOS 12.1 (clean install). 2. I fresh-installed TextMate via `brew install text mate` 3. I tried running my Duplicate Line command: https://pastebin.com/G8HLz4tc 4. I get the error above.
This command doesn't work with ruby v2, so it can't be fixed as easy as Christophe's `ruby18` wrapper script hack.
Should the ruby18 included in TextMate be able to run on Apple silicon?
Regards, Quinn