Skip to content

Commit ebc598d

Browse files
authored
Update CI and add JuliaFormatter (#1)
* Add JuliaFormatter * Update CI * Fix badges * Update to codecov-action@v2 * Rename action
1 parent 7a8ab58 commit ebc598d

File tree

4 files changed

+61
-11
lines changed

4 files changed

+61
-11
lines changed

.JuliaFormatter.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
style = "blue"

.github/workflows/CI.yml

Lines changed: 31 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,39 @@
11
name: CI
2+
23
on:
3-
- push
4-
- pull_request
4+
push:
5+
branches:
6+
- main
7+
pull_request:
8+
9+
concurrency:
10+
# Skip intermediate builds: always.
11+
# Cancel intermediate builds: only if it is a pull request build.
12+
group: ${{ github.workflow }}-${{ github.ref }}
13+
cancel-in-progress: ${{ startsWith(github.ref, 'refs/pull/') }}
14+
515
jobs:
616
test:
7-
name: Julia ${{ matrix.version }} - ${{ matrix.os }} - ${{ matrix.arch }} - ${{ github.event_name }}
17+
name: Julia ${{ matrix.version }} - ${{ matrix.os }} - ${{ matrix.arch }}
818
runs-on: ${{ matrix.os }}
919
strategy:
1020
fail-fast: false
1121
matrix:
1222
version:
13-
- '1'
1423
- '1.0'
24+
- '1'
1525
- 'nightly'
1626
os:
1727
- ubuntu-latest
1828
arch:
1929
- x64
30+
include:
31+
- os: macOS-latest
32+
version: '1'
33+
arch: x64
34+
- os: windows-latest
35+
version: '1'
36+
arch: x64
2037
steps:
2138
- uses: actions/checkout@v2
2239
- uses: julia-actions/setup-julia@v1
@@ -35,10 +52,16 @@ jobs:
3552
${{ runner.os }}-
3653
- uses: julia-actions/julia-buildpkg@v1
3754
- uses: julia-actions/julia-runtest@v1
55+
with:
56+
coverage: ${{ matrix.version == '1' && matrix.os == 'ubuntu-latest' }}
3857
- uses: julia-actions/julia-processcoverage@v1
39-
- uses: codecov/codecov-action@v1
58+
if: matrix.version == '1' && matrix.os == 'ubuntu-latest'
59+
- uses: codecov/codecov-action@v2
60+
if: matrix.version == '1' && matrix.os == 'ubuntu-latest'
4061
with:
4162
file: lcov.info
42-
- uses: julia-actions/julia-uploadcoveralls@v1
43-
env:
44-
COVERALLS_TOKEN: ${{ secrets.COVERALLS_TOKEN }}
63+
- uses: coverallsapp/github-action@master
64+
if: matrix.version == '1' && matrix.os == 'ubuntu-latest'
65+
with:
66+
github-token: ${{ secrets.GITHUB_TOKEN }}
67+
path-to-lcov: lcov.info

.github/workflows/Format.yml

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
name: Format
2+
3+
on:
4+
pull_request:
5+
6+
concurrency:
7+
# Skip intermediate builds: always.
8+
# Cancel intermediate builds: only if it is a pull request build.
9+
group: ${{ github.workflow }}-${{ github.ref }}
10+
cancel-in-progress: ${{ startsWith(github.ref, 'refs/pull/') }}
11+
12+
jobs:
13+
format:
14+
runs-on: ubuntu-latest
15+
steps:
16+
- uses: actions/checkout@v2
17+
- uses: julia-actions/setup-julia@latest
18+
with:
19+
version: 1
20+
- run: |
21+
julia -e 'using Pkg; Pkg.add("JuliaFormatter")'
22+
julia -e 'using JuliaFormatter; format("."; verbose=true)'
23+
- uses: reviewdog/action-suggester@v1
24+
with:
25+
tool_name: JuliaFormatter
26+
fail_on_error: true

README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# RealDot
22

3-
[![Build Status](https://github.com/devmotion/RealDot.jl/workflows/CI/badge.svg)](https://github.com/devmotion/RealDot.jl/actions)
4-
[![Coverage](https://codecov.io/gh/devmotion/RealDot.jl/branch/master/graph/badge.svg)](https://codecov.io/gh/devmotion/RealDot.jl)
5-
[![Coverage](https://coveralls.io/repos/github/devmotion/RealDot.jl/badge.svg?branch=master)](https://coveralls.io/github/devmotion/RealDot.jl?branch=master)
3+
[![Build Status](https://github.com/devmotion/RealDot.jl/workflows/CI/badge.svg?branch=main)](https://github.com/devmotion/RealDot.jl/actions/workflows/CI.yml?query=branch%3Amain)
4+
[![Coverage](https://codecov.io/gh/devmotion/RealDot.jl/branch/main/graph/badge.svg)](https://codecov.io/gh/devmotion/RealDot.jl)
5+
[![Coverage](https://coveralls.io/repos/github/devmotion/RealDot.jl/badge.svg?branch=main)](https://coveralls.io/github/devmotion/RealDot.jl?branch=main)
66
[![Code Style: Blue](https://img.shields.io/badge/code%20style-blue-4495d1.svg)](https://github.com/invenia/BlueStyle)

0 commit comments

Comments
 (0)