heroku-vraptor-scaffold 0.9.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (148) hide show
  1. data/.gitignore +10 -0
  2. data/.travis.yml +6 -0
  3. data/CHANGELOG.rdoc +188 -0
  4. data/Gemfile +2 -0
  5. data/Gemfile.lock +30 -0
  6. data/LICENSE +22 -0
  7. data/README.md +23 -0
  8. data/README.textile +51 -0
  9. data/Rakefile +20 -0
  10. data/bin/heroku-vraptor +8 -0
  11. data/heroku-vraptor-scaffold.gemspec +28 -0
  12. data/index.sample.html +169 -0
  13. data/lib/vraptor-scaffold.rb +14 -0
  14. data/lib/vraptor-scaffold/configuration.rb +54 -0
  15. data/lib/vraptor-scaffold/execution.rb +22 -0
  16. data/lib/vraptor-scaffold/generators/app/app_generator.rb +161 -0
  17. data/lib/vraptor-scaffold/generators/app/dependency.rb +15 -0
  18. data/lib/vraptor-scaffold/generators/app/dependency_manager.rb +32 -0
  19. data/lib/vraptor-scaffold/generators/app/templates/angular/angular.js +14327 -0
  20. data/lib/vraptor-scaffold/generators/app/templates/bootstrap/bootstrap-responsive.css +9 -0
  21. data/lib/vraptor-scaffold/generators/app/templates/bootstrap/bootstrap.css +9 -0
  22. data/lib/vraptor-scaffold/generators/app/templates/bootstrap/bootstrap.js +6 -0
  23. data/lib/vraptor-scaffold/generators/app/templates/bootstrap/glyphicons-halflings-white.png +0 -0
  24. data/lib/vraptor-scaffold/generators/app/templates/bootstrap/glyphicons-halflings.png +0 -0
  25. data/lib/vraptor-scaffold/generators/app/templates/eclipse/classpath.erb +18 -0
  26. data/lib/vraptor-scaffold/generators/app/templates/eclipse/project.erb +36 -0
  27. data/lib/vraptor-scaffold/generators/app/templates/eclipse/settings/org.eclipse.jdt.core.prefs +8 -0
  28. data/lib/vraptor-scaffold/generators/app/templates/eclipse/settings/org.eclipse.wst.common.component.tt +10 -0
  29. data/lib/vraptor-scaffold/generators/app/templates/eclipse/settings/org.eclipse.wst.common.project.facet.core.xml +10 -0
  30. data/lib/vraptor-scaffold/generators/app/templates/eclipse/settings/org.eclipse.wst.jsdt.ui.superType.container +1 -0
  31. data/lib/vraptor-scaffold/generators/app/templates/eclipse/settings/org.eclipse.wst.jsdt.ui.superType.name +1 -0
  32. data/lib/vraptor-scaffold/generators/app/templates/heroku/Main.java +21 -0
  33. data/lib/vraptor-scaffold/generators/app/templates/heroku/Procfile +1 -0
  34. data/lib/vraptor-scaffold/generators/app/templates/jquery/jquery.min.js +4 -0
  35. data/lib/vraptor-scaffold/generators/app/templates/models/Entity.erb +46 -0
  36. data/lib/vraptor-scaffold/generators/app/templates/orm/Repository-hibernate.java.tt +50 -0
  37. data/lib/vraptor-scaffold/generators/app/templates/orm/Repository-jpa.java.tt +48 -0
  38. data/lib/vraptor-scaffold/generators/app/templates/orm/Repository-objectify.java.tt +41 -0
  39. data/lib/vraptor-scaffold/generators/app/templates/orm/hibernate.cfg.xml +7 -0
  40. data/lib/vraptor-scaffold/generators/app/templates/orm/persistence.xml +10 -0
  41. data/lib/vraptor-scaffold/generators/app/templates/pom.erb +110 -0
  42. data/lib/vraptor-scaffold/generators/app/templates/resources-test/.empty_directory +0 -0
  43. data/lib/vraptor-scaffold/generators/app/templates/resources/hibernate.properties +16 -0
  44. data/lib/vraptor-scaffold/generators/app/templates/resources/log4j.properties +4 -0
  45. data/lib/vraptor-scaffold/generators/app/templates/resources/messages.properties +0 -0
  46. data/lib/vraptor-scaffold/generators/app/templates/underscore/underscore.min.js +32 -0
  47. data/lib/vraptor-scaffold/generators/app/templates/vraptor-scaffold.erb +5 -0
  48. data/lib/vraptor-scaffold/generators/app/templates/webapp/WEB-INF/web.xml.tt +33 -0
  49. data/lib/vraptor-scaffold/generators/app/templates/webapp/images/.empty_directory +0 -0
  50. data/lib/vraptor-scaffold/generators/app/templates/webapp/index.html +24 -0
  51. data/lib/vraptor-scaffold/generators/app/templates/webapp/javascripts/utils.js +7 -0
  52. data/lib/vraptor-scaffold/generators/base.rb +16 -0
  53. data/lib/vraptor-scaffold/generators/scaffold/attribute.rb +51 -0
  54. data/lib/vraptor-scaffold/generators/scaffold/base_scaffold.rb +54 -0
  55. data/lib/vraptor-scaffold/generators/scaffold/client_generator/client_generator.rb +41 -0
  56. data/lib/vraptor-scaffold/generators/scaffold/client_generator/templates/controller.erb +75 -0
  57. data/lib/vraptor-scaffold/generators/scaffold/client_generator/templates/details.erb +16 -0
  58. data/lib/vraptor-scaffold/generators/scaffold/client_generator/templates/form.erb +39 -0
  59. data/lib/vraptor-scaffold/generators/scaffold/client_generator/templates/list.erb +40 -0
  60. data/lib/vraptor-scaffold/generators/scaffold/controller_generator/controller_generator.rb +20 -0
  61. data/lib/vraptor-scaffold/generators/scaffold/controller_generator/templates/controller.erb +77 -0
  62. data/lib/vraptor-scaffold/generators/scaffold/controller_generator/templates/controller_test.erb +12 -0
  63. data/lib/vraptor-scaffold/generators/scaffold/model_generator/model_generator.rb +26 -0
  64. data/lib/vraptor-scaffold/generators/scaffold/model_generator/templates/model.erb +32 -0
  65. data/lib/vraptor-scaffold/generators/scaffold/model_generator/templates/model_test.erb +13 -0
  66. data/lib/vraptor-scaffold/generators/scaffold/repository_generator/repository_generator.rb +32 -0
  67. data/lib/vraptor-scaffold/generators/scaffold/repository_generator/templates/repository.erb +22 -0
  68. data/lib/vraptor-scaffold/generators/scaffold/repository_generator/templates/repository_impl.erb +16 -0
  69. data/lib/vraptor-scaffold/generators/scaffold/repository_generator/templates/repository_test.erb +13 -0
  70. data/lib/vraptor-scaffold/generators/scaffold/scaffold_generator.rb +35 -0
  71. data/lib/vraptor-scaffold/runner.rb +9 -0
  72. data/lib/vraptor-scaffold/runner/commands_help.rb +13 -0
  73. data/lib/vraptor-scaffold/runner/generator.rb +15 -0
  74. data/lib/vraptor-scaffold/runner/help.rb +12 -0
  75. data/lib/vraptor-scaffold/runner/scaffold.rb +16 -0
  76. data/lib/vraptor-scaffold/version.rb +3 -0
  77. data/maven/repo/br/com/caelum/vraptor-gae/1.0/vraptor-gae-1.0.jar +0 -0
  78. data/spec/resources/vraptor-scaffold-objectify.properties +7 -0
  79. data/spec/resources/vraptor-scaffold.properties +7 -0
  80. data/spec/spec.opts +4 -0
  81. data/spec/spec_helper.rb +31 -0
  82. data/spec/vraptor-scaffold/configuration_spec.rb +146 -0
  83. data/spec/vraptor-scaffold/execution_spec.rb +51 -0
  84. data/spec/vraptor-scaffold/generators/app/app_generator_spec.rb +557 -0
  85. data/spec/vraptor-scaffold/generators/app/dependency_manager_spec.rb +34 -0
  86. data/spec/vraptor-scaffold/generators/app/dependency_spec.rb +14 -0
  87. data/spec/vraptor-scaffold/generators/app/freemarker_template_engine_spec.rb +80 -0
  88. data/spec/vraptor-scaffold/generators/app/jsp_template_engine_spec.rb +77 -0
  89. data/spec/vraptor-scaffold/generators/app/templates/Entity.java +45 -0
  90. data/spec/vraptor-scaffold/generators/app/templates/FreemarkerPathResolver.java +21 -0
  91. data/spec/vraptor-scaffold/generators/app/templates/ObjectifyFactory.java +30 -0
  92. data/spec/vraptor-scaffold/generators/app/templates/RepositoryJPA.java +48 -0
  93. data/spec/vraptor-scaffold/generators/app/templates/RepositoryObjectify.java +41 -0
  94. data/spec/vraptor-scaffold/generators/app/templates/build.gradle +60 -0
  95. data/spec/vraptor-scaffold/generators/app/templates/build.properties +18 -0
  96. data/spec/vraptor-scaffold/generators/app/templates/build.xml +146 -0
  97. data/spec/vraptor-scaffold/generators/app/templates/classpath-gae +18 -0
  98. data/spec/vraptor-scaffold/generators/app/templates/decorators-jsp.xml +7 -0
  99. data/spec/vraptor-scaffold/generators/app/templates/decorators.xml +7 -0
  100. data/spec/vraptor-scaffold/generators/app/templates/freemarker-web.xml +60 -0
  101. data/spec/vraptor-scaffold/generators/app/templates/gae-jsp-web.xml +45 -0
  102. data/spec/vraptor-scaffold/generators/app/templates/ivy-gae.xml +45 -0
  103. data/spec/vraptor-scaffold/generators/app/templates/ivy.xml +40 -0
  104. data/spec/vraptor-scaffold/generators/app/templates/jsp-web.xml +45 -0
  105. data/spec/vraptor-scaffold/generators/app/templates/pom-heroku.xml +182 -0
  106. data/spec/vraptor-scaffold/generators/app/templates/pom.xml +157 -0
  107. data/spec/vraptor-scaffold/generators/app/templates/project-gae +47 -0
  108. data/spec/vraptor-scaffold/generators/app/templates/vraptor-scaffold.properties +7 -0
  109. data/spec/vraptor-scaffold/generators/plugin/expected_configs/build.gradle +62 -0
  110. data/spec/vraptor-scaffold/generators/plugin/expected_configs/default_org_build.gradle +62 -0
  111. data/spec/vraptor-scaffold/generators/plugin/expected_configs/default_org_ivy.xml +41 -0
  112. data/spec/vraptor-scaffold/generators/plugin/expected_configs/default_org_pom.xml +152 -0
  113. data/spec/vraptor-scaffold/generators/plugin/expected_configs/ivy.xml +42 -0
  114. data/spec/vraptor-scaffold/generators/plugin/expected_configs/pom.xml +182 -0
  115. data/spec/vraptor-scaffold/generators/scaffold/attribute_spec.rb +186 -0
  116. data/spec/vraptor-scaffold/generators/scaffold/base_scaffold_spec.rb +73 -0
  117. data/spec/vraptor-scaffold/generators/scaffold/client_controller_generator/controller_generator_spec.rb +62 -0
  118. data/spec/vraptor-scaffold/generators/scaffold/client_controller_generator/templates/ProductController.java +95 -0
  119. data/spec/vraptor-scaffold/generators/scaffold/controller_generator/controller_generator_spec.rb +62 -0
  120. data/spec/vraptor-scaffold/generators/scaffold/controller_generator/templates/ProductController.java +95 -0
  121. data/spec/vraptor-scaffold/generators/scaffold/freemarker_generator/freemarker_generator_spec.rb +81 -0
  122. data/spec/vraptor-scaffold/generators/scaffold/freemarker_generator/templates/form.ftl +28 -0
  123. data/spec/vraptor-scaffold/generators/scaffold/jsp_generator/jsp_generator_spec.rb +81 -0
  124. data/spec/vraptor-scaffold/generators/scaffold/jsp_generator/templates/form.jsp +61 -0
  125. data/spec/vraptor-scaffold/generators/scaffold/model_generator/model_generator_spec.rb +54 -0
  126. data/spec/vraptor-scaffold/generators/scaffold/model_generator/objectify_model_generator_spec.rb +40 -0
  127. data/spec/vraptor-scaffold/generators/scaffold/model_generator/templates/ObjectifyFactory.java +33 -0
  128. data/spec/vraptor-scaffold/generators/scaffold/model_generator/templates/Objectify_Product.java +38 -0
  129. data/spec/vraptor-scaffold/generators/scaffold/model_generator/templates/Product.java +25 -0
  130. data/spec/vraptor-scaffold/generators/scaffold/model_generator/templates/hibernate.cfg.xml +8 -0
  131. data/spec/vraptor-scaffold/generators/scaffold/repository_generator/objectify_repository_generator_spec.rb +33 -0
  132. data/spec/vraptor-scaffold/generators/scaffold/repository_generator/repository_generator_spec.rb +68 -0
  133. data/spec/vraptor-scaffold/generators/scaffold/repository_generator/templates/ClientRepository.java +22 -0
  134. data/spec/vraptor-scaffold/generators/scaffold/repository_generator/templates/ClientRepositoryImpl.java +16 -0
  135. data/spec/vraptor-scaffold/generators/scaffold/repository_generator/templates/Objectify_ProductRepository.java +22 -0
  136. data/spec/vraptor-scaffold/generators/scaffold/repository_generator/templates/Objectify_ProductRepositoryImpl.java +16 -0
  137. data/spec/vraptor-scaffold/generators/scaffold/repository_generator/templates/ProductRepository.java +22 -0
  138. data/spec/vraptor-scaffold/generators/scaffold/repository_generator/templates/ProductRepositoryImpl.java +16 -0
  139. data/spec/vraptor-scaffold/generators/scaffold/scaffold_generator_spec.rb +79 -0
  140. data/spec/vraptor-scaffold/http_request_spec.rb +40 -0
  141. data/spec/vraptor-scaffold/runner/commands_help_spec.rb +12 -0
  142. data/spec/vraptor-scaffold/runner/configure_spec.rb +12 -0
  143. data/spec/vraptor-scaffold/runner/generator_spec.rb +31 -0
  144. data/spec/vraptor-scaffold/runner/help_spec.rb +29 -0
  145. data/spec/vraptor-scaffold/runner/scaffold_spec.rb +35 -0
  146. data/spec/vraptor-scaffold/runner/start_spec.rb +51 -0
  147. data/spec/vraptor-scaffold_spec.rb +4 -0
  148. metadata +261 -0
