Skip to content

Commit 43f101d

Browse files
committed
Migrate from Travis and AppVeyor to GitHub Actions
1 parent 08a0b43 commit 43f101d

6 files changed

Lines changed: 107 additions & 110 deletions

File tree

.github/workflows/maven.yml

Lines changed: 100 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,100 @@
1+
name: Maven Build and Deployment
2+
3+
on:
4+
push:
5+
branches: [ master ]
6+
pull_request:
7+
branches: [ master ]
8+
9+
jobs:
10+
build:
11+
name: Java 11 Build and Verify
12+
runs-on: ubuntu-16.04
13+
14+
steps:
15+
- name: Check out Git repository
16+
uses: actions/checkout@v2
17+
18+
- name: Set up Java and Maven
19+
uses: actions/setup-java@v1
20+
with:
21+
java-version: 11
22+
23+
- name: Cache Maven packages
24+
uses: actions/cache@v1
25+
with:
26+
path: ~/.m2
27+
key: ${{ runner.os }}-m2-${{ hashFiles('**/pom.xml') }}
28+
restore-keys: ${{ runner.os }}-m2
29+
30+
- name: Build with Maven
31+
run: mvn -B verify
32+
33+
- name: Upload code coverage to Codecov
34+
uses: codecov/codecov-action@v1
35+
36+
compatibility-checks:
37+
name: Java ${{ matrix.java }} on ${{ matrix.os }} Compatibility
38+
runs-on: ${{ matrix.os }}
39+
40+
strategy:
41+
matrix:
42+
os: [ubuntu-16.04, macos-latest, windows-latest]
43+
java: [8, 11, 14]
44+
45+
steps:
46+
- name: Check out Git repository
47+
uses: actions/checkout@v2
48+
49+
- name: Set up Java and Maven
50+
uses: actions/setup-java@v1
51+
with:
52+
java-version: ${{ matrix.java }}
53+
54+
- name: Cache Maven packages
55+
uses: actions/cache@v1
56+
with:
57+
path: ~/.m2
58+
key: ${{ runner.os }}-${{ matrix.java }}-m2-${{ hashFiles('**/pom.xml') }}
59+
restore-keys: ${{ runner.os }}-${{ matrix.java }}-m2
60+
61+
- name: Test with Maven
62+
run: mvn -B test
63+
64+
- name: Upload Surefire reports on test failure
65+
uses: actions/upload-artifact@v1
66+
if: failure()
67+
with:
68+
name: surefire-test-log
69+
path: target/surefire-reports
70+
71+
deploy:
72+
name: Deploy to OSSRH
73+
needs: [build, compatibility-checks]
74+
if: github.event_name == 'push'
75+
runs-on: ubuntu-latest
76+
77+
steps:
78+
- name: Check out Git repository
79+
uses: actions/checkout@v2
80+
81+
- name: Set up Java and Maven
82+
uses: actions/setup-java@v1
83+
with:
84+
java-version: 11
85+
86+
- name: Cache Maven packages
87+
uses: actions/cache@v1
88+
with:
89+
path: ~/.m2
90+
key: ${{ runner.os }}-m2-${{ hashFiles('**/pom.xml') }}
91+
restore-keys: ${{ runner.os }}-m2
92+
93+
- name: Publish Maven package
94+
uses: samuelmeuli/action-maven-publish@v1
95+
with:
96+
gpg_private_key: ${{ secrets.gpg_private_key }}
97+
gpg_passphrase: ${{ secrets.gpg_passphrase }}
98+
nexus_username: ${{ secrets.nexus_username }}
99+
nexus_password: ${{ secrets.nexus_password }}
100+
maven_args: "-DskipTests"

.travis-settings.xml

Lines changed: 0 additions & 44 deletions
This file was deleted.

.travis.yml

Lines changed: 0 additions & 26 deletions
This file was deleted.

