You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@buildr.apache.org by do...@apache.org on 2014/11/10 22:49:11 UTC

buildr git commit: Update ipr.add_gwt_configuration method to support GWT 2.7 configuration parameters and IDEA 14 parameters.

Repository: buildr
Updated Branches:
  refs/heads/master 67d9bcc7c -> af4bdbc76


Update ipr.add_gwt_configuration method to support GWT 2.7 configuration parameters and IDEA 14 parameters.


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

Branch: refs/heads/master
Commit: af4bdbc766a31f33a627cc593ae4893882f89972
Parents: 67d9bcc
Author: Peter Donald <pe...@realityforge.org>
Authored: Tue Nov 11 08:49:05 2014 +1100
Committer: Peter Donald <pe...@realityforge.org>
Committed: Tue Nov 11 08:49:05 2014 +1100

----------------------------------------------------------------------
 CHANGELOG              |  2 ++
 lib/buildr/ide/idea.rb | 28 ++++++++++++++++++++++------
 2 files changed, 24 insertions(+), 6 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/buildr/blob/af4bdbc7/CHANGELOG
----------------------------------------------------------------------
diff --git a/CHANGELOG b/CHANGELOG
index 51e9faf..e6d3a6b 100644
--- a/CHANGELOG
+++ b/CHANGELOG
@@ -1,4 +1,6 @@
 1.4.21 (Pending)
+* Change: Update ipr.add_gwt_configuration method to support GWT 2.7 configuration
+          parameters and IDEA 14 parameters.
 * Change: Upgrade jacoco to 0.7.2. Submitted by neher.
 * Change: Update checkstyle addon to use Checkstyle 6.0.
 * Added:  Updated the gwt addon to support the upcoming GWT 2.7.x release.

http://git-wip-us.apache.org/repos/asf/buildr/blob/af4bdbc7/lib/buildr/ide/idea.rb
----------------------------------------------------------------------
diff --git a/lib/buildr/ide/idea.rb b/lib/buildr/ide/idea.rb
index 5da6f98..3258409 100644
--- a/lib/buildr/ide/idea.rb
+++ b/lib/buildr/ide/idea.rb
@@ -905,19 +905,35 @@ module Buildr #:nodoc:
         end
       end
 
-      def add_gwt_configuration(launch_page, project, options = {})
-        name = options[:name] || "Run #{launch_page}"
-        shell_parameters = options[:shell_parameters] || ''
+      def add_gwt_configuration(project, options = {})
+        launch_page = options[:launch_page]
+        name = options[:name] || (launch_page ? "Run #{launch_page}" : "Run #{project.name} DevMode")
+        shell_parameters = options[:shell_parameters]
         vm_parameters = options[:vm_parameters] || '-Xmx512m'
+        singleton = options[:singleton].nil? ? true : !!options[:singleton]
+        super_dev = options[:super_dev].nil? ? true : !!options[:super_dev]
 
-        add_configuration(name, 'GWT.ConfigurationType', 'GWT Configuration') do |xml|
+        start_javascript_debugger = options[:start_javascript_debugger].nil? ? true : !!options[:start_javascript_debugger]
+
+        add_configuration(name, 'GWT.ConfigurationType', 'GWT Configuration', false, :singleton => singleton) do |xml|
           xml.module(:name => project.iml.id)
-          xml.option(:name => 'RUN_PAGE', :value => launch_page)
-          xml.option(:name => 'SHELL_PARAMETERS', :value => shell_parameters)
+
           xml.option(:name => 'VM_PARAMETERS', :value => vm_parameters)
+          xml.option(:name => 'RUN_PAGE', :value => launch_page) if launch_page
+
+          xml.option(:name => 'START_JAVASCRIPT_DEBUGGER', :value => start_javascript_debugger)
+          xml.option(:name => 'USE_SUPER_DEV_MODE', :value => super_dev)
+          xml.option(:name => 'SHELL_PARAMETERS', :value => shell_parameters) if shell_parameters
+
+          xml.RunnerSettings(:RunnerId => 'Debug') do |xml|
+            xml.option(:name => 'DEBUG_PORT', :value => '')
+            xml.option(:name => 'TRANSPORT', :value => 0)
+            xml.option(:name => 'LOCAL', :value => true)
+          end
 
           xml.RunnerSettings(:RunnerId => 'Run')
           xml.ConfigurationWrapper(:RunnerId => 'Run')
+          xml.ConfigurationWrapper(:RunnerId => 'Debug')
           xml.method()
         end
       end