Skip to content

Commit

Permalink
BLD: Add workflow.
Browse files Browse the repository at this point in the history
  • Loading branch information
MilanSkocic committed Nov 13, 2023
1 parent ad6237d commit 200f6dc
Show file tree
Hide file tree
Showing 3 changed files with 77 additions and 1 deletion.
73 changes: 73 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,73 @@
name: CI

on:
push:
branches: [ "main", "dev" ]
pull_request:
branches: [ "main", "dev" ]

jobs:
linux:
runs-on: ubuntu-latest
steps:
- name: Gfortran
run: |
sudo update-alternatives \
--install /usr/bin/gcc gcc /usr/bin/gcc-10 100 \
--slave /usr/bin/gfortran gfortran /usr/bin/gfortran-10 \
--slave /usr/bin/gcov gcov /usr/bin/gcov-10
- name: Set FPM
uses: fortran-lang/setup-fpm@v5
with:
fpm-version: "v0.9.0"
- name: Gfortran version
run : gfortran --version
- name: Checkout
uses: actions/checkout@v4
- name: Compile
run: |
. ./configure.sh
make
macos:
runs-on: macos-latest
steps:
- name: Gfortran
run: |
brew reinstall gcc@10 gcc@13
- name: Set FPM
uses: fortran-lang/setup-fpm@v5
with:
fpm-version: "v0.9.0"
- name: Gfortran version
run : gfortran --version
- name: Checkout
uses: actions/checkout@v4
- name: Compile
run: |
. ./configure.sh
make
windows:
runs-on: windows-latest
defaults:
run:
shell: msys2 {0}
steps:
- name: MSYS2, Gfortran, fpm
uses: msys2/setup-msys2@v2
with:
msystem: MINGW64
install: >-
mingw-w64-x86_64-gcc-fortran
mingw-w64-x86_64-fpm
git
make
- name: Gfortran version
run : gfortran --version
- name: Checkout
uses: actions/checkout@v4
- name: Compile
run: |
. ./configure.sh
make
3 changes: 2 additions & 1 deletion INSTALL.rst
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
A Makefile is provided, which uses `fpm <https://fpm.fortran-lang.org/en/index.html>`_, for building the library.
A Makefile is provided, which uses `fpm <https://fpm.fortran-lang.org/en/index.html>`_,
for building the library.

On windows, `msys2 <https://www.msys2.org>`_ needs to be installed.

Expand Down
2 changes: 2 additions & 0 deletions README.rst
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
Description
==============

.. image:: https://github.com/MilanSkocic/ecx/actions/workflows/ci.yml/badge.svg?branch=main

.. readme_inclusion_start
`codata` is a Fortran library providing the lastest codata constants (2018).
Expand Down

0 comments on commit 200f6dc

Please sign in to comment.