You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@allura.apache.org by he...@apache.org on 2015/10/02 16:02:39 UTC

[1/5] allura git commit: [#7976] Use Broccoli to transpile es6 & jsx files

Repository: allura
Updated Branches:
  refs/heads/master 79b2b98d1 -> 70001e201


[#7976] Use Broccoli to transpile es6 & jsx files


Project: http://git-wip-us.apache.org/repos/asf/allura/repo
Commit: http://git-wip-us.apache.org/repos/asf/allura/commit/1dd78440
Tree: http://git-wip-us.apache.org/repos/asf/allura/tree/1dd78440
Diff: http://git-wip-us.apache.org/repos/asf/allura/diff/1dd78440

Branch: refs/heads/master
Commit: 1dd78440bde218d65065258a7bc988a37a596936
Parents: 34e5195
Author: Dave Brondsema <da...@brondsema.net>
Authored: Thu Sep 24 13:35:42 2015 -0400
Committer: Heith Seewald <hs...@hsmb.local>
Committed: Fri Oct 2 10:01:48 2015 -0400

----------------------------------------------------------------------
 .gitignore                                      |  2 ++
 .../allura/templates/jinja_master/master.html   |  1 +
 Allura/docs/development/contributing.rst        | 10 +++++-
 Allura/docs/getting_started/installation.rst    | 16 +++++++++
 Brocfile.js                                     | 35 ++++++++++++++++++++
 Dockerfile                                      |  8 +++--
 docker-compose.yml                              | 12 ++++++-
 package.json                                    | 23 +++++++++++++
 scripts/asf-release.sh                          | 12 +++++++
 9 files changed, 115 insertions(+), 4 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/allura/blob/1dd78440/.gitignore
----------------------------------------------------------------------
diff --git a/.gitignore b/.gitignore
index 44b29e3..0918813 100644
--- a/.gitignore
+++ b/.gitignore
@@ -26,11 +26,13 @@ var/
 .noseids
 env
 env-docker
+Allura/allura/public/nf/js/build/
 Allura/allura/templates/home
 Allura/allura/templates/var
 Allura/production.ini
 Allura/forced_upgrade.ini
 scripts/teamforge-export/
+/node_modules
 report.clonedigger
 .ropeproject
 .idea

http://git-wip-us.apache.org/repos/asf/allura/blob/1dd78440/Allura/allura/templates/jinja_master/master.html
----------------------------------------------------------------------
diff --git a/Allura/allura/templates/jinja_master/master.html b/Allura/allura/templates/jinja_master/master.html
index 48b6911..b2d2418 100644
--- a/Allura/allura/templates/jinja_master/master.html
+++ b/Allura/allura/templates/jinja_master/master.html
@@ -29,6 +29,7 @@
 {% do g.register_forge_js('js/sylvester.js') %}
 {% do g.register_forge_js('js/pb.transformie.min.js') %}
 {% do g.register_forge_js('js/allura-base.js') %}
+{% do g.register_forge_js('js/build/transpiled.js') %}
 {% do g.register_forge_css('css/forge/hilite.css') %}
 {% do g.register_forge_css('css/forge/tooltipster.css') %}
 {% do g.register_forge_css('css/font-awesome.min.css', compress=False) %}

http://git-wip-us.apache.org/repos/asf/allura/blob/1dd78440/Allura/docs/development/contributing.rst
----------------------------------------------------------------------
diff --git a/Allura/docs/development/contributing.rst b/Allura/docs/development/contributing.rst
index 56ee818..e161fdb 100644
--- a/Allura/docs/development/contributing.rst
+++ b/Allura/docs/development/contributing.rst
@@ -100,7 +100,15 @@ the Allura source already.
 `Jinja <http://jinja.pocoo.org/>`_ - HTML template library used by Allura.
 
 If you want to work on the front end of Allura, you'll also need some CSS and
-Javascript skills, and basic knowledge of JQuery.
+Javascript skills, and basic knowledge of JQuery.  We are also using React and ES6.
+To transpile those files as soon as you edit them:
+
+.. code-block:: bash
+
+    ~$ npm install -g broccoli-timepiece
+    ~$ cd ~/src/allura
+    ~$ broccoli-timepiece Allura/allura/public/nf/js/build/
+
 
 Finding Something to Work On
 ----------------------------

http://git-wip-us.apache.org/repos/asf/allura/blob/1dd78440/Allura/docs/getting_started/installation.rst
----------------------------------------------------------------------
diff --git a/Allura/docs/getting_started/installation.rst b/Allura/docs/getting_started/installation.rst
index 36df424..b28fca3 100644
--- a/Allura/docs/getting_started/installation.rst
+++ b/Allura/docs/getting_started/installation.rst
@@ -178,6 +178,22 @@ Allura uses a background task service called "taskd" to do async tasks like send
     (env-allura)~$ cd ~/src/allura/Allura
     (env-allura)~/src/allura/Allura$ nohup paster taskd development.ini > /var/log/allura/taskd.log 2>&1 &
 
+
+A few more steps, if using git
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+
+If you're using a released version of Allura, these are already done for you.  This transpiles JS into a version all browsers support:
+
+.. code-block:: bash
+
+    (env-allura)~$ sudo aptitude install nodejs npm
+    (env-allura)~$ sudo ln -s /usr/bin/nodejs /usr/bin/node
+    (env-allura)~$ cd ~/src/allura
+    (env-allura)~$ npm install -g broccoli-cli
+    (env-allura)~$ npm install
+    (env-allura)~$ broccoli build Allura/allura/public/nf/js/build/
+
+
 The application server
 ~~~~~~~~~~~~~~~~~~~~~~
 

http://git-wip-us.apache.org/repos/asf/allura/blob/1dd78440/Brocfile.js
----------------------------------------------------------------------
diff --git a/Brocfile.js b/Brocfile.js
new file mode 100644
index 0000000..e16ee4c
--- /dev/null
+++ b/Brocfile.js
@@ -0,0 +1,35 @@
+var babelTranspiler = require("broccoli-babel-transpiler");
+var sourceMap = require('broccoli-source-map');
+var concat = require('broccoli-concat');
+var funnel = require('broccoli-funnel');
+var uglifyJavaScript = require('broccoli-uglify-js');
+
+var tree = funnel('Allura/allura/public/nf/js', {
+  include: ['*.es6.js'],
+});
+tree = babelTranspiler(tree, {
+    browserPolyfill: true,
+    //filterExtensions:['es6.js'],
+    sourceMaps: 'inline',  // external doesn't work, have to use extract below
+    comments: false,
+});
+tree = concat(tree, {
+  inputFiles: ['**/*.js'],
+  outputFile: '/transpiled.js'
+});
+tree = sourceMap.extract(tree);
+
+if (process.env.BROCCOLI_ENV === 'production') {
+    /* can't use this for dev mode, since it drops the sourcemap comment even if we set  output: {comments: true}
+     https://github.com/mishoo/UglifyJS2/issues/653
+     https://github.com/mishoo/UglifyJS2/issues/754
+     https://github.com/mishoo/UglifyJS2/issues/780
+     https://github.com/mishoo/UglifyJS2/issues/520
+     */
+    tree = uglifyJavaScript(tree, {
+        mangle: false,
+        compress: false
+    });
+}
+
+module.exports = tree;

http://git-wip-us.apache.org/repos/asf/allura/blob/1dd78440/Dockerfile
----------------------------------------------------------------------
diff --git a/Dockerfile b/Dockerfile
index 12170ef..f125d55 100644
--- a/Dockerfile
+++ b/Dockerfile
@@ -29,7 +29,10 @@ RUN apt-get update && apt-get install -y \
     python-pip \
     zip \
     subversion \
-    python-svn
+    python-svn \
+    npm
+RUN ln -s /usr/bin/nodejs /usr/bin/node
+RUN npm install -g broccoli-cli
 
 # Snapshot generation for SVN (and maybe other SCMs) might fail without this
 RUN locale-gen en_US.UTF-8
@@ -39,4 +42,5 @@ ENV LANG en_US.UTF-8
 # tests). If this is not set, it uses os.getlogin, which fails inside docker.
 ENV USER root
 
-WORKDIR /allura
+WORKDIR /allura/Allura
+CMD gunicorn --paste docker-dev.ini --reload

http://git-wip-us.apache.org/repos/asf/allura/blob/1dd78440/docker-compose.yml
----------------------------------------------------------------------
diff --git a/docker-compose.yml b/docker-compose.yml
index 6822677..86102ed 100644
--- a/docker-compose.yml
+++ b/docker-compose.yml
@@ -18,7 +18,17 @@
 web:
   build: .
   working_dir: /allura
-  command: bash -c 'cd Allura && gunicorn --paste docker-dev.ini --reload'
+  # specialized command (and working_dir) to run broccoli
+  # since it depends on files from the shared volume, it can't be run as part of the Dockerfile build :(
+  command: >
+    sh -c '
+    if [ ! -e Allura/allura/public/nf/js/build/transpiled.js ]; then
+      npm install &&
+      rm -rf Allura/allura/public/nf/js/build/ &&
+      broccoli build Allura/allura/public/nf/js/build/;
+    fi;
+    gunicorn --paste Allura/docker-dev.ini --reload
+    '
   ports:
     - "8080:8080"
   volumes:

http://git-wip-us.apache.org/repos/asf/allura/blob/1dd78440/package.json
----------------------------------------------------------------------
diff --git a/package.json b/package.json
new file mode 100644
index 0000000..58dcc6b
--- /dev/null
+++ b/package.json
@@ -0,0 +1,23 @@
+{
+  "name": "allura",
+  "version": "0.0.0",
+  "description": "",
+  "main": "Brocfile.js",
+  "scripts": {
+    "test": "echo \"Error: no test specified\" && exit 1"
+  },
+  "repository": {
+    "type": "git",
+    "url": "https://git-wip-us.apache.org/repos/asf/allura.git"
+  },
+  "author": "",
+  "license": "Apache-2.0",
+  "devDependencies": {
+    "broccoli": "^0.16.8",
+    "broccoli-babel-transpiler": "^5.4.5",
+    "broccoli-concat": "0.0.13",
+    "broccoli-funnel": "^0.2.8",
+    "broccoli-source-map": "^0.2.3",
+    "broccoli-uglify-js": "^0.1.3"
+  }
+}

http://git-wip-us.apache.org/repos/asf/allura/blob/1dd78440/scripts/asf-release.sh
----------------------------------------------------------------------
diff --git a/scripts/asf-release.sh b/scripts/asf-release.sh
index 9239dc2..8ee73a4 100755
--- a/scripts/asf-release.sh
+++ b/scripts/asf-release.sh
@@ -41,6 +41,7 @@ prompt VERSION "Version" "$VERSION"
 RELEASE_BASE=allura-$VERSION
 RELEASE_DIR=$RELEASE_DIR_BASE/$RELEASE_BASE
 RELEASE_FILENAME=$RELEASE_BASE.tar.gz
+RELEASE_FILE_EXTRACTED=$RELEASE_DIR/$RELEASE_BASE
 RELEASE_FILE=$RELEASE_DIR/$RELEASE_FILENAME
 RELEASE_TAG=asf_release_$VERSION
 CLOSE_DATE=`date -d '+72 hours' +%F`
@@ -68,6 +69,17 @@ COMMIT_SHA=`git rev-parse $RELEASE_TAG`
 mkdir -p $RELEASE_DIR
 git archive -o $RELEASE_FILE --prefix $RELEASE_BASE/ $RELEASE_TAG
 
+# expand archive, run broccoli in it, rebuild archive
+cd $RELEASE_DIR
+tar xzf $RELEASE_FILE
+cd $RELEASE_FILE_EXTRACTED
+npm install >/dev/null
+BROCCOLI_ENV=production broccoli build Allura/allura/public/nf/js/build/
+rm -rf node_modules
+cd ..
+tar czf $RELEASE_FILE $RELEASE_BASE
+rm -rf $RELEASE_FILE_EXTRACTED
+
 gpg --default-key $KEY --armor --output $RELEASE_FILE.asc --detach-sig $RELEASE_FILE
 MD5_CHECKSUM=`cd $RELEASE_DIR ; md5sum $RELEASE_FILENAME` ; echo "$MD5_CHECKSUM" > $RELEASE_FILE.md5
 SHA1_CHECKSUM=`cd $RELEASE_DIR ; shasum -a1 $RELEASE_FILENAME` ; echo "$SHA1_CHECKSUM" > $RELEASE_FILE.sha1


[3/5] allura git commit: [#7976] add & use npm run cmds for build & watch; add license header

Posted by he...@apache.org.
[#7976] add & use npm run cmds for build & watch; add license header


Project: http://git-wip-us.apache.org/repos/asf/allura/repo
Commit: http://git-wip-us.apache.org/repos/asf/allura/commit/d6a9114b
Tree: http://git-wip-us.apache.org/repos/asf/allura/tree/d6a9114b
Diff: http://git-wip-us.apache.org/repos/asf/allura/diff/d6a9114b

Branch: refs/heads/master
Commit: d6a9114b81ecc482e4216edcfd35f85eb5e397bb
Parents: 1dd7844
Author: Dave Brondsema <da...@brondsema.net>
Authored: Wed Sep 30 16:01:21 2015 -0400
Committer: Heith Seewald <hs...@hsmb.local>
Committed: Fri Oct 2 10:01:49 2015 -0400

----------------------------------------------------------------------
 Allura/docs/development/contributing.rst     |  2 +-
 Allura/docs/getting_started/installation.rst |  2 +-
 Brocfile.js                                  | 18 ++++++++++++++++++
 docker-compose.yml                           |  3 +--
 package.json                                 |  8 +++++---
 scripts/asf-release.sh                       |  2 +-
 6 files changed, 27 insertions(+), 8 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/allura/blob/d6a9114b/Allura/docs/development/contributing.rst
----------------------------------------------------------------------
diff --git a/Allura/docs/development/contributing.rst b/Allura/docs/development/contributing.rst
index e161fdb..73a9974 100644
--- a/Allura/docs/development/contributing.rst
+++ b/Allura/docs/development/contributing.rst
@@ -107,7 +107,7 @@ To transpile those files as soon as you edit them:
 
     ~$ npm install -g broccoli-timepiece
     ~$ cd ~/src/allura
-    ~$ broccoli-timepiece Allura/allura/public/nf/js/build/
+    ~$ npm run watch
 
 
 Finding Something to Work On

http://git-wip-us.apache.org/repos/asf/allura/blob/d6a9114b/Allura/docs/getting_started/installation.rst
----------------------------------------------------------------------
diff --git a/Allura/docs/getting_started/installation.rst b/Allura/docs/getting_started/installation.rst
index b28fca3..026da99 100644
--- a/Allura/docs/getting_started/installation.rst
+++ b/Allura/docs/getting_started/installation.rst
@@ -191,7 +191,7 @@ If you're using a released version of Allura, these are already done for you.  T
     (env-allura)~$ cd ~/src/allura
     (env-allura)~$ npm install -g broccoli-cli
     (env-allura)~$ npm install
-    (env-allura)~$ broccoli build Allura/allura/public/nf/js/build/
+    (env-allura)~$ npm run build
 
 
 The application server

http://git-wip-us.apache.org/repos/asf/allura/blob/d6a9114b/Brocfile.js
----------------------------------------------------------------------
diff --git a/Brocfile.js b/Brocfile.js
index e16ee4c..93cab0b 100644
--- a/Brocfile.js
+++ b/Brocfile.js
@@ -1,3 +1,21 @@
+/*
+       Licensed to the Apache Software Foundation (ASF) under one
+       or more contributor license agreements.  See the NOTICE file
+       distributed with this work for additional information
+       regarding copyright ownership.  The ASF licenses this file
+       to you under the Apache License, Version 2.0 (the
+       "License"); you may not use this file except in compliance
+       with the License.  You may obtain a copy of the License at
+
+         http://www.apache.org/licenses/LICENSE-2.0
+
+       Unless required by applicable law or agreed to in writing,
+       software distributed under the License is distributed on an
+       "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+       KIND, either express or implied.  See the License for the
+       specific language governing permissions and limitations
+       under the License.
+*/
 var babelTranspiler = require("broccoli-babel-transpiler");
 var sourceMap = require('broccoli-source-map');
 var concat = require('broccoli-concat');

http://git-wip-us.apache.org/repos/asf/allura/blob/d6a9114b/docker-compose.yml
----------------------------------------------------------------------
diff --git a/docker-compose.yml b/docker-compose.yml
index 86102ed..faac4a4 100644
--- a/docker-compose.yml
+++ b/docker-compose.yml
@@ -24,8 +24,7 @@ web:
     sh -c '
     if [ ! -e Allura/allura/public/nf/js/build/transpiled.js ]; then
       npm install &&
-      rm -rf Allura/allura/public/nf/js/build/ &&
-      broccoli build Allura/allura/public/nf/js/build/;
+      npm run build;
     fi;
     gunicorn --paste Allura/docker-dev.ini --reload
     '

http://git-wip-us.apache.org/repos/asf/allura/blob/d6a9114b/package.json
----------------------------------------------------------------------
diff --git a/package.json b/package.json
index 58dcc6b..95fa5ac 100644
--- a/package.json
+++ b/package.json
@@ -1,16 +1,18 @@
 {
   "name": "allura",
   "version": "0.0.0",
-  "description": "",
+  "description": "Apache Allura's JavaScript tooling",
   "main": "Brocfile.js",
   "scripts": {
-    "test": "echo \"Error: no test specified\" && exit 1"
+    "test": "echo \"Error: no test specified\" && exit 1",
+    "build": "rm -rf Allura/allura/public/nf/js/build/; broccoli build Allura/allura/public/nf/js/build/",
+    "watch": "broccoli-timepiece Allura/allura/public/nf/js/build/"
   },
   "repository": {
     "type": "git",
     "url": "https://git-wip-us.apache.org/repos/asf/allura.git"
   },
-  "author": "",
+  "author": "Apache Allura team",
   "license": "Apache-2.0",
   "devDependencies": {
     "broccoli": "^0.16.8",

http://git-wip-us.apache.org/repos/asf/allura/blob/d6a9114b/scripts/asf-release.sh
----------------------------------------------------------------------
diff --git a/scripts/asf-release.sh b/scripts/asf-release.sh
index 8ee73a4..cd1e347 100755
--- a/scripts/asf-release.sh
+++ b/scripts/asf-release.sh
@@ -74,7 +74,7 @@ cd $RELEASE_DIR
 tar xzf $RELEASE_FILE
 cd $RELEASE_FILE_EXTRACTED
 npm install >/dev/null
-BROCCOLI_ENV=production broccoli build Allura/allura/public/nf/js/build/
+BROCCOLI_ENV=production npm run build
 rm -rf node_modules
 cd ..
 tar czf $RELEASE_FILE $RELEASE_BASE


[2/5] allura git commit: [#7976] no caching of resources during development - particularly needed since Chrome caches sourcemaps even if dev tools has caching off

Posted by he...@apache.org.
[#7976] no caching of resources during development - particularly needed since Chrome caches sourcemaps even if dev tools has caching off


Project: http://git-wip-us.apache.org/repos/asf/allura/repo
Commit: http://git-wip-us.apache.org/repos/asf/allura/commit/34e5195c
Tree: http://git-wip-us.apache.org/repos/asf/allura/tree/34e5195c
Diff: http://git-wip-us.apache.org/repos/asf/allura/diff/34e5195c

Branch: refs/heads/master
Commit: 34e5195c9c6bb3c502b7c439354cb2742146ad87
Parents: 79b2b98
Author: Dave Brondsema <da...@brondsema.net>
Authored: Mon Sep 28 13:48:49 2015 -0400
Committer: Heith Seewald <hs...@hsmb.local>
Committed: Fri Oct 2 10:01:48 2015 -0400

----------------------------------------------------------------------
 Allura/allura/config/middleware.py | 4 +++-
 Allura/development.ini             | 4 ++++
 2 files changed, 7 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/allura/blob/34e5195c/Allura/allura/config/middleware.py
----------------------------------------------------------------------
diff --git a/Allura/allura/config/middleware.py b/Allura/allura/config/middleware.py
index 6c39d4b..5ce50a3 100644
--- a/Allura/allura/config/middleware.py
+++ b/Allura/allura/config/middleware.py
@@ -158,7 +158,9 @@ def _make_core_app(root, global_conf, full_stack=True, **app_conf):
         # compress=True,
         script_name=app_conf.get('ew.script_name', '/_ew_resources/'),
         url_base=app_conf.get('ew.url_base', '/_ew_resources/'),
-        extra_headers=eval(app_conf.get('ew.extra_headers', 'None')))
+        extra_headers=eval(app_conf.get('ew.extra_headers', 'None')),
+        cache_max_age=asint(app_conf.get('ew.cache_header_seconds', 60*60*24*365)),
+    )
     # Handle static files (by tool)
     app = StaticFilesMiddleware(app, app_conf.get('static.script_name'))
     # Handle setup and flushing of Ming ORM sessions

http://git-wip-us.apache.org/repos/asf/allura/blob/34e5195c/Allura/development.ini
----------------------------------------------------------------------
diff --git a/Allura/development.ini b/Allura/development.ini
index aee8bca..4c540d5 100644
--- a/Allura/development.ini
+++ b/Allura/development.ini
@@ -260,7 +260,11 @@ static.url_base = /nf/%(build_key)s/_static_/
 ; Expires header for "static" resources served through allura (e.g. icons, attachments, /nf/tool_icon_css)
 files_expires_header_secs = 1209600 ; 2 weeks
 
+; EasyWidgets settings
+; This CORS header is necessary if serving webfonts via a different domain
 ew.extra_headers = [ ('Access-Control-Allow-Origin', '*') ]
+; In production, comment this out and it will default to 1 year.  Update build_key whenever you deploy new code, instead.
+ew.cache_header_seconds = 0
 
 ; If your environment (e.g. behind a server-side proxy) needs to look at an http header to get the actual remote addr
 ;ip_address_header = X-Forwarded-For


[4/5] allura git commit: [#7976] concat sourcemaps together properly

Posted by he...@apache.org.
[#7976] concat sourcemaps together properly


Project: http://git-wip-us.apache.org/repos/asf/allura/repo
Commit: http://git-wip-us.apache.org/repos/asf/allura/commit/cd63778f
Tree: http://git-wip-us.apache.org/repos/asf/allura/tree/cd63778f
Diff: http://git-wip-us.apache.org/repos/asf/allura/diff/cd63778f

Branch: refs/heads/master
Commit: cd63778f4c93bf7a3503f41ffef9a88857058c01
Parents: d6a9114
Author: Dave Brondsema <da...@brondsema.net>
Authored: Thu Oct 1 14:54:33 2015 -0400
Committer: Heith Seewald <hs...@hsmb.local>
Committed: Fri Oct 2 10:01:49 2015 -0400

----------------------------------------------------------------------
 Brocfile.js  | 8 +++-----
 package.json | 3 +--
 2 files changed, 4 insertions(+), 7 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/allura/blob/cd63778f/Brocfile.js
----------------------------------------------------------------------
diff --git a/Brocfile.js b/Brocfile.js
index 93cab0b..71a8f90 100644
--- a/Brocfile.js
+++ b/Brocfile.js
@@ -17,8 +17,7 @@
        under the License.
 */
 var babelTranspiler = require("broccoli-babel-transpiler");
-var sourceMap = require('broccoli-source-map');
-var concat = require('broccoli-concat');
+var sourceMapConcat = require('broccoli-sourcemap-concat');
 var funnel = require('broccoli-funnel');
 var uglifyJavaScript = require('broccoli-uglify-js');
 
@@ -31,11 +30,10 @@ tree = babelTranspiler(tree, {
     sourceMaps: 'inline',  // external doesn't work, have to use extract below
     comments: false,
 });
-tree = concat(tree, {
-  inputFiles: ['**/*.js'],
+tree = sourceMapConcat(tree, {
+  inputFiles: ['**/*'],
   outputFile: '/transpiled.js'
 });
-tree = sourceMap.extract(tree);
 
 if (process.env.BROCCOLI_ENV === 'production') {
     /* can't use this for dev mode, since it drops the sourcemap comment even if we set  output: {comments: true}

http://git-wip-us.apache.org/repos/asf/allura/blob/cd63778f/package.json
----------------------------------------------------------------------
diff --git a/package.json b/package.json
index 95fa5ac..f850f00 100644
--- a/package.json
+++ b/package.json
@@ -17,9 +17,8 @@
   "devDependencies": {
     "broccoli": "^0.16.8",
     "broccoli-babel-transpiler": "^5.4.5",
-    "broccoli-concat": "0.0.13",
     "broccoli-funnel": "^0.2.8",
-    "broccoli-source-map": "^0.2.3",
+    "broccoli-sourcemap-concat": "^2.0.1",
     "broccoli-uglify-js": "^0.1.3"
   }
 }


[5/5] allura git commit: fix JS error when viewing ticket list page that has no tickets

Posted by he...@apache.org.
fix JS error when viewing ticket list page that has no tickets


Project: http://git-wip-us.apache.org/repos/asf/allura/repo
Commit: http://git-wip-us.apache.org/repos/asf/allura/commit/70001e20
Tree: http://git-wip-us.apache.org/repos/asf/allura/tree/70001e20
Diff: http://git-wip-us.apache.org/repos/asf/allura/diff/70001e20

Branch: refs/heads/master
Commit: 70001e2016b993aa2863b2b2a3a53ef55d691dfc
Parents: cd63778
Author: Dave Brondsema <da...@brondsema.net>
Authored: Thu Oct 1 14:54:50 2015 -0400
Committer: Heith Seewald <hs...@hsmb.local>
Committed: Fri Oct 2 10:01:49 2015 -0400

----------------------------------------------------------------------
 ForgeTracker/forgetracker/widgets/resources/js/ticket-list.js | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/allura/blob/70001e20/ForgeTracker/forgetracker/widgets/resources/js/ticket-list.js
----------------------------------------------------------------------
diff --git a/ForgeTracker/forgetracker/widgets/resources/js/ticket-list.js b/ForgeTracker/forgetracker/widgets/resources/js/ticket-list.js
index 9221389..9d060e6 100644
--- a/ForgeTracker/forgetracker/widgets/resources/js/ticket-list.js
+++ b/ForgeTracker/forgetracker/widgets/resources/js/ticket-list.js
@@ -150,7 +150,10 @@
     });
 
     function select_active_filter() {
-      /* this 'filter' var is set in HTML */
+      /* this 'filter' var is set in HTML on list pages (if there are tickets) */
+      if (typeof filter === 'undefined') {
+          return;
+      }
       for (var name in filter) {
         var fname = 'filter-' + name;
         var $select = $('select[name="' + fname + '"]');