diff --git a/package.json b/package.json
index 9961121674ccbf2d933a4ad0be4ea81eae566350..fe3a5692dd33d533d223e2af72c50fdd0189c56f 100644
--- a/package.json
+++ b/package.json
@@ -2,8 +2,8 @@
   "name": "create-react-app-scripts",
   "version": "0.0.1",
   "scripts": {
-    "start": "node scripts/start.js local",
-    "build": "node scripts/build.js local",
+    "start": "node scripts/start.js",
+    "build": "node scripts/build.js",
     "create-react-app": "node global-cli/index.js --scripts-version \"$PWD/`npm pack`\""
   },
   "bin": {
diff --git a/scripts/build.js b/scripts/build.js
index 93b08992dfcba711af43b39308daf5b8cc433573..09ef8bdafdb4a03594ea5376650dee492ac7e4a7 100644
--- a/scripts/build.js
+++ b/scripts/build.js
@@ -9,11 +9,14 @@
 
 process.env.NODE_ENV = 'production';
 
+var path = require('path');
 var spawnSync = require('child_process').spawnSync;
 var webpack = require('webpack');
 var config = require('../webpack.config.prod');
 
-var relative = process.argv[2] === 'local' ? '.' : '../..';
+var isInNodeModules = 'node_modules' ===
+  path.basename(path.resolve(path.join(__dirname, '..', '..')));
+var relative = isInNodeModules ? '../..' : '.';
 spawnSync('rm', ['-rf', relative + '/build']);
 
 webpack(config).run(function(err, stats) {
diff --git a/scripts/graduate.js b/scripts/graduate.js
index 5d646a24a724dc76028dfacbe6aea77f7a51a4bf..58d9719c4962290fe20466731dd662310c7b9bde 100644
--- a/scripts/graduate.js
+++ b/scripts/graduate.js
@@ -8,26 +8,28 @@
  */
 
 var fs = require('fs');
+var path = require('path');
 
 console.log('Extracting scripts...');
+console.log();
 
-var hostPath = __dirname;
-var selfPath = hostPath + '/node_modules/create-react-app-scripts';
+var selfPath = path.join(__dirname, '..');
+var hostPath = path.join(selfPath, '..', '..');
 
 var files = [
   'scripts',
-  '.webpack.config.dev.js',
-  '.webpack.config.prod.js',
+  'webpack.config.dev.js',
+  'webpack.config.prod.js',
   '.babelrc',
   '.eslintrc',
 ];
 
 // Ensure that the host folder is clean and we won't override any files
 files.forEach(function(file) {
-  if (fs.existsSync(hostPath + '/' + file)) {
+  if (fs.existsSync(path.join(hostPath, file))) {
     console.error(
-      '`' + file + '` already exists on your app folder, we cannot ' +
-      'continue as you would lose all the changes in that file.',
+      '`' + file + '` already exists in your app folder. We cannot ' +
+      'continue as you would lose all the changes in that file or directory. ' +
       'Please delete it (maybe make a copy for backup) and run this ' +
       'command again.'
     );
@@ -37,9 +39,38 @@ files.forEach(function(file) {
 
 // Move the files over
 files.forEach(function(file) {
-  fs.renameSync(selfPath + '/' + file, hostPath + '/' + file);
+  console.log('Moving ' + file + ' to ' + hostPath);
+  fs.renameSync(path.join(selfPath, file), path.join(hostPath, file));
 });
 
-var hostPackage = require(hostPath + '/package.json');
+// These are unnecessary after graduation
+fs.unlinkSync(path.join(hostPath, 'scripts', 'init.js'));
+fs.unlinkSync(path.join(hostPath, 'scripts', 'graduate.js'));
 
+console.log();
+
+var selfPackage = require(path.join(selfPath, 'package.json'));
+var hostPackage = require(path.join(hostPath, 'package.json'));
+
+console.log('Removing dependency: create-react-app-scripts');
+delete hostPackage.devDependencies['create-react-app-scripts'];
+
+Object.keys(selfPackage.dependencies).forEach(function (key) {
+  console.log('Adding dependency: ' + key);
+  hostPackage.devDependencies[key] = selfPackage.dependencies[key];
+});
+
+console.log('Updating scripts');
+Object.keys(hostPackage.scripts).forEach(function (key) {
+  hostPackage.scripts[key] = 'node ./scripts/' + key + '.js'
+});
+delete hostPackage.scripts['graduate'];
+
+console.log('Writing package.json...');
+fs.writeFileSync(
+  path.join(hostPath, 'package.json'),
+  JSON.stringify(hostPackage, null, 2)
+);
+
+console.log();
 console.log('Done!');
diff --git a/scripts/init.js b/scripts/init.js
index a8d5d04e9f697e0a731c7afa6d5b9d3a8cda871e..6c3dc72bcafd2a96864881ffd46e256ea3ab6025 100644
--- a/scripts/init.js
+++ b/scripts/init.js
@@ -8,12 +8,13 @@
  */
 
 var fs = require('fs');
+var path = require('path');
 
 module.exports = function(hostPath, appName) {
-  var selfPath = hostPath + '/node_modules/create-react-app-scripts';
+  var selfPath = path.join(hostPath, 'node_modules', 'create-react-app-scripts');
 
-  var hostPackage = require(hostPath + '/package.json');
-  var selfPackage = require(selfPath + '/package.json');
+  var hostPackage = require(path.join(hostPath, 'package.json'));
+  var selfPackage = require(path.join(selfPath, 'package.json'));
 
   // Copy over devDependencies
   hostPackage.dependencies = hostPackage.dependencies || {};
@@ -28,12 +29,15 @@ module.exports = function(hostPath, appName) {
       command + '-react-app';
   });
 
-  fs.writeFileSync(hostPath + '/package.json', JSON.stringify(hostPackage, null, 2));
+  fs.writeFileSync(
+    path.join(hostPath, 'package.json'),
+    JSON.stringify(hostPackage, null, 2)
+  );
 
   // TODO: run npm install in hostPath, (not needed for npm 3 if we accept some hackery)
 
   // Move the src folder
-  fs.renameSync(selfPath + '/src', hostPath + '/src');
+  fs.renameSync(path.join(selfPath, 'src'), path.join(hostPath, 'src'));
 
   console.log('Success! Created ' + appName + ' at ' + hostPath + '.');
   console.log();
diff --git a/webpack.config.dev.js b/webpack.config.dev.js
index e9b8a7f541bc90dfb170b36dc5ebd15a1d878625..5b8847233b1fc44e9740c07705bce696875ceecf 100644
--- a/webpack.config.dev.js
+++ b/webpack.config.dev.js
@@ -12,7 +12,9 @@ var autoprefixer = require('autoprefixer');
 var webpack = require('webpack');
 var HtmlWebpackPlugin = require('html-webpack-plugin');
 
-var relative = process.argv[2] === 'local' ? '.' : '../..';
+var isInNodeModules = 'node_modules' ===
+  path.basename(path.resolve(path.join(__dirname, '..')));
+var relative = isInNodeModules ? '../..' : '.';
 
 module.exports = {
   devtool: 'eval',
diff --git a/webpack.config.prod.js b/webpack.config.prod.js
index 20b5d7a28a305c83766083a337c9e84bc99765b3..76a445057f1eb28f67d7ad8b56587fbb52b55b48 100644
--- a/webpack.config.prod.js
+++ b/webpack.config.prod.js
@@ -12,7 +12,9 @@ var autoprefixer = require('autoprefixer');
 var webpack = require('webpack');
 var HtmlWebpackPlugin = require('html-webpack-plugin');
 
-var relative = process.argv[2] === 'local' ? '.' : '../..';
+var isInNodeModules = 'node_modules' ===
+  path.basename(path.resolve(path.join(__dirname, '..')));
+var relative = isInNodeModules ? '../..' : '.';
 
 module.exports = {
   devtool: 'source-map',