Skip to content

Commit 195153c

Browse files
committed
CI: switch from Travis CI to GitHub Actions
1 parent 54d1e4d commit 195153c

9 files changed

Lines changed: 89 additions & 24 deletions

File tree

.github/build.sh

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
#!/bin/sh
2+
curl -fsLO https://raw.githubusercontent.com/scijava/scijava-scripts/master/ci-build.sh
3+
sh ci-build.sh

.github/setup.sh

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
#!/bin/sh
2+
curl -fsLO https://raw.githubusercontent.com/scijava/scijava-scripts/master/ci-setup-github-actions.sh
3+
sh ci-setup-github-actions.sh

.github/workflows/build-main.yml

Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
name: build
2+
3+
on:
4+
push:
5+
branches:
6+
- master
7+
tags:
8+
- "*-[0-9]+.*"
9+
10+
jobs:
11+
build:
12+
runs-on: ubuntu-latest
13+
14+
steps:
15+
- uses: actions/checkout@v2
16+
17+
- name: Cache m2 folder
18+
uses: actions/cache@v2
19+
env:
20+
cache-name: cache-m2
21+
with:
22+
path: ~/.m2/repository
23+
key: ${{ runner.os }}-build-${{ env.cache-name }}
24+
restore-keys: |
25+
${{ runner.os }}-build-${{ env.cache-name }}-
26+
${{ runner.os }}-build-
27+
${{ runner.os }}-
28+
29+
- name: Set up JDK 8
30+
uses: actions/setup-java@v2
31+
with:
32+
java-version: '8'
33+
distribution: 'zulu'
34+
- name: Set up CI environment
35+
run: .github/setup.sh
36+
- name: Execute the build
37+
run: .github/build.sh
38+
env:
39+
GPG_KEY_NAME: ${{ secrets.GPG_KEY_NAME }}
40+
GPG_PASSPHRASE: ${{ secrets.GPG_PASSPHRASE }}
41+
MAVEN_USER: ${{ secrets.MAVEN_USER }}
42+
MAVEN_PASS: ${{ secrets.MAVEN_PASS }}
43+
OSSRH_PASS: ${{ secrets.OSSRH_PASS }}
44+
SIGNING_ASC: ${{ secrets.SIGNING_ASC }}

.github/workflows/build-pr.yml

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
name: build PR
2+
3+
on:
4+
pull_request:
5+
branches:
6+
- master
7+
8+
jobs:
9+
build:
10+
runs-on: ubuntu-latest
11+
12+
steps:
13+
- uses: actions/checkout@v2
14+
15+
- name: Cache m2 folder
16+
uses: actions/cache@v2
17+
env:
18+
cache-name: cache-m2
19+
with:
20+
path: ~/.m2/repository
21+
key: ${{ runner.os }}-build-${{ env.cache-name }}
22+
restore-keys: |
23+
${{ runner.os }}-build-${{ env.cache-name }}-
24+
${{ runner.os }}-build-
25+
${{ runner.os }}-
26+
27+
- name: Set up JDK 8
28+
uses: actions/setup-java@v2
29+
with:
30+
java-version: '8'
31+
distribution: 'zulu'
32+
- name: Set up CI environment
33+
run: .github/setup.sh
34+
- name: Execute the build
35+
run: .github/build.sh

.travis.yml

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

.travis/build.sh

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

.travis/signingkey.asc.enc

-9.41 KB
Binary file not shown.

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
[![](https://travis-ci.com/scijava/scijava-optional.svg?branch=master)](https://travis-ci.com/scijava/scijava-optional)
1+
[![](https://github.com/scijava/scijava-optional/actions/workflows/build-main.yml/badge.svg)](https://github.com/scijava/scijava-optional/actions/workflows/build-main.yml)
22

33
# scijava-optional
44

pom.xml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -54,8 +54,8 @@
5454
<url>https://github.com/scijava/scijava-optional/issues</url>
5555
</issueManagement>
5656
<ciManagement>
57-
<system>Travis CI</system>
58-
<url>https://travis-ci.com/scijava/scijava-optional</url>
57+
<system>GitHub Actions</system>
58+
<url>https://github.com/scijava/scijava-optional/actions</url>
5959
</ciManagement>
6060

6161
<properties>
@@ -66,7 +66,7 @@
6666
<license.copyrightOwners>Max Planck Institute of Molecular Cell Biology and Genetics</license.copyrightOwners>
6767

6868
<!-- NB: Deploy releases to the SciJava Maven repository. -->
69-
<releaseProfiles>deploy-to-scijava</releaseProfiles>
69+
<releaseProfiles>sign,deploy-to-scijava</releaseProfiles>
7070
</properties>
7171

7272
<developers>

0 commit comments

Comments
 (0)