Skip to content
Find file
Fetching contributors…
Cannot retrieve contributors at this time
45 lines (36 sloc) 1.12 KB
// TCMyImporterPlugin.m
// technicolor-file-importer
// Created by Steve Streza on 11/2/08.
// Copyright 2008 __MyCompanyName__. All rights reserved.
#import "TCMyImporterPlugin.h"
#import "SSImportScanOperation.h"
#import "TCTVShow.h"
#import "TCTVEpisode.h"
@implementation TCMyImporterPlugin
NSArray *paths = [NSArray arrayWithObjects:
@"/Volumes/Lavos/Video/TV Shows/",
@"/Volumes/Kerrigan/Video/TV Shows/",
@"/Volumes/Kefka/Video/TV Shows/",
@"/Volumes/Cortana/Video/TV Shows/",
for(NSString *path in paths){
SSImportScanOperation *scanOp = [[SSImportScanOperation alloc] init];
scanOp.sourcePath = path;
[scanOp run];
[scanOp release];
NSArray *allShows = [TCTVShow allShows:YES];
NSArray *allEpisodes = [TCTVEpisode allEpisodes:YES];
NSLog(@"All shows! %i",[allShows count]);
for(TCTVShow *show in allShows){
NSArray *episodes = [show episodes];
NSLog(@" - Show %@ has %i episodes",[show valueForKey:@"showName"], [episodes count]);
NSLog(@"All episodes! %i",[allEpisodes count]);
Something went wrong with that request. Please try again.