README.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
1-
[![Build Status](https://travis-ci.org/lmdbjava/lmdbjava.svg?branch=master)](https://travis-ci.org/lmdbjava/lmdbjava)
2-
[![Build Status](https://ci.appveyor.com/api/projects/status/0w4yb9ybx22g2pwp?svg=true)](https://ci.appveyor.com/project/benalexau/lmdbjava)
1+
[![Maven Build and Deployment](https://github.com/lmdbjava/lmdbjava/workflows/Maven%20Build%20and%20Deployment/badge.svg)](https://github.com/lmdbjava/lmdbjava/actions)
32
[![codecov](https://codecov.io/gh/lmdbjava/lmdbjava/branch/master/graph/badge.svg)](https://codecov.io/gh/lmdbjava/lmdbjava)
43
[![Javadocs](http://www.javadoc.io/badge/org.lmdbjava/lmdbjava.svg?color=blue)](http://www.javadoc.io/doc/org.lmdbjava/lmdbjava)
54
[![Maven Central](https://img.shields.io/maven-central/v/org.lmdbjava/lmdbjava.svg?maxAge=3600)](http://search.maven.org/#search%7Cga%7C1%7Cg%3A%22org.lmdbjava%22%20AND%20a%3A%22lmdbjava%22)
@@ -35,9 +34,10 @@
3534
* Community questions and contributions are welcome through [GitHub tickets](https://github.com/lmdbjava/lmdbjava/issues)
3635
* Mature code (commenced in 2016) and used for heavy production workloads (eg > 500 TB of HFT data)
3736
* Actively maintained and with a "Zero Bug Policy" before every release (see [issues](https://github.com/lmdbjava/lmdbjava/issues))
38-
* Available from [Maven Central](http://search.maven.org/#search%7Cga%7C1%7Cg%3A%22org.lmdbjava%22%20AND%20a%3A%22lmdbjava%22) and [OSS Sonatype Snapshots](https://oss.sonatype.org/content/repositories/snapshots/org/lmdbjava/lmdbjava) (see [Change Log](https://github.com/lmdbjava/lmdbjava/wiki/Change-Log))
39-
* Comprehensive [JavaDocs](http://www.javadoc.io/doc/org.lmdbjava/lmdbjava)
40-
* [Linux](https://travis-ci.org/lmdbjava/lmdbjava), [OS X](https://travis-ci.org/lmdbjava/lmdbjava) and [Windows](https://ci.appveyor.com/project/benalexau/lmdbjava) CI
37+
* Available from [Maven Central](http://search.maven.org/#search%7Cga%7C1%7Cg%3A%22org.lmdbjava%22%20AND%20a%3A%22lmdbjava%22) and [OSS Sonatype Snapshots](https://oss.sonatype.org/content/repositories/snapshots/org/lmdbjava/lmdbjava)
38+
* Detailed [JavaDocs](http://www.javadoc.io/doc/org.lmdbjava/lmdbjava)
39+
* [Change Log](https://github.com/lmdbjava/lmdbjava/wiki/Change-Log) to assist with upgrades
40+
* [Continuous integration](https://github.com/lmdbjava/lmdbjava/actions) testing on Linux, Windows and macOS across Java versions 8, 11 and 14
4141

4242
### Performance
4343

appveyor.yml

Lines changed: 0 additions & 33 deletions
This file was deleted.

pom.xml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -52,8 +52,8 @@
5252
<url>https://github.com/${github.org}/${github.repo}/issues</url>
5353
</issueManagement>
5454
<ciManagement>
55-
<system>travis-ci</system>
56-
<url>https://travis-ci.org/${github.org}/${github.repo}</url>
55+
<system>GitHub Actions</system>
56+
<url>https://github.com/${github.org}/${github.repo}/actions</url>
5757
</ciManagement>
5858
<properties>
5959
<github.org>lmdbjava</github.org>

0 commit comments

Comments
 (0)