@@ -18,11 +18,6 @@ val moveLibs = taskKey[Pipeline.Stage]("Moves libraries")
18
18
19
19
val removeUnversionedAssets = taskKey[Pipeline .Stage ](" Removes unversioned assets" )
20
20
21
- val explicitlyExcludedLibFiles = Set (
22
- " lib/bootstrap/fonts/glyphicons-halflings-regular.eot" , " lib/bootstrap/fonts/glyphicons-halflings-regular.svg" ,
23
- " lib/bootstrap/fonts/glyphicons-halflings-regular.ttf" , " lib/bootstrap/fonts/glyphicons-halflings-regular.woff2"
24
- )
25
-
26
21
val genHtmlDir = settingKey[File ](" Output directory for HTML generated files" )
27
22
28
23
val PublicDirName = " statistiky" // TODO: DRY this constant from routes
@@ -58,13 +53,10 @@ lazy val server = (project in file("server")).settings(
58
53
scalacOptions ++= Seq (" -deprecation" , " -feature" ),
59
54
scalaVersion := scalaV2,
60
55
scalaJSProjects := Seq (client),
61
- scalaJSStage := FullOptStage ,
62
56
Assets / pipelineStages := Seq (scalaJSPipeline),
63
57
pipelineStages := Seq (concat, removeLibs, filter, digest, simpleUrlUpdate/* , digest*/ , removeUnversionedAssets, moveLibs),
64
58
digest / includeFilter := " *" ,
65
- digest / excludeFilter := " *.html" || " *.csv" || " *.json" || " *.json.new" ||
66
- // When sbt-simple-url-update updates path for glyphicons-halflings-regular.woff, it garbles the path for glyphicons-halflings-regular.woff2.
67
- " glyphicons-halflings-regular.woff" ,
59
+ digest / excludeFilter := " *.html" || " *.csv" || " *.json" || " *.json.new" ,
68
60
filter / excludeFilter := " *.scss" || " *.note" || " *.source" || " *.css" - " main.css" || " *.js" - " main.min.js" ,
69
61
filter / includeFilter := " *.css" || " *.html" || " *.js" || " *.csv" || " *.svg" || " *.woff" || " *.ttf" || " *.eot" || " *.woff2" || " *.json.new" ,
70
62
genHtmlDir := target.value / " web" / " html" / " main" ,
@@ -88,7 +80,7 @@ lazy val server = (project in file("server")).settings(
88
80
}
89
81
}.taskValue,
90
82
removeUnversionedAssets := { mappings : Seq [PathMapping ] =>
91
- mappings.filter{case (file, name) => ! (name.startsWith(" main." ) || explicitlyExcludedLibFiles.contains(name) )}
83
+ mappings.filter{case (file, name) => ! (name.startsWith(" main." ) )}
92
84
},
93
85
removeLibs := { mappings : Seq [PathMapping ] => // Most of libs are already included in a CSS/JS file, so skip them
94
86
mappings.filter{case (file, name) => (! name.startsWith(" lib/" )) || name.startsWith(" lib/bootstrap/fonts" )}
@@ -109,7 +101,7 @@ lazy val server = (project in file("server")).settings(
109
101
" org.webjars" % " bootstrap" % bootstrapVersion,
110
102
specs2 % Test
111
103
),
112
- ).enablePlugins(PlayScala , SbtWeb , WebScalaJSBundlerPlugin )// .dependsOn(sharedJvm)
104
+ ).enablePlugins(PlayScala , SbtWeb , WebScalaJSBundlerPlugin )
113
105
114
106
// Generates client JS; other assets are generated by the server subproject
115
107
lazy val client = (project in file(" client" )).settings(
@@ -137,15 +129,7 @@ lazy val client = (project in file("client")).settings(
137
129
),
138
130
stIgnore ++= List (" moment" , " moment-timezone" , " bootstrap" , " chart.js" , " chartjs-adapter-moment" ,
139
131
" comma-separated-values" ),
140
- ).enablePlugins(ScalaJSPlugin , ScalaJSBundlerPlugin , ScalablyTypedConverterPlugin )// .dependsOn(sharedJs)
141
-
142
- /* lazy val shared = (crossProject.crossType(CrossType.Pure) in file("shared")).
143
- settings(scalaVersion := scalaV).
144
- jsConfigure(_ enablePlugins ScalaJSWeb)
145
-
146
- lazy val sharedJvm = shared.jvm
147
- lazy val sharedJs = shared.js*/
148
-
132
+ ).enablePlugins(ScalaJSPlugin , ScalaJSBundlerPlugin , ScalablyTypedConverterPlugin )
149
133
150
134
name := " zbdb-stats"
151
135
0 commit comments