objc-run

Run Objective-C code directly from the command line like shell scripts

brewmacoslinux
Try with needOr install directly
Source

About

Use Objective-C files for shell script-like tasks

Commands

objc-run

Examples

Execute a simple Objective-C script file$ objc-run script.m
Run inline Objective-C code with arguments$ objc-run -c '@import Foundation; NSLog(@"Hello %@", @"World");'
Use Objective-C for system tasks like file operations$ objc-run -c '@import Foundation; [[NSFileManager defaultManager] copyItemAtPath:@"/source" toPath:@"/dest" error:nil];'