jenkins-bot has submitted this change and it was merged.

Change subject: Update JSDuck config to standard jsduck.json
......................................................................


Update JSDuck config to standard jsduck.json

Also
* This way we don't need to pass the --config=jsduck.config.json
  parameter but can run plain 'jsduck' in Jenkins. Allowing it
  to use the standard job template for testing.

* Move processes=0 to jsduck.json.
  Workaround for https://github.com/senchalabs/jsduck/issues/525

* Use standard ' - Documentation' suffix, which makes the first
  part of the title render in bold (similar to how we do in OOjs
  and OOjs UI already).

Change-Id: I6c9c7a1f29df0a72dc8cd0d37a83aaef23068062
---
D .docs/config.json
R .jsduck/CustomTags.rb
R .jsduck/categories.json
R .jsduck/eg-iframe.html
R .jsduck/eg-iframe.html.template
R .jsduck/external.js
R .jsduck/generate.sh
R .jsduck/mw-categories.json
M Gruntfile.js
M bin/generateDocs.sh
A jsduck.json
11 files changed, 30 insertions(+), 33 deletions(-)

Approvals:
  Jforrester: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/.docs/config.json b/.docs/config.json
deleted file mode 100644
index 81a5751..0000000
--- a/.docs/config.json
+++ /dev/null
@@ -1,21 +0,0 @@
-{
-       "--title": "VisualEditor Code Documentation",
-       "--categories": "../.docs/categories.json",
-       "--eg-iframe": "../.docs/eg-iframe.html",
-       "--tags": "./CustomTags.rb",
-       "--warnings": ["-nodoc(class,public)"],
-       "--builtin-classes": true,
-       "--warnings-exit-nonzero": true,
-       "--external": 
"HTMLDocument,Window,Node,Set,Range,Selection,ClientRect,File,Blob,DataTransfer,DataTransferItem",
-       "--output": "../docs",
-       "--": [
-               "./external.js",
-               "../lib/ve/.jsduck/external.js",
-               "../lib/ve/lib/oojs",
-               "../lib/ve/lib/oojs-ui",
-               "../lib/ve/lib/unicodejs",
-               "../lib/ve/src",
-               "../lib/ve/tests",
-               "../modules/ve-mw"
-       ]
-}
diff --git a/.docs/CustomTags.rb b/.jsduck/CustomTags.rb
similarity index 100%
rename from .docs/CustomTags.rb
rename to .jsduck/CustomTags.rb
diff --git a/.docs/categories.json b/.jsduck/categories.json
similarity index 100%
rename from .docs/categories.json
rename to .jsduck/categories.json
diff --git a/.docs/eg-iframe.html b/.jsduck/eg-iframe.html
similarity index 100%
rename from .docs/eg-iframe.html
rename to .jsduck/eg-iframe.html
diff --git a/.docs/eg-iframe.html.template b/.jsduck/eg-iframe.html.template
similarity index 100%
rename from .docs/eg-iframe.html.template
rename to .jsduck/eg-iframe.html.template
diff --git a/.docs/external.js b/.jsduck/external.js
similarity index 100%
rename from .docs/external.js
rename to .jsduck/external.js
diff --git a/.docs/generate.sh b/.jsduck/generate.sh
similarity index 100%
rename from .docs/generate.sh
rename to .jsduck/generate.sh
diff --git a/.docs/mw-categories.json b/.jsduck/mw-categories.json
similarity index 100%
rename from .docs/mw-categories.json
rename to .jsduck/mw-categories.json
diff --git a/Gruntfile.js b/Gruntfile.js
index 9618290..6c369d1 100644
--- a/Gruntfile.js
+++ b/Gruntfile.js
@@ -20,9 +20,9 @@
                pkg: grunt.file.readJSON( 'package.json' ),
                jsduckcatconfig: {
                        main: {
-                               target: '.docs/categories.json',
+                               target: '.jsduck/categories.json',
                                from: [
-                                       '.docs/mw-categories.json',
+                                       '.jsduck/mw-categories.json',
                                        {
                                                file: 
'lib/ve/.jsduck/categories.json',
                                                aggregate: {
@@ -42,8 +42,8 @@
                },
                buildloader: {
                        egiframe: {
-                               targetFile: '.docs/eg-iframe.html',
-                               template: '.docs/eg-iframe.html.template',
+                               targetFile: '.jsduck/eg-iframe.html',
+                               template: '.jsduck/eg-iframe.html.template',
                                modules: modules,
                                load: [ 'visualEditor.desktop.standalone' ],
                                pathPrefix: 'lib/ve/',
@@ -56,7 +56,7 @@
                        },
                        all: [
                                '*.js',
-                               '{.docs,build}/**/*.js',
+                               '{.jsduck,build}/**/*.js',
                                'modules/**/*.js'
                        ]
                },
diff --git a/bin/generateDocs.sh b/bin/generateDocs.sh
index 5cf9422..eeba646 100755
--- a/bin/generateDocs.sh
+++ b/bin/generateDocs.sh
@@ -1,9 +1,5 @@
 #!/usr/bin/env bash
 set -e
-
-REPO_DIR=$(cd $(dirname $0)/..; pwd)
-
-# Disable parallel processing which seems to be causing problems under Ruby 1.8
-jsduck --config $REPO_DIR/.docs/config.json --processes 0
-
-ln -s ../lib $REPO_DIR/docs/lib
+cd $(dirname $0)/..
+jsduck
+ln -s ../lib docs/lib
diff --git a/jsduck.json b/jsduck.json
new file mode 100644
index 0000000..494d807
--- /dev/null
+++ b/jsduck.json
@@ -0,0 +1,22 @@
+{
+       "--title": "VisualEditor - Documentation",
+       "--categories": ".jsduck/categories.json",
+       "--eg-iframe": ".jsduck/eg-iframe.html",
+       "--tags": ".jsduck/CustomTags.rb",
+       "--warnings": ["-nodoc(class,public)"],
+       "--builtin-classes": true,
+       "--processes": "0",
+       "--warnings-exit-nonzero": true,
+       "--external": 
"HTMLDocument,Window,Node,Set,Range,Selection,ClientRect,File,Blob,DataTransfer,DataTransferItem",
+       "--output": "docs",
+       "--": [
+               ".jsduck/external.js",
+               "lib/ve/.jsduck/external.js",
+               "lib/ve/lib/oojs",
+               "lib/ve/lib/oojs-ui",
+               "lib/ve/lib/unicodejs",
+               "lib/ve/src",
+               "lib/ve/tests",
+               "modules/ve-mw"
+       ]
+}

-- 
To view, visit https://gerrit.wikimedia.org/r/194727
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I6c9c7a1f29df0a72dc8cd0d37a83aaef23068062
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/VisualEditor
Gerrit-Branch: master
Gerrit-Owner: Krinkle <[email protected]>
Gerrit-Reviewer: Jforrester <[email protected]>
Gerrit-Reviewer: jenkins-bot <>

_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to