File tree Expand file tree Collapse file tree 3 files changed +9
-409
lines changed Expand file tree Collapse file tree 3 files changed +9
-409
lines changed Original file line number Diff line number Diff line change @@ -35,6 +35,7 @@ object Deps {
3535  val  acyclic  =  ivy " com.lihaoyi:::acyclic:0.3.6 " 
3636  val  jna  =  ivy " net.java.dev.jna:jna:5.13.0 " 
3737  val  geny  =  ivy " com.lihaoyi::geny::1.0.0 " 
38+   val  scalaCollectionCompat  =  ivy " org.scala-lang.modules::scala-collection-compat::2.9.0 " 
3839  val  sourcecode  =  ivy " com.lihaoyi::sourcecode::0.3.0 " 
3940  val  utest  =  ivy " com.lihaoyi::utest::0.8.1 " 
4041  def  scalaLibrary (version : String ) =  ivy " org.scala-lang:scala-library: ${version}" 
@@ -173,9 +174,13 @@ trait OsLibTestModule extends ScalaModule with TestModule.Utest with SafeDeps {
173174
174175trait  OsModule  extends  OsLibModule  {
175176  override  def  artifactName  =  " os-lib" 
176-   override  def  ivyDeps  =  Agg (
177-     Deps .geny
178-   )
177+   override  def  ivyDeps  =  T  {
178+     val  scalaV  =  scalaVersion()
179+     if  (scalaV.startsWith(" 2.11" ||  scalaV.startsWith(" 2.12" 
180+       //  include collection compat, mostly for a backported scala.util.Using
181+       Agg (Deps .geny, Deps .scalaCollectionCompat)
182+     } else  Agg (Deps .geny)
183+   }
179184}
180185
181186trait  WatchModule  extends  OsLibModule  {
Original file line number Diff line number Diff line change 11package  os 
22
33import  java .nio .file .attribute .{FileAttribute , PosixFilePermissions }
4- import  os .util .Using 
4+ import  scala .util .Using 
55
66/** 
77 * Create temporary files and directories. [[withFile ]] and [[withDir ]]  
 
 
   
 
     
   
   
          
    
    
     
    
      
     
     
    You can’t perform that action at this time.
  
 
    
  
    
      
        
     
       
      
     
   
 
    
    
  
 
  
 
     
    
0 commit comments