I found a solution, but I think it might be a bit hacky.
In my xcode plugin i put this in my init
[[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(notificationListener:) name:nil object:nil];
And I made a method called
-(void)notificationListener:(NSNotification *)notification{
if (![notification.name isKindOfClass:[NSString class]]) {
if ([[notification name] isEqualToString:@"IDESourceCodeDocumentDidUpdateSourceModelNotification"] ) {
NSString *path = [ NSString stringWithFormat :@"%@",notification.object ];
path = [path substringFromIndex:49];
}
You'll get ALOT of notifications, and it took me a while to find one with information on the path, but this one has it.
Same method with
NSLog(@"Not recv: %@", notification.name);
will write out all the names of all the Notifications.