Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
47 commits
Select commit Hold shift + click to select a range
11e817d
Initial github actions migration
notoriaga Jan 26, 2021
18f4a40
Comments
notoriaga Jan 26, 2021
910c9b8
Remove unused inputs
notoriaga Jan 26, 2021
3b99ba9
Try not running if no changes
notoriaga Jan 27, 2021
82a880a
Don't create release if it exists
notoriaga Jan 27, 2021
0772660
Cleanup rust build
notoriaga Jan 27, 2021
7b64d93
Replace setup-rust custom action
notoriaga Jan 27, 2021
de1438d
Remove custom publish action
notoriaga Mar 2, 2021
ae82d3a
disable haskell
notoriaga Mar 2, 2021
6bb6645
zip
notoriaga Mar 2, 2021
2c2cdf8
zip
notoriaga Mar 2, 2021
dac8228
right dir
notoriaga Mar 2, 2021
0606638
undo .gitignore change
notoriaga Mar 2, 2021
6642150
zip part II
notoriaga Mar 2, 2021
e1f398a
Revert "undo .gitignore change"
notoriaga Mar 2, 2021
7110807
update .gitignore
notoriaga Mar 2, 2021
53531f6
on workflow_dispatch
notoriaga Mar 2, 2021
3996fbe
zip III
notoriaga Mar 2, 2021
5a064af
Cleanup
notoriaga Mar 2, 2021
3196d07
Spacing
notoriaga Mar 2, 2021
63e8ce6
fix
notoriaga Mar 2, 2021
541743f
s/main/master
notoriaga Mar 3, 2021
015418d
test other langs
notoriaga Mar 15, 2021
561534c
Cleanup
notoriaga Mar 15, 2021
16e293f
Install python 3.7
notoriaga Mar 15, 2021
5f0a446
build haskell
notoriaga Mar 15, 2021
683b3c5
Fix rust build
notoriaga Mar 15, 2021
2ceaced
Remove comment
notoriaga Mar 15, 2021
5b97516
Trigger workflow when you change it
notoriaga Mar 16, 2021
3c6cbd9
typo
notoriaga Mar 16, 2021
1c2f71b
try setting shell
notoriaga Mar 16, 2021
755c37c
Add package.json to javascript wf triggers
notoriaga Mar 16, 2021
9f7b708
Add auto cancellation
notoriaga Mar 18, 2021
d0ecf82
Add requirements.txt/tox.ini to wf triggers
notoriaga Mar 18, 2021
b4585e0
Add other build scripts to wf triggers
notoriaga Mar 18, 2021
fc08783
Split test-javascript into two recipe lines
notoriaga Mar 18, 2021
7fda80d
Bump serialport (js)
notoriaga Mar 18, 2021
af8f6ad
warmer
notoriaga Mar 18, 2021
f5b3452
Add Cargo.lock/toml
notoriaga Mar 18, 2021
9f1372d
Upgrade hyperfine and allow it to determine runs
Mar 19, 2021
70423fd
don't upgrade hyperfine...
Mar 19, 2021
8d492b2
build on older versions of things
Mar 19, 2021
5e361cf
Merge branch 'master' into steve/github-actions
Mar 19, 2021
5ca0396
more slack in times
Mar 19, 2021
779d7aa
Update benchmark_main.py
Mar 19, 2021
b94965e
Update benchmark_main.py
Mar 19, 2021
45caa6b
shellcheck
Mar 19, 2021
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions .github/workflows/auto-cancellation.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
name: Cancel old jobs
on: pull_request
jobs:
cancel:
name: auto-cancellation-running-action
runs-on: ubuntu-latest
steps:
- uses: fauguste/[email protected]
with:
githubToken: ${{ secrets.GITHUB_TOKEN }}
32 changes: 32 additions & 0 deletions .github/workflows/benchmark.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
name: Benchmarks
on:
workflow_dispatch:
push:
branches:
- master
tags:
- "*"
pull_request:
paths:
- "python/**"
- "haskell/**"
- "rust/**"
- scripts/ci_benchmark.bash
- scripts/ci_benchmark_install.bash
- .github/workflows/benchmark.yaml
jobs:
benchmark:
name: Benchmark
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2

- name: Setup
run: ./scripts/ci_prepare_python.bash

- name: Run benchmarks
run: |
source ./scripts/ci_benchmark_install.bash
./scripts/ci_benchmark.bash
env:
VIA_DOCKER: y
35 changes: 35 additions & 0 deletions .github/workflows/c.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
name: C
on:
workflow_dispatch:
push:
branches:
- master
tags:
- "*"
pull_request:
paths:
- "c/**"
- .github/workflows/c.yaml
jobs:
coverage:
name: Test
runs-on: ubuntu-18.04
steps:
- uses: actions/checkout@v2
with:
submodules: recursive
fetch-depth: 0

- name: Setup
run: |
sudo apt-get -qq update
sudo apt-get -qq install lcov

- name: Run tests
run: make test-c
env:
CMAKEFLAGS: -DCODE_COVERAGE=ON -DCMAKE_BUILD_TYPE=Debug

