forked from scalameta/scalameta
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.drone.yml
40 lines (38 loc) · 1.38 KB
/
.drone.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
clone:
depth: 50
tags: true
recursive: true
build:
image: ensime/ensime:v2.x-cache
pull: true
environment:
- SONATYPE_USERNAME=$$SONATYPE_USERNAME
- SONATYPE_PASSWORD=$$SONATYPE_PASSWORD
- GITHUB_USERNAME=$$GITHUB_USERNAME
- GITHUB_PASSWORD=$$GITHUB_PASSWORD
commands:
- git log | head -n 20
- host `curl -s http://httpbin.org/ip | jq -r '.origin'` || true ;
- if [ -n "$CI_PULL_REQUEST" ] ; then
echo "Incoming pull request from https://github.com/$CI_REPO/pull/$CI_PULL_REQUEST";
author=$(curl -s "https://api.github.com/repos/$CI_REPO/pulls/$CI_PULL_REQUEST" | jq -r ".user.login");
if [ $? -ne 0 ] ; then exit 1; fi;
echo "Pull request submitted by $author";
signed=$(curl -s http://www.lightbend.com/contribute/cla/scala/check/$author | jq -r ".signed");
if [ $? -ne 0 ] ; then exit 1; fi;
if [ "$signed" = "true" ] ; then
echo "CLA check for $author successful";
else
echo "CLA check for $author failed";
echo "Please sign the Scala CLA to contribute to scala.meta";
echo "Go to https://www.lightbend.com/contribute/cla/scala and then resubmit this pull request";
exit 1;
fi;
fi
- sbt ++$SCALA_VERSION test
- if [ -z "$CI_PULL_REQUEST" ] ; then
sbt ++$SCALA_VERSION publish ;
fi
matrix:
SCALA_VERSION:
- 2.11.8