Repository: polygene-java
Updated Branches:
  refs/heads/develop 2bdc626a3 -> a4a4f0738


tools/generator-polygene makes Rat™ happy


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

Branch: refs/heads/develop
Commit: a4a4f0738b7be3237a8833955bdd12d45fae9220
Parents: 2bdc626
Author: Paul Merlin <[email protected]>
Authored: Sun Apr 23 18:00:13 2017 +0200
Committer: Paul Merlin <[email protected]>
Committed: Sun Apr 23 18:00:13 2017 +0200

----------------------------------------------------------------------
 .../distributions/DistributionsPlugin.groovy      |  3 +++
 .../gradle/structure/tools/NpmToolPlugin.groovy   |  2 --
 .../app/templates/CommandLineApplication/app.js   | 17 +++++++++++++++++
 .../ConfigurationLayer/ConfigModule/module.js     | 17 +++++++++++++++++
 .../app/templates/ConfigurationLayer/layer.js     | 17 +++++++++++++++++
 .../ConnectivityLayer/RestApiModule/module.js     | 17 +++++++++++++++++
 .../app/templates/ConnectivityLayer/layer.js      | 17 +++++++++++++++++
 .../templates/DomainLayer/CrudModule/module.js    | 17 +++++++++++++++++
 .../templates/DomainLayer/DomainModule/module.js  | 18 ++++++++++++++++++
 .../app/templates/DomainLayer/JmxModule/module.js | 18 ++++++++++++++++++
 .../DomainLayer/SecurityModule/module.js          | 18 ++++++++++++++++++
 .../app/templates/DomainLayer/layer.js            | 17 +++++++++++++++++
 .../InfrastructureLayer/CachingModule/module.js   | 17 +++++++++++++++++
 .../FileConfigurationModule/module.js             | 18 ++++++++++++++++++
 .../InfrastructureLayer/IndexingModule/module.js  | 18 ++++++++++++++++++
 .../InfrastructureLayer/MetricsModule/module.js   | 18 ++++++++++++++++++
 .../SerializationModule/module.js                 | 18 ++++++++++++++++++
 .../InfrastructureLayer/StorageModule/module.js   | 18 ++++++++++++++++++
 .../app/templates/InfrastructureLayer/layer.js    | 17 +++++++++++++++++
 .../app/templates/RestAPIApplication/app.js       | 18 ++++++++++++++++++
 .../CommandLineModule/module.js                   | 17 +++++++++++++++++
 .../app/templates/UserInterfaceLayer/layer.js     | 17 +++++++++++++++++
 .../app/templates/buildtool/build.js              | 18 ++++++++++++++++++
 tools/generator-polygene/build.gradle             | 16 +++++++++++-----
 tools/generator-polygene/test/generator_test.js   | 18 ++++++++++++++++++
 25 files changed, 399 insertions(+), 7 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/polygene-java/blob/a4a4f073/buildSrc/src/main/groovy/org/apache/polygene/gradle/structure/distributions/DistributionsPlugin.groovy
----------------------------------------------------------------------
diff --git 
a/buildSrc/src/main/groovy/org/apache/polygene/gradle/structure/distributions/DistributionsPlugin.groovy
 
b/buildSrc/src/main/groovy/org/apache/polygene/gradle/structure/distributions/DistributionsPlugin.groovy
index fc03c76..80b940c 100644
--- 
a/buildSrc/src/main/groovy/org/apache/polygene/gradle/structure/distributions/DistributionsPlugin.groovy
+++ 
b/buildSrc/src/main/groovy/org/apache/polygene/gradle/structure/distributions/DistributionsPlugin.groovy
@@ -156,6 +156,7 @@ class DistributionsPlugin implements Plugin<Project>
       spec.exclude '**/.git*'                // Git files
       spec.exclude '**/.gradle/**'           // Gradle caches
       spec.exclude '**/.gradletasknamecache' // Gradle shell completion cache
+      spec.exclude '**/node_modules/**'      // Node's node_module dir
 
       spec.into '.'
     }