- name: Upload coverage to codecov.io
run: |
bash <(curl -s https://codecov.io/bash) -s c/build || echo "Codecov did not collect coverage reports";
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

IIRC, the bash codecov usually doesnt set an exit status, so the || .. here is useless.

This upload isnt working; see https://github.com/swift-nav/libsbp/runs/2124966802#step:5:530

It seems codecov hasnt been working for a while in this repo, so perhaps that could be another task to get them all working in github actions after this PR.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It seems codecov<->github-integration isnt enabled for this repo. It is possible to send reports without that integration being enabled.

68 changes: 68 additions & 0 deletions .github/workflows/haskell.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,68 @@
name: Haskell
on:
workflow_dispatch:
push:
branches:
- master
tags:
- "*"
pull_request:
paths:
- "haskell/**"
- .github/workflows/haskell.yaml
jobs:
build:
name: Build
runs-on: ubuntu-18.04
steps:
- uses: actions/checkout@v2

- uses: haskell/actions/setup@v1
with:
enable-stack: true

- name: Build binaries
id: build
working-directory: ./haskell
run: |
VERSION="$(git describe --always --tags --dirty)"
BUILD_TRIPLET="$(cc -dumpmachine)"
ARTIFACT_NAME="sbp_tools_haskell-${VERSION}-${BUILD_TRIPLET}.zip"

mkdir ./bins
stack install --local-bin-path ./bins
cd ./bins
zip ../$ARTIFACT_NAME \
sbp2json \
sbp2prettyjson \
sbp2yaml \
json2sbp \
json2json \
sbp2nmea
echo "::set-output name=artifact_name::$ARTIFACT_NAME"

- uses: actions/upload-artifact@v2
with:
name: ${{ steps.build.outputs.artifact_name }}
path: ./haskell/${{ steps.build.outputs.artifact_name }}

publish:
if: startsWith(github.ref, 'refs/tags/v')
needs: [build]
name: Publish github release
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2

- uses: actions/download-artifact@v2
with:
path: artifacts

- name: Upload Release
uses: svenstaro/upload-release-action@v1-release
with:
repo_token: ${{ secrets.GITHUB_TOKEN }}
file: "artifacts/*/*.zip"
tag: ${{ github.ref }}
overwrite: true
file_glob: true
21 changes: 21 additions & 0 deletions .github/workflows/java.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
name: Java
on:
workflow_dispatch:
push:
branches:
- master
tags:
- "*"
pull_request:
paths:
- "java/**"
- .github/workflows/java.yaml
jobs:
coverage:
name: Test
runs-on: ubuntu-18.04
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

there are three jvms on https://github.com/actions/virtual-environments/blob/ubuntu18/20210309.1/images/linux/Ubuntu1804-README.md . It would be useful to print the JVM version that is being used for these tests. (Under Travis, the version was explicitly being set to 1.8.0)

steps:
- uses: actions/checkout@v2

- name: Run tests
run: make test-java
24 changes: 24 additions & 0 deletions .github/workflows/javascript.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
name: JavaScript
on:
workflow_dispatch:
push:
branches:
- master
tags:
- "*"
pull_request:
paths:
- "javascript/**"
- package.json
- package-lock.json
- .github/workflows/javascript.yaml
jobs:
coverage:
name: Test
runs-on: ubuntu-18.04
steps:
- uses: actions/checkout@v2

- name: Run tests
shell: bash
run: make test-javascript
27 changes: 27 additions & 0 deletions .github/workflows/python.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
name: Python
on:
workflow_dispatch:
push:
branches:
- master
tags:
- "*"
pull_request:
paths:
- "python/**"
- requirements.txt
- tox.ini
- scripts/ci_prepare_python.bash
- .github/workflows/python.yaml
jobs:
coverage:
name: Test
runs-on: ubuntu-18.04
steps:
- uses: actions/checkout@v2

- name: Setup
run: ./scripts/ci_prepare_python.bash

- name: Run tests
run: make test-python
109 changes: 109 additions & 0 deletions .github/workflows/rust.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,109 @@
name: Rust
on:
workflow_dispatch:
push:
branches:
- master
tags:
- "*"
pull_request:
paths:
- "rust/**"
- Cargo.toml
- Cargo.lock
- scripts/ci_prepare_rust.bash
- scripts/ci_build_rust.bash
- .github/workflows/rust.yaml
jobs:
lint:
name: Format and lint
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2

- run: ./scripts/ci_prepare_rust.bash
shell: bash

- uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: stable
override: true
components: rustfmt

- uses: actions-rs/cargo@v1
name: Format Check
with:
command: fmt
args: -- --check

test:
name: Tests
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2

- run: ./scripts/ci_prepare_rust.bash
shell: bash

- uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: stable
override: true

- name: Run tests
run: make test-rust

build:
name: Build binaries
needs: [lint, test]
strategy:
matrix:
os:
- ubuntu-18.04
- macos-10.15
- windows-2016
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v2

- run: ./scripts/ci_prepare_rust.bash
shell: bash

- uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: stable
override: true

- name: Build ${{ matrix.os }} binaries
id: build
run: ./scripts/ci_build_rust.bash
shell: bash

- uses: actions/upload-artifact@v2
with:
name: ${{ steps.build.outputs.artifact_name }}
path: ${{ steps.build.outputs.artifact_name }}

publish:
if: startsWith(github.ref, 'refs/tags/v')
needs: [build]
name: Publish github release
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2

- uses: actions/download-artifact@v2
with:
path: artifacts

- name: Upload Release
uses: svenstaro/upload-release-action@v1-release
with:
repo_token: ${{ secrets.GITHUB_TOKEN }}
file: "artifacts/*/*.zip"
tag: ${{ github.ref }}
overwrite: true
file_glob: true
Loading