Skip to content

Commit

Permalink
Clean better.
Browse files Browse the repository at this point in the history
  • Loading branch information
lrytz committed Mar 15, 2018
1 parent 76d9640 commit 999a756
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 9 deletions.
14 changes: 5 additions & 9 deletions admin/build.ps1
Expand Up @@ -16,15 +16,11 @@ Function ensureVersion() {
}

Function clearIvyCache() {
if (test-path C:\Users\appveyor\.ivy2\cache\org.scala-lang) {
remove-item -force -recurse C:\Users\appveyor\.ivy2\cache\org.scala-lang
}
if (test-path C:\Users\appveyor\.ivy2) {
get-childitem -path C:\Users\appveyor\.ivy2 -recurse -include "*compiler-interface*$env:version*" | remove-item -force -recurse
}
if (test-path C:\Users\appveyor\.sbt) {
get-childitem -path C:\Users\appveyor\.sbt -recurse -include "*compiler-interface*$env:version*" | remove-item -force -recurse
}
remove-item -erroraction ignore -force $homeDir\.ivy2\exclude_classifiers, $homeDir\.ivy2\exclude_classifiers.lock
remove-item -erroraction ignore -force -recurse $homeDir\.ivy2\cache\org.scala-lang
remove-item -erroraction ignore -force -recurse $homeDir\.ivy2\local\org.scala-lang
get-childitem -erroraction ignore -path $homeDir\.ivy2 -recurse -include "*compiler-interface*$env:version*" | remove-item -force -recurse
get-childitem -erroraction ignore -path $homeDir\.sbt -recurse -include "*compiler-interface*$env:version*" | remove-item -force -recurse
}

# oh boy. i don't (want to) fully understand, but executing commands and redirecting is difficult.
Expand Down
2 changes: 2 additions & 0 deletions admin/build.sh
Expand Up @@ -71,7 +71,9 @@ function triggerSmoketest() {
}

clearIvyCache() {
rm -f $HOME/.ivy2/exclude_classifiers $HOME/.ivy2/exclude_classifiers.lock
rm -rf $HOME/.ivy2/cache/org.scala-lang
rm -rf $HOME/.ivy2/local/org.scala-lang
if [ -d $HOME/.ivy2 ]; then find $HOME/.ivy2 -name "*compiler-interface*$version*" | xargs rm -rf; fi
if [ -d $HOME/.sbt ]; then find $HOME/.sbt -name "*compiler-interface*$version*" | xargs rm -rf; fi
}
Expand Down
2 changes: 2 additions & 0 deletions scripts/common.ps1
@@ -1,3 +1,5 @@
$homeDir="C:\Users\appveyor"

Function postCommitStatus($state) {
if ("$env:scala_sha" -ne "") {
$jsonTemplate = '{{ "state": "{0}", "target_url": "{1}", "description": "{2}", "context": "{3}" }}'
Expand Down

0 comments on commit 999a756

Please sign in to comment.