@@ -265,6 +266,8 @@ class DistributionsPlugin implements Plugin<Project>
         '**/src/test/resources/**/*.txt',
         'libraries/rest-server/src/main/resources/**/*.htm',
         'libraries/rest-server/src/main/resources/**/*.atom',
+        'tools/generator-polygene/app/templates/**/*.tmpl',
+        'tools/generator-polygene/app/templates/**/*.*_',
         'tools/qidea/src/main/resources/**/*.ft',
         'tools/qidea/src/main/resources/**/*.template',
         // Graphic Resources

http://git-wip-us.apache.org/repos/asf/polygene-java/blob/a4a4f073/buildSrc/src/main/groovy/org/apache/polygene/gradle/structure/tools/NpmToolPlugin.groovy
----------------------------------------------------------------------
diff --git 
a/buildSrc/src/main/groovy/org/apache/polygene/gradle/structure/tools/NpmToolPlugin.groovy
 
b/buildSrc/src/main/groovy/org/apache/polygene/gradle/structure/tools/NpmToolPlugin.groovy
index fde64e9..48c4f19 100644
--- 
a/buildSrc/src/main/groovy/org/apache/polygene/gradle/structure/tools/NpmToolPlugin.groovy
+++ 
b/buildSrc/src/main/groovy/org/apache/polygene/gradle/structure/tools/NpmToolPlugin.groovy
@@ -37,8 +37,6 @@ class NpmToolPlugin implements Plugin<Project>
     def dependencies = project.rootProject.extensions.getByType( 
DependenciesDeclarationExtension )
     def node = project.extensions.getByType NodeExtension
     node.download = true
