Browse files

add SBT support in archetypes

  • Loading branch information...
1 parent d08b0ed commit f5b8ef699f360eaa853294dae79e72666d76e326 @indrajitr indrajitr committed Aug 5, 2010
Showing with 132 additions and 1 deletion.
  1. +3 −0 lift-archetype-basic/src/main/resources/META-INF/maven/archetype-metadata.xml
  2. +1 −1 lift-archetype-basic/src/main/resources/archetype-resources/pom.xml
  3. +7 −0 lift-archetype-basic/src/main/resources/archetype-resources/project/build.properties
  4. +13 −0 lift-archetype-basic/src/main/resources/archetype-resources/project/build/LiftProject.scala
  5. +3 −0 lift-archetype-blank/src/main/resources/META-INF/maven/archetype-metadata.xml
  6. +7 −0 lift-archetype-blank/src/main/resources/archetype-resources/project/build.properties
  7. +13 −0 lift-archetype-blank/src/main/resources/archetype-resources/project/build/LiftProject.scala
  8. +3 −0 lift-archetype-jpa-basic/src/main/resources/META-INF/maven/archetype-metadata.xml
  9. +7 −0 lift-archetype-jpa-basic/src/main/resources/archetype-resources/project/build.properties
  10. +21 −0 lift-archetype-jpa-basic/src/main/resources/archetype-resources/project/build/LiftProject.scala
  11. +3 −0 lift-archetype-jpa-blank-single/src/main/resources/META-INF/maven/archetype-metadata.xml
  12. +7 −0 lift-archetype-jpa-blank-single/src/main/resources/archetype-resources/project/build.properties
  13. +13 −0 ...archetype-jpa-blank-single/src/main/resources/archetype-resources/project/build/LiftProject.scala
  14. +3 −0 lift-archetype-jpa-blank/src/main/resources/META-INF/maven/archetype-metadata.xml
  15. +7 −0 lift-archetype-jpa-blank/src/main/resources/archetype-resources/project/build.properties
  16. +21 −0 lift-archetype-jpa-blank/src/main/resources/archetype-resources/project/build/LiftProject.scala