@@ -0,0 +1,18 @@
1
+ project.name=vraptor-scaffold
2
+
3
+ output.dir=target
4
+ test.build.dir=target/test-classes
5
+
6
+ webapp.dir=src/main/webapp
7
+ js.dir=src/main/webapp/javascripts
8
+ css.dir=src/main/webapp/stylesheets
9
+ lib.dir=src/main/webapp/WEB-INF/lib
10
+ build.dir=src/main/webapp/WEB-INF/classes
11
+
12
+ src.dir=src/main/java
13
+ resources.dir=src/main/resources
14
+
15
+ test.src.dir=src/test/java
16
+ test.resources.dir=src/test/resources
17
+
18
+ ivy.jar.file=ivy-2.2.0.jar
@@ -0,0 +1,146 @@
1
+ <project name="vraptor-scaffold" default="war" xmlns:ivy="antlib:org.apache.ivy.ant">
2
+
3
+ <property file="build.properties" />
4
+
5
+ <!-- paths -->
6
+ <path id="lib.path.id">
7
+ <fileset dir="${lib.dir}" />
8
+ <fileset dir="lib/provided" />
9
+ </path>
10
+ <path id="test.path.id">
11
+ <fileset dir="lib/test" />
12
+ <path refid="lib.path.id" />
13
+ <pathelement location="${test.build.dir}" />
14
+ <pathelement location="${build.dir}" />
15
+ </path>
16
+
17
+ <!-- =================================
18
+ target: resolve
19
+ ================================= -->
20
+ <target name="resolve" description="--> retrieve dependencies with ivy">
21
+ <path id="ivy.lib.path">
22
+ <pathelement location="${ivy.jar.file}" />
23
+ </path>
24
+ <taskdef resource="org/apache/ivy/ant/antlib.xml" uri="antlib:org.apache.ivy.ant" classpathref="ivy.lib.path" />
25
+
26
+ <ivy:retrieve pattern="lib/[conf]/[artifact]-[revision].[ext]" sync="true" />
27
+ <delete dir="${lib.dir}" includes="**/*.*" />
28
+ <copy todir="${lib.dir}">
29
+ <fileset dir="lib/default">
30
+ <include name="*.jar" />
31
+ </fileset>
32
+ </copy>
33
+ </target>
34
+
35
+ <!-- =================================
36
+ target: compile
37
+ ================================= -->
38
+ <target name="compile" depends="resolve" description="--> compile">
39
+ <mkdir dir="${build.dir}" />
40
+ <delete dir="${build.dir}" includes="**/*.*" />
41
+ <javac srcdir="${src.dir}" destdir="${build.dir}" classpathref="lib.path.id" debug="on" />
42
+ <copy todir="${build.dir}">
43
+ <fileset dir="${resources.dir}">
44
+ <include name="**/*.*" />
45
+ </fileset>
46
+ </copy>
47
+ </target>
48
+
49
+ <!-- =================================
50
+ target: compile test
51
+ ================================= -->
52
+ <target name="compile-test" depends="compile" description="--> compile test">
53
+ <mkdir dir="${test.build.dir}" />
54
+ <delete dir="${test.build.dir}" includes="**/*.*" />
55
+ <javac srcdir="${test.src.dir}" destdir="${test.build.dir}" classpathref="test.path.id" debug="on" />
56
+ <copy todir="${test.build.dir}">
57
+ <fileset dir="${test.resources.dir}">
58
+ <include name="**/*.*" />
59
+ </fileset>
60
+ </copy>
61
+ </target>
62
+
63
+ <!-- =================================
64
+ target: run tests
65
+ ================================= -->
66
+ <target name="test" depends="compile-test" description="--> run all tests">
67
+ <mkdir dir="${output.dir}/test-results" />
68
+ <junit haltonfailure="yes">
69
+ <batchtest fork="yes" todir="${output.dir}/test-results">
70
+ <fileset dir="${test.src.dir}">
71
+ <include name="**/*Test.java" />
72
+ </fileset>
73
+ </batchtest>
74
+ <formatter type="brief" usefile="false" />
75
+ <formatter type="xml" />
76
+ <classpath refid="test.path.id" />
77
+ </junit>
78
+ </target>
79
+
80
+ <!-- =================================
81
+ target: war
82
+ ================================= -->
83
+ <target name="war" description="--> generate war file" depends="test">
84
+ <war destfile="${output.dir}/${project.name}.war">
85
+ <zipfileset dir="${webapp.dir}" />
86
+ </war>
87
+ </target>
88
+
89
+ <!-- =================================
90
+ target: jetty.run
91
+ ================================= -->
92
+ <target name="jetty.run" description="--> run jetty server" depends="compile">
93
+ <path id="jetty.path.id">
94
+ <fileset dir="lib/jetty" />
95
+ </path>
96
+ <taskdef classpathref="jetty.path.id" resource="tasks.properties" loaderref="jetty.loader" />
97
+ <jetty tempDirectory="${output.dir}/jetty-temp">
98
+ <webApp name="${project.name}" warfile="${webapp.dir}" contextpath="/" scanIntervalSeconds="3">
99
+ <scanTargets dir="${build.dir}">
100
+ <include name="**/*"/>
101
+ </scanTargets>
102
+ </webApp>
103
+ </jetty>
104
+ </target>
105
+
106
+ <!-- =================================
107
+ target: minify
108
+ ================================= -->
109
+ <target name="minify" depends="resolve" description="minify js and css">
110
+ <property name="yuicompressor.jar" value="lib/minify/yuicompressor-2.3.6.jar" />
111
+
112
+ <fileset dir="${js.dir}" includes="*.js" excludes="all.min.js" id="alljs" />
113
+ <fileset dir="${css.dir}" includes="*.css" excludes="*.min.css" id="allcss" />
114
+
115
+ <delete file="${css.dir}/all.css" />
116
+ <concat destfile="${css.dir}/all.css" fixlastline="true">
117
+ <fileset refid="allcss" />
118
+ </concat>
119
+
120
+ <java jar="${yuicompressor.jar}" fork="true">
121
+ <arg value="${css.dir}/all.css" />
122
+ <arg value="-o" />
123
+ <arg value="${css.dir}/all.min.css" />
124
+ </java>
125
+
126
+ <delete file="${js.dir}/all.js" />
127
+ <concat destfile="${js.dir}/all.js" fixlastline="true">
128
+ <fileset refid="alljs" />
129
+ </concat>
130
+
131
+ <java jar="${yuicompressor.jar}" fork="true">
132
+ <arg value="${js.dir}/all.js" />
133
+ <arg value="-o" />
134
+ <arg value="${js.dir}/all.min.js" />
135
+ </java>
136
+ </target>
137
+
138
+ <!-- =================================
139
+ target: report
140
+ ================================= -->
141
+ <target name="report" depends="resolve" description="--> generates a report of dependencies">
142
+ <mkdir dir="${output.dir}/reports" />
143
+ <ivy:report todir="${output.dir}/reports" />
144
+ </target>
145
+
146
+ </project>
@@ -0,0 +1,18 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <classpath>
3
+ <classpathentry kind="src" path="src/main/java"/>
4
+ <classpathentry kind="src" path="src/main/resources"/>
5
+ <classpathentry kind="src" output="target/test-classes" path="src/test/java"/>
6
+ <classpathentry kind="src" output="target/test-classes" path="src/test/resources"/>
7
+ <classpathentry kind="con" path="org.eclipse.jst.j2ee.internal.web.container"/>
8
+ <classpathentry kind="con" path="org.eclipse.jst.j2ee.internal.module.container"/>
9
+
10
+ <classpathentry kind="lib" path="lib/test/junit-4.10.jar"/>
11
+
12
+ <classpathentry kind="lib" path="lib/test/hamcrest-all-1.1.jar"/>
13
+
14
+ <classpathentry kind="lib" path="lib/test/mockito-all-1.9.0.jar"/>
15
+ <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
16
+ <classpathentry kind="con" path="com.google.appengine.eclipse.core.GAE_CONTAINER"/>
17
+ <classpathentry kind="output" path="src/main/webapp/WEB-INF/classes"/>
18
+ </classpath>
@@ -0,0 +1,7 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+
3
+ <decorators defaultdir="/WEB-INF/jsp/decorators">
4
+ <decorator name="main" page="main.jsp">
5
+ <pattern>/*</pattern>
6
+ </decorator>
7
+ </decorators>
@@ -0,0 +1,7 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+
3
+ <decorators defaultdir="/WEB-INF/views/decorators">
4
+ <decorator name="main" page="main.ftl">
5
+ <pattern>/*</pattern>
6
+ </decorator>
7
+ </decorators>
@@ -0,0 +1,60 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <web-app xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://java.sun.com/xml/ns/javaee"
3
+ xmlns:web="http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd"
4
+ id="WebApp_ID" version="2.5">
5
+
6
+ <display-name>vraptor-scaffold</display-name>
7
+
8
+ <context-param>
9
+ <param-name>br.com.caelum.vraptor.packages</param-name>
10
+ <param-value>br.com.caelum.vraptor.util.hibernate</param-value>
11
+ </context-param>
12
+
13
+ <context-param>
14
+ <param-name>br.com.caelum.vraptor.encoding</param-name>
15
+ <param-value>UTF-8</param-value>
16
+ </context-param>
17
+
18
+ <filter>
19
+ <filter-name>sitemesh</filter-name>
20
+ <filter-class>com.opensymphony.sitemesh.webapp.SiteMeshFilter</filter-class>
21
+ </filter>
22
+
23
+ <filter>
24
+ <filter-name>vraptor</filter-name>
25
+ <filter-class>br.com.caelum.vraptor.VRaptor</filter-class>
26
+ </filter>
27
+
28
+ <filter-mapping>
29
+ <filter-name>sitemesh</filter-name>
30
+ <url-pattern>/*</url-pattern>
31
+ </filter-mapping>
32
+
33
+ <filter-mapping>
34
+ <filter-name>vraptor</filter-name>
35
+ <url-pattern>/*</url-pattern>
36
+ </filter-mapping>
37
+
38
+ <servlet>
39
+ <servlet-name>sitemesh-freemarker</servlet-name>
40
+ <servlet-class>com.opensymphony.module.sitemesh.freemarker.FreemarkerDecoratorServlet</servlet-class>
41
+ <init-param>
42
+ <param-name>TemplatePath</param-name>
43
+ <param-value>/</param-value>
44
+ </init-param>
45
+ <init-param>
46
+ <param-name>default_encoding</param-name>
47
+ <param-value>UTF-8</param-value>
48
+ </init-param>
49
+ <init-param>
50
+ <param-name>auto_import</param-name>
51
+ <param-value>macros/html.ftl as html</param-value>
52
+ </init-param>
53
+ <load-on-startup>1</load-on-startup>
54
+ </servlet>
55
+
56
+ <servlet-mapping>
57
+ <servlet-name>sitemesh-freemarker</servlet-name>
58
+ <url-pattern>*.ftl</url-pattern>
59
+ </servlet-mapping>
60
+ </web-app>
@@ -0,0 +1,45 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <web-app xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://java.sun.com/xml/ns/javaee"
3
+ xmlns:web="http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd"
4
+ id="WebApp_ID" version="2.5">
5
+
6
+ <display-name>gae</display-name>
7
+
8
+ <context-param>
9
+ <param-name>br.com.caelum.vraptor.packages</param-name>
10
+ <param-value>br.com.caelum.vraptor.gae</param-value>
11
+ </context-param>
12
+
13
+ <context-param>
14
+ <param-name>br.com.caelum.vraptor.encoding</param-name>
15
+ <param-value>UTF-8</param-value>
16
+ </context-param>
17
+
18
+ <filter>
19
+ <filter-name>sitemesh</filter-name>
20
+ <filter-class>com.opensymphony.sitemesh.webapp.SiteMeshFilter</filter-class>
21
+ </filter>
22
+
23
+ <filter>
24
+ <filter-name>vraptor</filter-name>
25
+ <filter-class>br.com.caelum.vraptor.VRaptor</filter-class>
26
+ </filter>
27
+
28
+ <filter-mapping>
29
+ <filter-name>sitemesh</filter-name>
30
+ <url-pattern>/*</url-pattern>
31
+ </filter-mapping>
32
+
33
+ <filter-mapping>
34
+ <filter-name>vraptor</filter-name>
35
+ <url-pattern>/*</url-pattern>
36
+ </filter-mapping>
37
+
38
+ <jsp-config>
39
+ <jsp-property-group>
40
+ <url-pattern>*.jsp</url-pattern>
41
+ <page-encoding>UTF-8</page-encoding>
42
+ <include-prelude>/WEB-INF/jsp/prelude.jspf</include-prelude>
43
+ </jsp-property-group>
44
+ </jsp-config>
45
+ </web-app>
@@ -0,0 +1,45 @@
1
+ <ivy-module version="2.0">
2
+ <info organisation="gae" module="gae" />
3
+
4
+ <configurations>
5
+ <conf name="default" description="dependencies used for compile" />
6
+ <conf name="provided" description="dependencies used for compile but is not packaged" visibility="public" />
7
+ <conf name="test" description="dependencies used for tests" visibility="public" />
8
+ <conf name="jetty" description="dependencies used for jetty" visibility="public" />
9
+ <conf name="minify" description="dependencies used to minify js and css" visibility="public" />
10
+ </configurations>
11
+
12
+ <dependencies>
13
+ <dependency org="br.com.caelum" name="vraptor" rev="3.3.1" conf="default" />
14
+ <dependency org="opensymphony" name="sitemesh" rev="2.4.2" conf="default" />
15
+ <dependency org="javax.servlet" name="jstl" rev="1.2" conf="default" />
16
+ <dependency org="org.hibernate" name="hibernate-validator" rev="4.2.0.Final" conf="default" />
17
+ <dependency org="joda-time" name="joda-time" rev="2.0" conf="default" />
18
+ <dependency org="com.thoughtworks.xstream" name="xstream" rev="1.4.1" conf="default" />
19
+ <dependency org="com.googlecode.objectify" name="objectify" rev="3.1" conf="default" />
20
+ <dependency org="br.com.caelum" name="vraptor-gae" rev="1.0" conf="default" />
21
+ <dependency org="commons-fileupload" name="commons-fileupload" rev="1.2.2" conf="default" />
22
+ <dependency org="com.google.appengine" name="appengine-api-1.0-sdk" rev="1.6.1" conf="default" />
23
+ <dependency org="com.google.appengine" name="appengine-api-labs" rev="1.6.1" conf="default" />
24
+ <dependency org="com.google.appengine" name="appengine-jsr107cache" rev="1.6.1" conf="default" />
25
+ <dependency org="net.sf.jsr107cache" name="jsr107cache" rev="1.1" conf="default" />
26
+ <dependency org="org.apache.geronimo.specs" name="geronimo-jpa_3.0_spec" rev="1.1.1" conf="default" />
27
+
28
+ <!-- Provided dependencies -->
29
+ <dependency org="javax.servlet" name="servlet-api" rev="2.5" conf="provided->default" />
30
+ <dependency org="javax.servlet.jsp" name="jsp-api" rev="2.1" conf="provided->default" />
31
+
32
+ <!-- Test dependencies -->
33
+ <dependency org="junit" name="junit" rev="4.10" conf="test->default" />
34
+ <dependency org="org.hamcrest" name="hamcrest-all" rev="1.1" conf="test->default" />
35
+ <dependency org="org.mockito" name="mockito-all" rev="1.9.0" conf="test->default" />
36
+
37
+ <!-- Jetty dependencies -->
38
+ <dependency org="org.mortbay.jetty" name="jsp-api-2.1" rev="6.1.14" conf="jetty->default" />
39
+ <dependency org="org.mortbay.jetty" name="jsp-2.1" rev="6.1.14" conf="jetty->default" />
40
+ <dependency org="org.mortbay.jetty" name="jetty-ant" rev="6.1.14" conf="jetty->default" />
41
+
42
+ <!-- Minify dependencies -->
43
+ <dependency org="com.yahoo.platform.yui" name="yuicompressor" rev="2.3.6" conf="minify->default" />
44
+ </dependencies>
45
+ </ivy-module>
@@ -0,0 +1,40 @@
1
+ <ivy-module version="2.0">
2
+ <info organisation="vraptor-scaffold" module="vraptor-scaffold" />
3
+
4
+ <configurations>
5
+ <conf name="default" description="dependencies used for compile" />
6
+ <conf name="provided" description="dependencies used for compile but is not packaged" visibility="public" />
7
+ <conf name="test" description="dependencies used for tests" visibility="public" />
8
+ <conf name="jetty" description="dependencies used for jetty" visibility="public" />
9
+ <conf name="minify" description="dependencies used to minify js and css" visibility="public" />
10
+ </configurations>
11
+
12
+ <dependencies>
13
+ <dependency org="br.com.caelum" name="vraptor" rev="3.4.0" conf="default" />
14
+ <dependency org="opensymphony" name="sitemesh" rev="2.4.2" conf="default" />
15
+ <dependency org="javax.servlet" name="jstl" rev="1.2" conf="default" />
16
+ <dependency org="org.hsqldb" name="hsqldb" rev="2.2.8" conf="default" />
17
+ <dependency org="org.hibernate" name="hibernate-entitymanager" rev="4.0.1.Final" conf="default" />
18
+ <dependency org="org.hibernate" name="hibernate-c3p0" rev="4.0.1.Final" conf="default" />
19
+ <dependency org="org.hibernate" name="hibernate-validator" rev="4.2.0.Final" conf="default" />
20
+ <dependency org="joda-time" name="joda-time" rev="2.0" conf="default" />
21
+ <dependency org="com.thoughtworks.xstream" name="xstream" rev="1.4.1" conf="default" />
22
+
23
+ <!-- Provided dependencies -->
24
+ <dependency org="javax.servlet" name="servlet-api" rev="2.5" conf="provided->default" />
25
+ <dependency org="javax.servlet.jsp" name="jsp-api" rev="2.1" conf="provided->default" />
26
+
27
+ <!-- Test dependencies -->
28
+ <dependency org="junit" name="junit" rev="4.10" conf="test->default" />
29
+ <dependency org="org.hamcrest" name="hamcrest-all" rev="1.1" conf="test->default" />
30
+ <dependency org="org.mockito" name="mockito-all" rev="1.9.0" conf="test->default" />
31
+
32
+ <!-- Jetty dependencies -->
33
+ <dependency org="org.mortbay.jetty" name="jsp-api-2.1" rev="6.1.14" conf="jetty->default" />
34
+ <dependency org="org.mortbay.jetty" name="jsp-2.1" rev="6.1.14" conf="jetty->default" />
35
+ <dependency org="org.mortbay.jetty" name="jetty-ant" rev="6.1.14" conf="jetty->default" />
36
+
37
+ <!-- Minify dependencies -->
38
+ <dependency org="com.yahoo.platform.yui" name="yuicompressor" rev="2.3.6" conf="minify->default" />
39
+ </dependencies>
40
+ </ivy-module>
@@ -0,0 +1,45 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <web-app xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://java.sun.com/xml/ns/javaee"
3
+ xmlns:web="http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd"
4
+ id="WebApp_ID" version="2.5">
5
+
6
+ <display-name>vraptor-scaffold</display-name>
7
+
8
+ <context-param>
9
+ <param-name>br.com.caelum.vraptor.packages</param-name>
10
+ <param-value>br.com.caelum.vraptor.util.jpa</param-value>
11
+ </context-param>
12
+
13
+ <context-param>
14
+ <param-name>br.com.caelum.vraptor.encoding</param-name>
15
+ <param-value>UTF-8</param-value>
16
+ </context-param>
17
+
18
+ <filter>
19
+ <filter-name>sitemesh</filter-name>
20
+ <filter-class>com.opensymphony.sitemesh.webapp.SiteMeshFilter</filter-class>
21
+ </filter>
22
+
23
+ <filter>
24
+ <filter-name>vraptor</filter-name>
25
+ <filter-class>br.com.caelum.vraptor.VRaptor</filter-class>
26
+ </filter>
27
+
28
+ <filter-mapping>
29
+ <filter-name>sitemesh</filter-name>
30
+ <url-pattern>/*</url-pattern>
31
+ </filter-mapping>
32
+
33
+ <filter-mapping>
34
+ <filter-name>vraptor</filter-name>
35
+ <url-pattern>/*</url-pattern>
36
+ </filter-mapping>
37
+
38
+ <jsp-config>
39
+ <jsp-property-group>
40
+ <url-pattern>*.jsp</url-pattern>
41
+ <page-encoding>UTF-8</page-encoding>
42
+ <include-prelude>/WEB-INF/jsp/prelude.jspf</include-prelude>
43
+ </jsp-property-group>
44
+ </jsp-config>
45
+ </web-app>
@@ -0,0 +1,182 @@
1
+ <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
2
+ xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
3
+ <modelVersion>4.0.0</modelVersion>
4
+ <groupId>heroku</groupId>
5
+ <artifactId>heroku</artifactId>
6
+ <version>0.0.1-SNAPSHOT</version>
7
+ <name>heroku</name>
8
+
9
+ <properties>
10
+ <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
11
+ </properties>
12
+
13
+ <build>
14
+ <outputDirectory>${basedir}/src/main/webapp/WEB-INF/classes</outputDirectory>
15
+ <plugins>
16
+ <plugin>
17
+ <artifactId>maven-compiler-plugin</artifactId>
18
+ <version>2.3.2</version>
19
+ <configuration>
20
+ <source>1.6</source>
21
+ <target>1.6</target>
22
+ <encoding>UTF-8</encoding>
23
+ </configuration>
24
+ </plugin>
25
+ <plugin>
26
+ <artifactId>maven-eclipse-plugin</artifactId>
27
+ <version>2.8</version>
28
+ <configuration>
29
+ <downloadSources>true</downloadSources>
30
+ <downloadJavadocs>true</downloadJavadocs>
31
+ <wtpversion>2.0</wtpversion>
32
+ </configuration>
33
+ </plugin>
34
+ <plugin>
35
+ <groupId>org.apache.maven.plugins</groupId>
36
+ <artifactId>maven-war-plugin</artifactId>
37
+ <version>2.1.1</version>
38
+ </plugin>
39
+ <plugin>
40
+ <groupId>org.mortbay.jetty</groupId>
41
+ <artifactId>maven-jetty-plugin</artifactId>
42
+ <version>6.1.14</version>
43
+ <configuration>
44
+ <scanIntervalSeconds>3</scanIntervalSeconds>
45
+ <stopKey>foo</stopKey>
46
+ <stopPort>9999</stopPort>
47
+ <webAppConfig>
48
+ <contextPath>/</contextPath>
49
+ </webAppConfig>
50
+ </configuration>
51
+ </plugin>
52
+ <plugin>
53
+ <groupId>org.codehaus.mojo</groupId>
54
+ <artifactId>appassembler-maven-plugin</artifactId>
55
+ <version>1.1.1</version>
56
+ <executions>
57
+ <execution>
58
+ <phase>package</phase>
59
+ <goals>
60
+ <goal>assemble</goal>
61
+ </goals>
62
+ <configuration>
63
+ <assembleDirectory>target</assembleDirectory>
64
+ <extraJvmArguments>-Xmx512m</extraJvmArguments>
65
+ <programs>
66
+ <program>
67
+ <mainClass>Main</mainClass>
68
+ <name>webapp</name>
69
+ </program>
70
+ </programs>
71
+ </configuration>
72
+ </execution>
73
+ </executions>
74
+ </plugin>
75
+ </plugins>
76
+ </build>
77
+
78
+ <dependencies>
79
+ <dependency>
80
+ <groupId>br.com.caelum</groupId>
81
+ <artifactId>vraptor</artifactId>
82
+ <version>3.4.0</version>
83
+ </dependency>
84
+ <dependency>
85
+ <groupId>opensymphony</groupId>
86
+ <artifactId>sitemesh</artifactId>
87
+ <version>2.4.2</version>
88
+ </dependency>
89
+ <dependency>
90
+ <groupId>javax.servlet</groupId>
91
+ <artifactId>jstl</artifactId>
92
+ <version>1.2</version>
93
+ </dependency>
94
+ <dependency>
95
+ <groupId>org.hsqldb</groupId>
96
+ <artifactId>hsqldb</artifactId>
97
+ <version>2.2.8</version>
98
+ </dependency>
99
+ <dependency>
100
+ <groupId>org.hibernate</groupId>
101
+ <artifactId>hibernate-entitymanager</artifactId>
102
+ <version>4.0.1.Final</version>
103
+ </dependency>
104
+ <dependency>
105
+ <groupId>org.hibernate</groupId>
106
+ <artifactId>hibernate-c3p0</artifactId>
107
+ <version>4.0.1.Final</version>
108
+ </dependency>
109
+ <dependency>
110
+ <groupId>org.hibernate</groupId>
111
+ <artifactId>hibernate-validator</artifactId>
112
+ <version>4.2.0.Final</version>
113
+ </dependency>
114
+ <dependency>
115
+ <groupId>joda-time</groupId>
116
+ <artifactId>joda-time</artifactId>
117
+ <version>2.0</version>
118
+ </dependency>
119
+ <dependency>
120
+ <groupId>com.thoughtworks.xstream</groupId>
121
+ <artifactId>xstream</artifactId>
122
+ <version>1.4.1</version>
123
+ </dependency>
124
+ <dependency>
125
+ <groupId>com.google.code.gson</groupId>
126
+ <artifactId>gson</artifactId>
127
+ <version>2.2.1</version>
128
+ </dependency>
129
+ <dependency>
130
+ <groupId>com.github.filipesperandio.vraptor</groupId>
131
+ <artifactId>vraptor-hypermedia</artifactId>
132
+ <version>3.4.0</version>
133
+ </dependency>
134
+ <dependency>
135
+ <groupId>org.eclipse.jetty</groupId>
136
+ <artifactId>jetty-webapp</artifactId>
137
+ <version>7.4.4.v20110707</version>
138
+ </dependency>
139
+ <dependency>
140
+ <groupId>org.mortbay.jetty</groupId>
141
+ <artifactId>jsp-2.1-glassfish</artifactId>
142
+ <version>2.1.v20100127</version>
143
+ </dependency>
144
+ <dependency>
145
+ <groupId>javax.servlet</groupId>
146
+ <artifactId>servlet-api</artifactId>
147
+ <version>2.5</version>
148
+ </dependency>
149
+
150
+ <!-- Test dependencies -->
151
+ <dependency>
152
+ <groupId>junit</groupId>
153
+ <artifactId>junit</artifactId>
154
+ <version>4.10</version>
155
+ <scope>test</scope>
156
+ </dependency>
157
+ <dependency>
158
+ <groupId>org.hamcrest</groupId>
159
+ <artifactId>hamcrest-all</artifactId>
160
+ <version>1.1</version>
161
+ <scope>test</scope>
162
+ </dependency>
163
+ <dependency>
164
+ <groupId>org.mockito</groupId>
165
+ <artifactId>mockito-all</artifactId>
166
+ <version>1.9.0</version>
167
+ <scope>test</scope>
168
+ </dependency>
169
+
170
+ <!-- Provided dependencies -->
171
+ </dependencies>
172
+
173
+ <reporting>
174
+ <plugins>
175
+ <plugin>
176
+ <groupId>org.codehaus.mojo</groupId>
177
+ <artifactId>cobertura-maven-plugin</artifactId>
178
+ <version>2.5.1</version>
179
+ </plugin>
180
+ </plugins>
181
+ </reporting>
182
+ </project>