Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Modernize CI configuration #11

Merged
merged 1 commit into from
May 23, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
62 changes: 35 additions & 27 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
@@ -1,55 +1,63 @@
# Test libsodiumd on all three platforms
name: Test

on: [pull_request, push]
on:
push:
branches:
- 'upstream-*'
tags:
- 'v*'
pull_request:
branches:
- 'upstream-*'
# Do a periodic build (every Monday at 0600) to ensure integrity
schedule:
- cron: '0 6 * * 1'

jobs:
main:
name: Run
strategy:
fail-fast: false
matrix:
os: [ ubuntu-18.04, macOS-10.15, windows-2019 ]
# DMD < 2.087.1 does not work on Mac OSX Catalina (10.15) because druntime used
# a private symbol, hence this is the minimum required version
# However, while compiling with DMD 2.087.1 works on Catalina,
# the distributed binary was not built with it until 2.090.0
dc: [ dmd-master, ldc-master, dmd-latest, ldc-latest, dmd-2.090.0, ldc-1.17.0 ]
exclude:
# https://github.com/dlang/dub/issues/1914
# https://github.com/dlang/dub/issues/1915
- { os: windows-2019, dc: dmd-master }
- { os: windows-2019, dc: dmd-latest }
- { os: windows-2019, dc: dmd-2.090.0 }
include:
- { os: macos-latest, dc: ldc-latest }
- { os: ubuntu-latest, dc: dmd-latest }
- { os: ubuntu-latest, dc: ldc-latest }
# https://github.com/dlang/dub/issues/1914
# https://github.com/dlang/dub/issues/1915
# - { os: windows-latest, dc: dmd-latest }
# - { os: windows-latest, dc: ldc-latest }

runs-on: ${{ matrix.os }}
timeout-minutes: 30
steps:

# Checkout this repository
- uses: actions/checkout@v2
- uses: actions/checkout@v4
with:
# For codecov
fetch-depth: 2
# Install the D compiler
- name: Prepare compiler
uses: mihails-strasuns/setup-dlang@v1
uses: dlang-community/setup-dlang@v1
with:
compiler: ${{ matrix.dc }}

# Install os-specific packages
- name: '[Posix] Install dependencies'
if: runner.os == 'macOS' || runner.os == 'Linux'
# Install os-specific packages.
# We only need pkg-config and libsodium, which *might* already be installed.
# See https://github.com/actions/runner-images for included software / libraries
- name: '[Linux] Install dependencies'
if: runner.os == 'Linux'
run: |
if [ '${{ runner.os }}' == 'macOS' ]; then
brew install pkg-config libsodium
elif [ '${{ runner.os }}' == 'Linux' ]; then
sudo add-apt-repository ppa:ubuntu-toolchain-r/test
sudo apt-get update
sudo apt-get install libsodium-dev
fi
sudo add-apt-repository ppa:ubuntu-toolchain-r/test
sudo apt-get update
sudo apt-get install libsodium-dev

- name: '[Windows] Load libsodium from cache'
id: cache-libsodium
if: runner.os == 'Windows'
uses: actions/cache@v1
uses: actions/cache@v4
with:
path: ${{ github.workspace }}\lib\libsodium\x64\Release\v142\static\
key: libsodium-1.0.18
Expand Down Expand Up @@ -87,6 +95,6 @@ jobs:
if %errorlevel% neq 0 exit /b %errorlevel%

- name: 'Upload code coverage'
uses: codecov/codecov-action@v1
uses: codecov/codecov-action@v4
with:
flags: unittests
45 changes: 0 additions & 45 deletions .travis.yml

This file was deleted.

1 change: 0 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
## Libsodiumd: D bindings for libsodium

[![Build Status](https://travis-ci.com/geod24/libsodiumd.svg?branch=upstream-1.0.17)](https://travis-ci.com/geod24/libsodiumd)
[![DUB Package](https://img.shields.io/dub/v/libsodiumd.svg)](https://code.dlang.org/packages/libsodiumd)

Currently supported version: v1.0.18 (released 2019-05-31)
Expand Down
Loading