1
+ val baseSettings = Seq (
2
+ organization := " com.lihaoyi" ,
3
+ name := " sourcecode" ,
4
+ version := " 0.1.4" ,
5
+ scalaVersion := " 2.11.11" ,
6
+ crossScalaVersions := Seq (" 2.10.6" , " 2.11.11" , " 2.12.2" , " 2.13.0-M1" ),
7
+ scmInfo := Some (ScmInfo (
8
+ browseUrl = url(" https://github.com/lihaoyi/sourcecode" ),
9
+ connection
= " scm:git:[email protected] :lihaoyi/sourcecode.git"
10
+ )),
11
+ homepage := Some (url(" https://github.com/lihaoyi/sourcecode" )),
12
+ licenses := Seq (" MIT" -> url(" http://www.opensource.org/licenses/mit-license.html" )),
13
+ developers += Developer (
14
+
15
+ id = " lihaoyi" ,
16
+ name = " Li Haoyi" ,
17
+ url = url(" https://github.com/lihaoyi" )
18
+ )
19
+ )
1
20
2
- crossScalaVersions := Seq ( " 2.10.6 " , " 2.11.8 " , " 2.12.0 " )
21
+ baseSettings
3
22
4
23
def macroDependencies (version : String ) =
5
24
Seq (
@@ -12,42 +31,20 @@ def macroDependencies(version: String) =
12
31
else
13
32
Seq ())
14
33
15
- lazy val sourcecode = crossProject.settings(
16
- version := " 0.1.3" ,
17
- scalaVersion := " 2.11.8" ,
18
- name := " sourcecode" ,
19
- organization := " com.lihaoyi" ,
20
- libraryDependencies ++= macroDependencies(scalaVersion.value),
21
- unmanagedSourceDirectories in Compile ++= {
22
- CrossVersion .partialVersion(scalaVersion.value) match {
23
- case Some ((2 , n)) if n >= 12 =>
24
- Seq (baseDirectory.value / " .." / " shared" / " src" / " main" / " scala-2.11" )
25
- case _ =>
26
- Seq ()
27
- }
28
- },
29
- publishTo := Some (" releases" at " https://oss.sonatype.org/service/local/staging/deploy/maven2" ),
30
-
31
- pomExtra :=
32
- <url >https:// github.com/ lihaoyi/ sourcecode</url >
33
- <licenses >
34
- <license >
35
- <name >MIT license</name >
36
- <url >http:// www.opensource.org/ licenses/ mit- license.php</url >
37
- </license >
38
- </licenses >
39
- <scm >
40
- <url >git:// github.com/ lihaoyi/ sourcecode.git</url >
41
- <connection >scm: git:// github.com/ lihaoyi/ sourcecode.git</connection >
42
- </scm >
43
- <developers >
44
- <developer >
45
- <id >lihaoyi</id >
46
- <name >Li Haoyi </name >
47
- <url >https:// github.com/ lihaoyi</url >
48
- </developer >
49
- </developers >
50
- )
34
+ lazy val sourcecode = crossProject
35
+ .settings(baseSettings)
36
+ .settings(
37
+ libraryDependencies ++= macroDependencies(scalaVersion.value),
38
+ unmanagedSourceDirectories in Compile ++= {
39
+ CrossVersion .partialVersion(scalaVersion.value) match {
40
+ case Some ((2 , n)) if n >= 12 =>
41
+ Seq (baseDirectory.value / " .." / " shared" / " src" / " main" / " scala-2.11" )
42
+ case _ =>
43
+ Seq ()
44
+ }
45
+ },
46
+ publishTo := Some (" releases" at " https://oss.sonatype.org/service/local/staging/deploy/maven2" )
47
+ )
51
48
52
49
lazy val js = sourcecode.js
53
50
lazy val jvm = sourcecode.jvm
0 commit comments