-
Notifications
You must be signed in to change notification settings - Fork 1
84 lines (73 loc) · 2.32 KB
/
dbuild-linux.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
name: linux ldc build
on: [push, pull_request]
jobs:
linux-build:
name: linux Dub build
strategy:
matrix:
os: [ubuntu-latest]
dc: [ldc-latest]
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v2
with:
submodules: recursive
- name: Install D compiler
uses: dlang-community/setup-dlang@v1
with:
compiler: ${{ matrix.dc }}
- name: Install htslib deps
run: |
sudo apt-get update && sudo apt-get install -y build-essential autoconf zlib1g-dev libbz2-dev liblzma-dev libcurl4-openssl-dev libssl-dev python cython
- name: Get dhtslib commit
id: get-dhtslib-commit
run: echo "::set-output name=sha_short::$(git rev-parse --short :dhtslib)"
- name: Cache dhtslib
id: cache-dhtslib
uses: actions/cache@v2
with:
path: dhtslib
key: ${{ runner.os}}-dhtslib-${{ steps.get-dhtslib-commit.outputs.sha_short }}
- name: Build htslib
if: steps.cache-dhtslib.outputs.cache-hit != 'true'
run: |
cd dhtslib/htslib
autoreconf -i
./configure
make
- name: Install htslib
run: |
cd dhtslib/htslib
sudo make install
sudo ldconfig
- name: Setup additional test files
run: |
cd dhtslib/htslib
cd test
cd tabix
bgzip -c gff_file.gff > gff_file.gff.gz
tabix gff_file.gff.gz
bgzip -c bed_file.bed > bed_file.bed.gz
tabix bed_file.bed.gz
bgzip -c vcf_file.vcf > vcf_file.vcf.gz
tabix vcf_file.vcf.gz
- name: Run build
run: dub build
env:
LIBRARY_PATH: /usr/local/lib
- name: Run unittests
run: dub test
env:
LIBRARY_PATH: /usr/local/lib
- name: Run integration tests
run: |
cd tests
dub test
env:
LIBRARY_PATH: /usr/local/lib
- name: generate coverage
run: dub -q test -b=unittest-cov
env:
LIBRARY_PATH: /usr/local/lib
- name: Upload coverage
run: bash <(curl -s https://codecov.io/bash)