-    node.workDir = project.file( "${ project.buildDir }/node-install" )
-    node.npmWorkDir = node.workDir
     node.version = dependencies.nodeVersions.node
     node.npmVersion = dependencies.nodeVersions.npm
     project.tasks.withType( NpmTask ) { NpmTask task ->

http://git-wip-us.apache.org/repos/asf/polygene-java/blob/a4a4f073/tools/generator-polygene/app/templates/CommandLineApplication/app.js
----------------------------------------------------------------------
diff --git 
a/tools/generator-polygene/app/templates/CommandLineApplication/app.js 
b/tools/generator-polygene/app/templates/CommandLineApplication/app.js
index 53658a4..f3eb324 100644
--- a/tools/generator-polygene/app/templates/CommandLineApplication/app.js
+++ b/tools/generator-polygene/app/templates/CommandLineApplication/app.js
@@ -1,3 +1,20 @@
+/*
+ *  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.
+ */
 module.exports = {
 
     write: function (p) {

http://git-wip-us.apache.org/repos/asf/polygene-java/blob/a4a4f073/tools/generator-polygene/app/templates/ConfigurationLayer/ConfigModule/module.js
----------------------------------------------------------------------
diff --git 
a/tools/generator-polygene/app/templates/ConfigurationLayer/ConfigModule/module.js
 
b/tools/generator-polygene/app/templates/ConfigurationLayer/ConfigModule/module.js
index 690f715..5056397 100644
--- 
a/tools/generator-polygene/app/templates/ConfigurationLayer/ConfigModule/module.js
+++ 
b/tools/generator-polygene/app/templates/ConfigurationLayer/ConfigModule/module.js
@@ -1,3 +1,20 @@
+/*
+ *  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.
+ */
 module.exports = {
 
     write: function (p) {

http://git-wip-us.apache.org/repos/asf/polygene-java/blob/a4a4f073/tools/generator-polygene/app/templates/ConfigurationLayer/layer.js
----------------------------------------------------------------------
diff --git a/tools/generator-polygene/app/templates/ConfigurationLayer/layer.js 
b/tools/generator-polygene/app/templates/ConfigurationLayer/layer.js
index 06a3e31..9f00ed8 100644
--- a/tools/generator-polygene/app/templates/ConfigurationLayer/layer.js
+++ b/tools/generator-polygene/app/templates/ConfigurationLayer/layer.js
@@ -1,3 +1,20 @@
+/*
+ *  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.
+ */
 
 module.exports = {
 

http://git-wip-us.apache.org/repos/asf/polygene-java/blob/a4a4f073/tools/generator-polygene/app/templates/ConnectivityLayer/RestApiModule/module.js
----------------------------------------------------------------------
diff --git 
a/tools/generator-polygene/app/templates/ConnectivityLayer/RestApiModule/module.js
 
b/tools/generator-polygene/app/templates/ConnectivityLayer/RestApiModule/module.js
index 4a2af7d..8d4ad47 100644
--- 
a/tools/generator-polygene/app/templates/ConnectivityLayer/RestApiModule/module.js
+++ 
b/tools/generator-polygene/app/templates/ConnectivityLayer/RestApiModule/module.js
@@ -1,3 +1,20 @@
+/*
+ *  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.
+ */
 
 module.exports = {
 

http://git-wip-us.apache.org/repos/asf/polygene-java/blob/a4a4f073/tools/generator-polygene/app/templates/ConnectivityLayer/layer.js
----------------------------------------------------------------------
diff --git a/tools/generator-polygene/app/templates/ConnectivityLayer/layer.js 
b/tools/generator-polygene/app/templates/ConnectivityLayer/layer.js
index 6a0e9b3..a9d2a9b 100644
--- a/tools/generator-polygene/app/templates/ConnectivityLayer/layer.js
+++ b/tools/generator-polygene/app/templates/ConnectivityLayer/layer.js
@@ -1,3 +1,20 @@
+/*
+ *  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.
+ */
 
 module.exports = {
 

http://git-wip-us.apache.org/repos/asf/polygene-java/blob/a4a4f073/tools/generator-polygene/app/templates/DomainLayer/CrudModule/module.js
----------------------------------------------------------------------
diff --git 
a/tools/generator-polygene/app/templates/DomainLayer/CrudModule/module.js 
b/tools/generator-polygene/app/templates/DomainLayer/CrudModule/module.js
index 6c930d9..4689e13 100644
--- a/tools/generator-polygene/app/templates/DomainLayer/CrudModule/module.js
+++ b/tools/generator-polygene/app/templates/DomainLayer/CrudModule/module.js
@@ -1,3 +1,20 @@
+/*
+ *  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.
+ */
 
 module.exports = {
 

http://git-wip-us.apache.org/repos/asf/polygene-java/blob/a4a4f073/tools/generator-polygene/app/templates/DomainLayer/DomainModule/module.js
----------------------------------------------------------------------
diff --git 
a/tools/generator-polygene/app/templates/DomainLayer/DomainModule/module.js 
b/tools/generator-polygene/app/templates/DomainLayer/DomainModule/module.js
index 03e2040..8855bc3 100644
--- a/tools/generator-polygene/app/templates/DomainLayer/DomainModule/module.js
+++ b/tools/generator-polygene/app/templates/DomainLayer/DomainModule/module.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.
+ */
+
 module.exports = {
 
     write: function (p) {

http://git-wip-us.apache.org/repos/asf/polygene-java/blob/a4a4f073/tools/generator-polygene/app/templates/DomainLayer/JmxModule/module.js
----------------------------------------------------------------------
diff --git 
a/tools/generator-polygene/app/templates/DomainLayer/JmxModule/module.js 
b/tools/generator-polygene/app/templates/DomainLayer/JmxModule/module.js
index 8857c34..18d1f00 100644
--- a/tools/generator-polygene/app/templates/DomainLayer/JmxModule/module.js
+++ b/tools/generator-polygene/app/templates/DomainLayer/JmxModule/module.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.
+ */
+
 module.exports = {
 
     write: function (p) {

http://git-wip-us.apache.org/repos/asf/polygene-java/blob/a4a4f073/tools/generator-polygene/app/templates/DomainLayer/SecurityModule/module.js
----------------------------------------------------------------------
diff --git 
a/tools/generator-polygene/app/templates/DomainLayer/SecurityModule/module.js 
b/tools/generator-polygene/app/templates/DomainLayer/SecurityModule/module.js
index 1ba7360..fed3dd6 100644
--- 
a/tools/generator-polygene/app/templates/DomainLayer/SecurityModule/module.js
+++ 
b/tools/generator-polygene/app/templates/DomainLayer/SecurityModule/module.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.
+ */
+
 module.exports = {
 
     write: function (p) {

http://git-wip-us.apache.org/repos/asf/polygene-java/blob/a4a4f073/tools/generator-polygene/app/templates/DomainLayer/layer.js
----------------------------------------------------------------------
diff --git a/tools/generator-polygene/app/templates/DomainLayer/layer.js 
b/tools/generator-polygene/app/templates/DomainLayer/layer.js
index 3a32039..7ed9307 100644
--- a/tools/generator-polygene/app/templates/DomainLayer/layer.js
+++ b/tools/generator-polygene/app/templates/DomainLayer/layer.js
@@ -1,3 +1,20 @@
+/*
+ *  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.
+ */
 
 module.exports = {
 

http://git-wip-us.apache.org/repos/asf/polygene-java/blob/a4a4f073/tools/generator-polygene/app/templates/InfrastructureLayer/CachingModule/module.js
----------------------------------------------------------------------
diff --git 
a/tools/generator-polygene/app/templates/InfrastructureLayer/CachingModule/module.js
 
b/tools/generator-polygene/app/templates/InfrastructureLayer/CachingModule/module.js
index fdc99b0..70be49c 100644
--- 
a/tools/generator-polygene/app/templates/InfrastructureLayer/CachingModule/module.js
+++ 
b/tools/generator-polygene/app/templates/InfrastructureLayer/CachingModule/module.js
@@ -1,3 +1,20 @@
+/*
+ *  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.
+ */
 
 module.exports = {
 

http://git-wip-us.apache.org/repos/asf/polygene-java/blob/a4a4f073/tools/generator-polygene/app/templates/InfrastructureLayer/FileConfigurationModule/module.js
----------------------------------------------------------------------
diff --git 
a/tools/generator-polygene/app/templates/InfrastructureLayer/FileConfigurationModule/module.js
 
b/tools/generator-polygene/app/templates/InfrastructureLayer/FileConfigurationModule/module.js
index 7ce44ef..3caecab 100644
--- 
a/tools/generator-polygene/app/templates/InfrastructureLayer/FileConfigurationModule/module.js
+++ 
b/tools/generator-polygene/app/templates/InfrastructureLayer/FileConfigurationModule/module.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.
+ */
+
 module.exports = {
 
     write: function (p) {

http://git-wip-us.apache.org/repos/asf/polygene-java/blob/a4a4f073/tools/generator-polygene/app/templates/InfrastructureLayer/IndexingModule/module.js
----------------------------------------------------------------------
diff --git 
a/tools/generator-polygene/app/templates/InfrastructureLayer/IndexingModule/module.js
 
b/tools/generator-polygene/app/templates/InfrastructureLayer/IndexingModule/module.js
index e34ef57..9d7f4e4 100644
--- 
a/tools/generator-polygene/app/templates/InfrastructureLayer/IndexingModule/module.js
+++ 
b/tools/generator-polygene/app/templates/InfrastructureLayer/IndexingModule/module.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.
+ */
+
 module.exports = {
 
     write: function (p) {

http://git-wip-us.apache.org/repos/asf/polygene-java/blob/a4a4f073/tools/generator-polygene/app/templates/InfrastructureLayer/MetricsModule/module.js
----------------------------------------------------------------------
diff --git 
a/tools/generator-polygene/app/templates/InfrastructureLayer/MetricsModule/module.js
 
b/tools/generator-polygene/app/templates/InfrastructureLayer/MetricsModule/module.js
index 6100c5c..2d426b9 100644
--- 
a/tools/generator-polygene/app/templates/InfrastructureLayer/MetricsModule/module.js
+++ 
b/tools/generator-polygene/app/templates/InfrastructureLayer/MetricsModule/module.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.
+ */
+
 module.exports = {
 
     write: function (p) {

http://git-wip-us.apache.org/repos/asf/polygene-java/blob/a4a4f073/tools/generator-polygene/app/templates/InfrastructureLayer/SerializationModule/module.js
----------------------------------------------------------------------
diff --git 
a/tools/generator-polygene/app/templates/InfrastructureLayer/SerializationModule/module.js
 
b/tools/generator-polygene/app/templates/InfrastructureLayer/SerializationModule/module.js
index 4264bd4..6afd62e 100644
--- 
a/tools/generator-polygene/app/templates/InfrastructureLayer/SerializationModule/module.js
+++ 
b/tools/generator-polygene/app/templates/InfrastructureLayer/SerializationModule/module.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.
+ */
+
 module.exports = {
 
     write: function (p) {

http://git-wip-us.apache.org/repos/asf/polygene-java/blob/a4a4f073/tools/generator-polygene/app/templates/InfrastructureLayer/StorageModule/module.js
----------------------------------------------------------------------
diff --git 
a/tools/generator-polygene/app/templates/InfrastructureLayer/StorageModule/module.js
 
b/tools/generator-polygene/app/templates/InfrastructureLayer/StorageModule/module.js
index 51488e0..3c17fcc 100644
--- 
a/tools/generator-polygene/app/templates/InfrastructureLayer/StorageModule/module.js
+++ 
b/tools/generator-polygene/app/templates/InfrastructureLayer/StorageModule/module.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.
+ */
+
 module.exports = {
 
     write: function (p) {

http://git-wip-us.apache.org/repos/asf/polygene-java/blob/a4a4f073/tools/generator-polygene/app/templates/InfrastructureLayer/layer.js
----------------------------------------------------------------------
diff --git 
a/tools/generator-polygene/app/templates/InfrastructureLayer/layer.js 
b/tools/generator-polygene/app/templates/InfrastructureLayer/layer.js
index ca844d1..8e7930c 100644
--- a/tools/generator-polygene/app/templates/InfrastructureLayer/layer.js
+++ b/tools/generator-polygene/app/templates/InfrastructureLayer/layer.js
@@ -1,3 +1,20 @@
+/*
+ *  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.
+ */
 
 module.exports = {
 

http://git-wip-us.apache.org/repos/asf/polygene-java/blob/a4a4f073/tools/generator-polygene/app/templates/RestAPIApplication/app.js
----------------------------------------------------------------------
diff --git a/tools/generator-polygene/app/templates/RestAPIApplication/app.js 
b/tools/generator-polygene/app/templates/RestAPIApplication/app.js
index efbcea8..80380c7 100644
--- a/tools/generator-polygene/app/templates/RestAPIApplication/app.js
+++ b/tools/generator-polygene/app/templates/RestAPIApplication/app.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.
+ */
+
 module.exports = {
 
     write: function (p) {

http://git-wip-us.apache.org/repos/asf/polygene-java/blob/a4a4f073/tools/generator-polygene/app/templates/UserInterfaceLayer/CommandLineModule/module.js
----------------------------------------------------------------------
diff --git 
a/tools/generator-polygene/app/templates/UserInterfaceLayer/CommandLineModule/module.js
 
b/tools/generator-polygene/app/templates/UserInterfaceLayer/CommandLineModule/module.js
index 41facd8..3da8821 100644
--- 
a/tools/generator-polygene/app/templates/UserInterfaceLayer/CommandLineModule/module.js
+++ 
b/tools/generator-polygene/app/templates/UserInterfaceLayer/CommandLineModule/module.js
@@ -1,3 +1,20 @@
+/*
+ *  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.
+ */
 
 module.exports = {
 

http://git-wip-us.apache.org/repos/asf/polygene-java/blob/a4a4f073/tools/generator-polygene/app/templates/UserInterfaceLayer/layer.js
----------------------------------------------------------------------
diff --git a/tools/generator-polygene/app/templates/UserInterfaceLayer/layer.js 
b/tools/generator-polygene/app/templates/UserInterfaceLayer/layer.js
index c060f63..36e0060 100644
--- a/tools/generator-polygene/app/templates/UserInterfaceLayer/layer.js
+++ b/tools/generator-polygene/app/templates/UserInterfaceLayer/layer.js
@@ -1,3 +1,20 @@
+/*
+ *  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.
+ */
 
 module.exports = {
 

http://git-wip-us.apache.org/repos/asf/polygene-java/blob/a4a4f073/tools/generator-polygene/app/templates/buildtool/build.js
----------------------------------------------------------------------
diff --git a/tools/generator-polygene/app/templates/buildtool/build.js 
b/tools/generator-polygene/app/templates/buildtool/build.js
index 7606514..630908f 100644
--- a/tools/generator-polygene/app/templates/buildtool/build.js
+++ b/tools/generator-polygene/app/templates/buildtool/build.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.
+ */
+
 module.exports = {
 
     write: function (p) {

http://git-wip-us.apache.org/repos/asf/polygene-java/blob/a4a4f073/tools/generator-polygene/build.gradle
----------------------------------------------------------------------
diff --git a/tools/generator-polygene/build.gradle 
b/tools/generator-polygene/build.gradle
index 119f702..518397c 100644
--- a/tools/generator-polygene/build.gradle
+++ b/tools/generator-polygene/build.gradle
@@ -30,7 +30,8 @@ def setsCurrentVersionToPackageJson = task( 
'setsCurrentVersionToPackageJson' )
   outputs.upToDateWhen { false }
   doLast {
     def packageJson = file( 'package.json' )
-    packageJson.text = packageJson.text.replaceFirst( /\"polygene_version\": 
\".*\"/, "\"polygene_version\": \"${project.version}\"" )
+    packageJson.text = packageJson.text.replaceFirst( /\"polygene_version\": 
\".*\"/,
+                                                      "\"polygene_version\": 
\"${ project.version }\"" )
   }
 }
 
@@ -49,9 +50,7 @@ def generateStageMavenRepositoryInitScript = task( 
'generateStageMavenRepository
     initScript.text = """
       allprojects {
         repositories {
-          maven {
-            url = "file://${ repoDir.absolutePath }"
-          }
+          maven { url = "file://${ repoDir.absolutePath }" }
         }
       }
     """.stripIndent()
@@ -69,10 +68,13 @@ def npmTest = task( 'npmTest', type: NpmTask ) {
   inputs.dir file( 'app' )
   inputs.dir file( 'test' )
   outputs.dir file( "${ buildDir }/reports/tests/npmTest" )
+  doFirst {
+    // Cleanup generated projects to always run from a fresh state
+    file( "$buildDir/build/npm-test" ).deleteDir()
+  }
 }
 check.dependsOn npmTest
 
-
 /**
  * Runs ALL the generator tests.
  */
@@ -84,4 +86,8 @@ task( 'npmTestAll', type: NpmTask ) {
   inputs.dir file( 'app' )
   inputs.dir file( 'test' )
   outputs.dir file( "${ buildDir }/reports/tests/npmTestAll" )
+  doFirst {
+    // Cleanup generated projects to always run from a fresh state
+    file( "$buildDir/build/npm-test" ).deleteDir()
+  }
 }

http://git-wip-us.apache.org/repos/asf/polygene-java/blob/a4a4f073/tools/generator-polygene/test/generator_test.js
----------------------------------------------------------------------
diff --git a/tools/generator-polygene/test/generator_test.js 
b/tools/generator-polygene/test/generator_test.js
index 4779b0a..d4ee454 100644
--- a/tools/generator-polygene/test/generator_test.js
+++ b/tools/generator-polygene/test/generator_test.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 path = require('path');
 var helpers = require('yeoman-test');
 var assert = require('yeoman-assert');

Reply via email to