Bug 1188417 - Split gcli commands require path to match file system. r=jwalker
authorAlexandre Poirot <poirot.alex@gmail.com>
Mon, 03 Aug 2015 03:01:35 -0700
changeset 287502 34e2362a1730fc91edc0be3c349d0f7e9bce24c0
parent 287391 88ecc638d778ef1a1e147fb025a0df03c48d31da
child 287503 85afe1aa3e6fa57689fa096a192a4265e0c40d01
push id5067
push userraliiev@mozilla.com
push dateMon, 21 Sep 2015 14:04:52 +0000
treeherdermozilla-beta@14221ffe5b2f [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersjwalker
bugs1188417
milestone42.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1188417 - Split gcli commands require path to match file system. r=jwalker
browser/devtools/commandline/test/browser_cmd_highlight_02.js
browser/devtools/commandline/test/browser_cmd_settings.js
browser/devtools/shared/DeveloperToolbar.jsm
toolkit/devtools/gcli/commands/index.js
toolkit/devtools/server/actors/gcli.js
--- a/browser/devtools/commandline/test/browser_cmd_highlight_02.js
+++ b/browser/devtools/commandline/test/browser_cmd_highlight_02.js
@@ -31,14 +31,14 @@ function test() {
     yield helpers.closeToolbar(options);
     yield helpers.closeTab(options);
   }).then(finish, helpers.handleError);
 }
 
 function getHighlighterNumber() {
   // Note that this only works as long as gcli tests aren't run with e10s on.
   // To make this e10s ready, execute this in a content frame script instead.
-  return require("gcli/commands/highlight").highlighters.length;
+  return require("devtools/toolkit/gcli/commands/highlight").highlighters.length;
 }
 
 function* runCommand(cmd, options) {
   yield helpers.audit(options, [{ setup: cmd, exec: {} }]);
 }
