From e461c4d94a03563a604fdc3296a2fdb905ca5cc6 Mon Sep 17 00:00:00 2001 From: Kevin Sawicki Date: Tue, 12 Mar 2013 13:49:28 -0700 Subject: [PATCH] :lipstick: --- native/atom_window_controller.mm | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/native/atom_window_controller.mm b/native/atom_window_controller.mm index 90e63d877..5dad7154a 100644 --- a/native/atom_window_controller.mm +++ b/native/atom_window_controller.mm @@ -59,17 +59,21 @@ @"vendor/packages", @"vendor", @"static", @"themes", @"node_modules", nil]; NSMutableArray *resourcePaths = [[NSMutableArray alloc] init]; + if (_runningSpecs) { NSString *fixturePackagesDirectory = [NSString stringWithFormat:@"%@/spec/fixtures/packages", _resourcePath]; [resourcePaths addObject:fixturePackagesDirectory]; } + NSString *userPackagesDirectory = [@"~/.atom/packages" stringByStandardizingPath]; [resourcePaths addObject:userPackagesDirectory]; + for (int i = 0; i < paths.count; i++) { NSString *fullPath = [NSString stringWithFormat:@"%@/%@", _resourcePath, [paths objectAtIndex:i]]; [resourcePaths addObject:fullPath]; } [resourcePaths addObject:_resourcePath]; + NSString *nodePath = [resourcePaths componentsJoinedByString:@":"]; setenv("NODE_PATH", [nodePath UTF8String], TRUE);