cws/build.sc
changeset 889 00c1c3408c93
parent 887 d9d52f3e7935
child 919 53f08d873e09
equal deleted inserted replaced
888:fc812b8f120f 889:00c1c3408c93
     1 #!/usr/bin/env amm
     1 #!/usr/bin/env amm
     2 
     2 
     3 val files = List("cw01.tex",
     3 val files = Seq("cw01.tex",
     4 	         "cw02.tex",
     4 	         "cw02.tex",
     5 	         "cw03.tex",
     5 	         "cw03.tex",
     6 	         "cw04.tex",
     6 	         "cw04.tex",
     7 	         "cw05.tex")
     7 	         "cw05.tex")
     8 
     8 
     9 
     9 val pdf_files = files.map(s => s.stripSuffix("tex") ++ "pdf")
    10 
    10 
    11 
    11 
    12 @main
    12 @main
    13 def make() = {
    13 def make() = {
    14   for (f <- files) {
    14   for (f <- files) {
    19 }
    19 }
    20 
    20 
    21 
    21 
    22 @main
    22 @main
    23 def hg() = {
    23 def hg() = {
    24   println(s"$files")
    24   println(os.proc("hg", "commit", "-m texupdate", files ++ pdf_files).call())
    25   println(os.proc("hg", "commit", "-m texupdate", files.mkString(" ")).call())
    25   println(os.proc("hg", "push").call())
    26 }
    26 }