--- a/browser/devtools/commandline/test/browser_cmd_settings.js
+++ b/browser/devtools/commandline/test/browser_cmd_settings.js
@@ -18,17 +18,17 @@ function test() {
 
 function* spawnTest() {
   // Setup
   let options = yield helpers.openTab(TEST_URI);
 
   const { createSystem } = require("gcli/system");
   const system = createSystem({ location: "server" });
 
-  const gcliInit = require("gcli/commands/index");
+  const gcliInit = require("devtools/toolkit/gcli/commands/index");
   gcliInit.addAllItemsByModule(system);
   yield system.load();
 
   let settings = system.settings;
 
   let hideIntroEnabled = settings.get("devtools.gcli.hideIntro");
   let tabSize = settings.get("devtools.editor.tabsize");
   let remoteHost = settings.get("devtools.debugger.remote-host");
--- a/browser/devtools/shared/DeveloperToolbar.jsm
+++ b/browser/devtools/shared/DeveloperToolbar.jsm
@@ -36,17 +36,17 @@ XPCOMUtils.defineLazyGetter(this, "prefB
 XPCOMUtils.defineLazyGetter(this, "toolboxStrings", function () {
   return Services.strings.createBundle("chrome://browser/locale/devtools/toolbox.properties");
 });
 
 const Telemetry = require("devtools/shared/telemetry");
 
 XPCOMUtils.defineLazyGetter(this, "gcliInit", function() {
   try {
-    return require("gcli/commands/index");
+    return require("devtools/toolkit/gcli/commands/index");
   }
   catch (ex) {
     console.log(ex);
   }
 });
 
 XPCOMUtils.defineLazyGetter(this, "util", () => {
   return require("gcli/util/util");
--- a/toolkit/devtools/gcli/commands/index.js
+++ b/toolkit/devtools/gcli/commands/index.js
@@ -49,35 +49,35 @@ exports.baseModules = [
   "gcli/commands/pref",
 ];
 
 /**
  * Some commands belong to a tool (see getToolModules). This is a list of the
  * modules that are *not* owned by a tool.
  */
 exports.devtoolsModules = [
-  "gcli/commands/addon",
-  "gcli/commands/appcache",
-  "gcli/commands/calllog",
-  "gcli/commands/cmd",
-  "gcli/commands/cookie",
-  "gcli/commands/csscoverage",
-  "gcli/commands/folder",
-  "gcli/commands/highlight",
-  "gcli/commands/inject",
-  "gcli/commands/jsb",
-  "gcli/commands/listen",
-  "gcli/commands/media",
-  "gcli/commands/pagemod",
-  "gcli/commands/paintflashing",
-  "gcli/commands/restart",
-  "gcli/commands/rulers",
-  "gcli/commands/screenshot",
-  "gcli/commands/security",
-  "gcli/commands/tools",
+  "devtools/toolkit/gcli/commands/addon",
+  "devtools/toolkit/gcli/commands/appcache",
+  "devtools/toolkit/gcli/commands/calllog",
+  "devtools/toolkit/gcli/commands/cmd",
+  "devtools/toolkit/gcli/commands/cookie",
+  "devtools/toolkit/gcli/commands/csscoverage",
+  "devtools/toolkit/gcli/commands/folder",
+  "devtools/toolkit/gcli/commands/highlight",
+  "devtools/toolkit/gcli/commands/inject",
+  "devtools/toolkit/gcli/commands/jsb",
+  "devtools/toolkit/gcli/commands/listen",
+  "devtools/toolkit/gcli/commands/media",
+  "devtools/toolkit/gcli/commands/pagemod",
+  "devtools/toolkit/gcli/commands/paintflashing",
+  "devtools/toolkit/gcli/commands/restart",
+  "devtools/toolkit/gcli/commands/rulers",
+  "devtools/toolkit/gcli/commands/screenshot",
+  "devtools/toolkit/gcli/commands/security",
+  "devtools/toolkit/gcli/commands/tools",
 ];
 
 /**
  * Register commands from tools with 'command: [ "some/module" ]' definitions.
  * The map/reduce incantation squashes the array of arrays to a single array.
  */
 try {
   const defaultTools = require("definitions").defaultTools;
@@ -106,17 +106,17 @@ try {
  * Add modules to a system for use in a content process (but don't call load)
  */
 exports.addAllItemsByModule = function(system) {
   system.addItemsByModule(exports.baseModules, { delayedLoad: true });
   system.addItemsByModule(exports.devtoolsModules, { delayedLoad: true });
   system.addItemsByModule(exports.devtoolsToolModules, { delayedLoad: true });
   system.addItemsByModule(exports.devtoolsButtonModules, { delayedLoad: true });
 
-  const { mozDirLoader } = require("gcli/commands/cmd");
+  const { mozDirLoader } = require("devtools/toolkit/gcli/commands/cmd");
   system.addItemsByModule("mozcmd", { delayedLoad: true, loader: mozDirLoader });
 };
 
 /**
  * This is WeakMap<Target, Links> where Links is an object that looks like
  *   { refs: number, promise: Promise<System>, front: GcliFront }
  */
 var linksForTarget = new WeakMap();
--- a/toolkit/devtools/server/actors/gcli.js
+++ b/toolkit/devtools/server/actors/gcli.js
@@ -239,17 +239,17 @@ const GcliActor = ActorClass({
     }
 
     const Requisition = require("gcli/cli").Requisition;
     const tabActor = this._tabActor;
 
     this._system = createSystem({ location: "server" });
     this._system.commands.onCommandsChange.add(this._commandsChanged);
 
-    const gcliInit = require("gcli/commands/index");
+    const gcliInit = require("devtools/toolkit/gcli/commands/index");
     gcliInit.addAllItemsByModule(this._system);
 
     // this._requisitionPromise should be created synchronously with the call
     // to _getRequisition so that destroy can tell whether there is an async
     // init in progress
     this._requisitionPromise = this._system.load().then(() => {
       const environment = {
         get chromeWindow() {