File tree 2 files changed +54
-8
lines changed
2 files changed +54
-8
lines changed Original file line number Diff line number Diff line change 1
- version :
1
+ version : 2
2
2
jobs :
3
3
build :
4
4
@@ -12,16 +12,51 @@ jobs:
12
12
- checkout
13
13
14
14
- restore_cache :
15
- key : cassandra-java-driver-kerberos-{{ checksum "pom.xml" }}
15
+ keys :
16
+ - m2-{{ checksum "pom.xml" }}
17
+ - m2-
16
18
17
- - run : mvn dependency:go-offline # gets the project dependencies
19
+ - run : mvn clean install -DoutputDirectory=/tmp/artifacts
18
20
19
21
- save_cache :
20
22
paths :
21
23
- ~/.m2
22
- key : cassandra-java-driver-kerberos-{{ checksum "pom.xml" }}
23
-
24
- - run : mvn clean install
24
+ key : m2-{{ checksum "pom.xml" }}
25
25
26
26
- store_artifacts :
27
- path : ~/cassandra-java-driver-kerberos/target/cassandra-driver-kerberos.jar
27
+ path : /tmp/artifacts
28
+
29
+ - persist_to_workspace :
30
+ root : /tmp/artifacts
31
+ paths :
32
+ - cassandra-driver-kerberos.jar
33
+
34
+ publish-github-release :
35
+ docker :
36
+ - image : circleci/golang
37
+ steps :
38
+ - attach_workspace :
39
+ at : ./artifacts
40
+ - run :
41
+ name : " Publish Release on GitHub"
42
+ command : |
43
+ set -xue
44
+ go get github.com/tcnksm/ghr
45
+ ghr -t ${GITHUB_TOKEN} -u ${CIRCLE_PROJECT_USERNAME} -r ${CIRCLE_PROJECT_REPONAME} -c ${CIRCLE_SHA1} -delete ${CIRCLE_TAG} ./artifacts/
46
+
47
+ workflows :
48
+ version : 2
49
+ build :
50
+ jobs :
51
+ - build :
52
+ filters :
53
+ tags :
54
+ only : /^v\d+\.\d+\.\d+$/
55
+ - publish-github-release :
56
+ requires :
57
+ - build
58
+ filters :
59
+ branches :
60
+ ignore : /.*/
61
+ tags :
62
+ only : /^v\d+\.\d+\.\d+$/
Original file line number Diff line number Diff line change 49
49
<version .maven.source.plugin>3.0.1</version .maven.source.plugin>
50
50
<version .maven.javadoc.plugin>3.1.0</version .maven.javadoc.plugin>
51
51
<version .maven.gpg.plugin>1.6</version .maven.gpg.plugin>
52
+ <maven .jar.plugin.version>3.1.1</maven .jar.plugin.version>
52
53
<version .nexus.staging.maven.plugin>1.6.8</version .nexus.staging.maven.plugin>
53
-
54
+
55
+ <outputDirectory >${project.build.directory}</outputDirectory >
56
+
54
57
<maven .compiler.source>1.8</maven .compiler.source>
55
58
<maven .compiler.target>1.8</maven .compiler.target>
56
59
78
81
<target >${maven.compiler.target} </target >
79
82
</configuration >
80
83
</plugin >
84
+ <plugin >
85
+ <groupId >org.apache.maven.plugins</groupId >
86
+ <artifactId >maven-jar-plugin</artifactId >
87
+ <version >${maven.jar.plugin.version} </version >
88
+ <configuration >
89
+ <outputDirectory >${outputDirectory} </outputDirectory >
90
+ </configuration >
91
+ </plugin >
81
92
</plugins >
82
93
</build >
83
94
You can’t perform that action at this time.
0 commit comments