View
3 lift-archetype-basic/src/main/resources/META-INF/maven/archetype-metadata.xml
@@ -9,6 +9,9 @@
</requiredProperty>
</requiredProperties>
<fileSets>
+ <fileSet encoding="UTF-8" filtered="true">
+ <directory>project</directory>
+ </fileSet>
<fileSet encoding="UTF-8" filtered="false">
<directory>src</directory>
<includes>
View
2 lift-archetype-basic/src/main/resources/archetype-resources/pom.xml
@@ -21,7 +21,7 @@
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<project.reporting.outputEncoding>$project_build_sourceEncoding_unevaled</project.reporting.outputEncoding>
<!-- vscaladoc settings -->
- <maven.scaladoc.vscaladocVersion>1.2-SNAPSHOT</maven.scaladoc.vscaladocVersion>
+ <maven.scaladoc.vscaladocVersion>1.2-m1</maven.scaladoc.vscaladocVersion>
<vscaladoc.links.liftweb.pathsufix>scaladocs/</vscaladoc.links.liftweb.pathsufix>
#if ($liftVersion.endsWith("SNAPSHOT"))
<vscaladoc.links.liftweb.baseurl>http://scala-tools.org/mvnsites-snapshots/liftweb</vscaladoc.links.liftweb.baseurl>
View
7 lift-archetype-basic/src/main/resources/archetype-resources/project/build.properties
@@ -0,0 +1,7 @@
+project.organization=$groupId
+project.name=$artifactId
+project.version=$version
+sbt.version=0.7.5-SNAPSHOT
+def.scala.version=2.7.7
+build.scala.versions=$scalaVersion
+project.initialize=false
View
13 lift-archetype-basic/src/main/resources/archetype-resources/project/build/LiftProject.scala
@@ -0,0 +1,13 @@
+import sbt._
+
+class LiftProject(info: ProjectInfo) extends DefaultWebProject(info) {
+
+ // Add Maven Local repository for SBT to search for (disable if this doesn't suit you)
+ val mavenLocal = "Local Maven Repository" at "file://"+Path.userHome+"/.m2/repository"
+
+#if ($liftVersion.endsWith("SNAPSHOT"))
+ // Add snapshot repo, since Lift SNAPSHOT in use
+ val snapshots = ScalaToolsSnapshots
+#end
+
+}
View
3 lift-archetype-blank/src/main/resources/META-INF/maven/archetype-metadata.xml
@@ -9,6 +9,9 @@
</requiredProperty>
</requiredProperties>
<fileSets>
+ <fileSet encoding="UTF-8" filtered="true">
+ <directory>project</directory>
+ </fileSet>
<fileSet encoding="UTF-8" filtered="false">
<directory>src</directory>
<includes>
View
7 lift-archetype-blank/src/main/resources/archetype-resources/project/build.properties
@@ -0,0 +1,7 @@
+project.organization=$groupId
+project.name=$artifactId
+project.version=$version
+sbt.version=0.7.5-SNAPSHOT
+def.scala.version=2.7.7
+build.scala.versions=$scalaVersion
+project.initialize=false
View
13 lift-archetype-blank/src/main/resources/archetype-resources/project/build/LiftProject.scala
@@ -0,0 +1,13 @@
+import sbt._
+
+class LiftProject(info: ProjectInfo) extends DefaultWebProject(info) {
+
+ // Add Maven Local repository for SBT to search for (disable if this doesn't suit you)
+ val mavenLocal = "Local Maven Repository" at "file://"+Path.userHome+"/.m2/repository"
+
+#if ($liftVersion.endsWith("SNAPSHOT"))
+ // Add snapshot repo, since Lift SNAPSHOT in use
+ val snapshots = ScalaToolsSnapshots
+#end
+
+}
View
3 lift-archetype-jpa-basic/src/main/resources/META-INF/maven/archetype-metadata.xml
@@ -10,6 +10,9 @@
</requiredProperties>
<fileSets>
<fileSet encoding="UTF-8" filtered="true">
+ <directory>project</directory>
+ </fileSet>
+ <fileSet encoding="UTF-8" filtered="true">
<directory/>
<includes>
<include>README</include>
View
7 lift-archetype-jpa-basic/src/main/resources/archetype-resources/project/build.properties
@@ -0,0 +1,7 @@
+project.organization=$groupId
+project.name=$artifactId
+project.version=$version
+sbt.version=0.7.5-SNAPSHOT
+def.scala.version=2.7.7
+build.scala.versions=$scalaVersion
+project.initialize=false
View
21 ...rchetype-jpa-basic/src/main/resources/archetype-resources/project/build/LiftProject.scala
@@ -0,0 +1,21 @@
+import sbt._
+
+class LiftProject(info: ProjectInfo) extends ParentProject(info) {
+
+ lazy val spa = project("spa", "spa", new SpaProject(_))
+ lazy val web = project("web", "web", new WebProject(_))
+
+ class SpaProject(info: ProjectInfo) extends DefaultProject(info) with BasicProjectSettings
+ class WebProject(info: ProjectInfo) extends DefaultWebProject(info) with BasicProjectSettings
+
+}
+
+trait BasicProjectSettings extends BasicDependencyProject {
+ // Add Maven Local repository for SBT to search for (disable if this doesn't suit you)
+ val mavenLocal = "Local Maven Repository" at "file://"+Path.userHome+"/.m2/repository"
+
+#if ($liftVersion.endsWith("SNAPSHOT"))
+ // Add snapshot repo, since Lift SNAPSHOT in use
+ val snapshots = ScalaToolsSnapshots
+#end
+}
View
3 lift-archetype-jpa-blank-single/src/main/resources/META-INF/maven/archetype-metadata.xml
@@ -10,6 +10,9 @@
</requiredProperties>
<fileSets>
<fileSet encoding="UTF-8" filtered="true">
+ <directory>project</directory>
+ </fileSet>
+ <fileSet encoding="UTF-8" filtered="true">
<directory/>
<includes>
<include>README</include>
View
7 ...rchetype-jpa-blank-single/src/main/resources/archetype-resources/project/build.properties
@@ -0,0 +1,7 @@
+project.organization=$groupId
+project.name=$artifactId
+project.version=$version
+sbt.version=0.7.5-SNAPSHOT
+def.scala.version=2.7.7
+build.scala.versions=$scalaVersion
+project.initialize=false
View
13 ...e-jpa-blank-single/src/main/resources/archetype-resources/project/build/LiftProject.scala
@@ -0,0 +1,13 @@
+import sbt._
+
+class LiftProject(info: ProjectInfo) extends DefaultWebProject(info) {
+
+ // Add Maven Local repository for SBT to search for (disable if this doesn't suit you)
+ val mavenLocal = "Local Maven Repository" at "file://"+Path.userHome+"/.m2/repository"
+
+#if ($liftVersion.endsWith("SNAPSHOT"))
+ // Add snapshot repo, since Lift SNAPSHOT in use
+ val snapshots = ScalaToolsSnapshots
+#end
+
+}
View
3 lift-archetype-jpa-blank/src/main/resources/META-INF/maven/archetype-metadata.xml
@@ -10,6 +10,9 @@
</requiredProperties>
<fileSets>
<fileSet encoding="UTF-8" filtered="true">
+ <directory>project</directory>
+ </fileSet>
+ <fileSet encoding="UTF-8" filtered="true">
<directory/>
<includes>
<include>README</include>
View
7 lift-archetype-jpa-blank/src/main/resources/archetype-resources/project/build.properties
@@ -0,0 +1,7 @@
+project.organization=$groupId
+project.name=$artifactId
+project.version=$version
+sbt.version=0.7.5-SNAPSHOT
+def.scala.version=2.7.7
+build.scala.versions=$scalaVersion
+project.initialize=false
View
21 ...rchetype-jpa-blank/src/main/resources/archetype-resources/project/build/LiftProject.scala
@@ -0,0 +1,21 @@
+import sbt._
+
+class LiftProject(info: ProjectInfo) extends ParentProject(info) {
+
+ lazy val spa = project("spa", "spa", new SpaProject(_))
+ lazy val web = project("web", "web", new WebProject(_))
+
+ class SpaProject(info: ProjectInfo) extends DefaultProject(info) with BasicProjectSettings
+ class WebProject(info: ProjectInfo) extends DefaultWebProject(info) with BasicProjectSettings
+
+}
+
+trait BasicProjectSettings extends BasicDependencyProject {
+ // Add Maven Local repository for SBT to search for (disable if this doesn't suit you)
+ val mavenLocal = "Local Maven Repository" at "file://"+Path.userHome+"/.m2/repository"
+
+#if ($liftVersion.endsWith("SNAPSHOT"))
+ // Add snapshot repo, since Lift SNAPSHOT in use
+ val snapshots = ScalaToolsSnapshots
+#end
+}

0 comments on commit f5b8ef6

Please sign in to comment.