Skip to content

Commit

Permalink
Include&Install
Browse files Browse the repository at this point in the history
  • Loading branch information
AngryMaciek committed Aug 1, 2023
1 parent 2b6d655 commit 3d8d27f
Show file tree
Hide file tree
Showing 4 changed files with 88 additions and 47 deletions.
42 changes: 0 additions & 42 deletions .github/workflows/include.yml

This file was deleted.

41 changes: 40 additions & 1 deletion .github/workflows/install.yml → .github/workflows/user.yml
Original file line number Diff line number Diff line change
@@ -1,8 +1,47 @@
name: Install
name: Include&Install

on: [push]

jobs:

Include:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [macos-12, ubuntu-22.04]
env:
working-directory: .test/include

steps:

- name: Install MPFR
run: |
if [ "$RUNNER_OS" == "Linux" ]; then
sudo apt-get update -y
sudo apt-get install -y libmpfr-dev
elif [ "$RUNNER_OS" == "macOS" ]; then
brew update
brew install mpfr
fi
- name: Checkout Repository
uses: actions/checkout@v2

- name: Copy Library Directory
working-directory: ${{env.working-directory}}
run: cp -r ../../hypercomplex hypercomplex

- name: Display compiler version
run: g++ --version

- name: Compile Test Program
working-directory: ${{env.working-directory}}
run: g++ --std=c++17 test.cpp -o test -lmpfr -lgmp

- name: Execute Test Program
working-directory: ${{env.working-directory}}
run: ./test

Install:
runs-on: ${{ matrix.os }}
strategy:
Expand Down
45 changes: 45 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
repos:

- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.4.0
hooks:

- id: no-commit-to-branch
name: "[01/09] Forbid committing to `master` branch"
args: [--branch=master]
always_run: true

- id: check-merge-conflict
name: "[02/09] Check for merge conflict strings"
always_run: true

- id: check-case-conflict
name: "[03/09] Guard against case-insensitive filesystems"
always_run: true

- id: fix-byte-order-marker
name: "[04/09] Remove UTF-8 byte order marker (BOM)"
always_run: true

- id: check-added-large-files
name: "[05/09] Forbid commiting files bigger than 1MB"
args: [— maxkb=1024]
always_run: true

- id: trailing-whitespace
name: "[06/09] Check for trailing whitespaces"
args: [--markdown-linebreak-ext=md]
always_run: true

- id: end-of-file-fixer
name: "[07/09] Ensure 1 newline at the end of each file"
always_run: true

- id: mixed-line-ending
name: "[08/09] Correct mixed line endings"
always_run: true

- id: check-yaml
name: "[09/09] Check YAML files syntax"
files: \.ya?ml$
always_run: true
7 changes: 3 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,11 +1,10 @@
[![Contribute with Gitpod](https://img.shields.io/badge/Contribute%20with-Gitpod-908a85?logo=gitpod)](https://gitpod.io/#https://github.com/AngryMaciek/hypercomplex)
[![pre-commit](https://img.shields.io/badge/pre--commit-+-brightgreen?logo=pre-commit)](https://github.com/pre-commit/pre-commit)
[![build](https://github.com/AngryMaciek/hypercomplex/workflows/Include/badge.svg?branch=master)](https://github.com/AngryMaciek/hypercomplex/actions?query=workflow%3AInclude)
[![build](https://github.com/AngryMaciek/hypercomplex/workflows/Install/badge.svg?branch=master)](https://github.com/AngryMaciek/hypercomplex/actions?query=workflow%3AInstall)
[![build](https://github.com/AngryMaciek/hypercomplex/workflows/Catch2/badge.svg?branch=master)](https://github.com/AngryMaciek/hypercomplex/actions?query=workflow%3ACatch2)
[![user](https://github.com/AngryMaciek/hypercomplex/workflows/user/badge.svg?branch=master)](https://github.com/AngryMaciek/hypercomplex/actions?query=workflow%3Auser)
[![catch2](https://github.com/AngryMaciek/hypercomplex/workflows/Catch2/badge.svg?branch=master)](https://github.com/AngryMaciek/hypercomplex/actions?query=workflow%3ACatch2)
[![codecov](https://codecov.io/gh/AngryMaciek/hypercomplex/branch/master/graph/badge.svg?token=SSKOK4XR1M)](https://codecov.io/gh/AngryMaciek/hypercomplex)
[![Cpp17](https://img.shields.io/badge/C%2B%2B-17-blue)](https://en.wikipedia.org/wiki/C%2B%2B17)
[![build](https://github.com/AngryMaciek/hypercomplex/workflows/cpplint/badge.svg?branch=master)](https://github.com/AngryMaciek/hypercomplex/actions?query=workflow%3Acpplint)
[![cpplint](https://github.com/AngryMaciek/hypercomplex/workflows/cpplint/badge.svg?branch=master)](https://github.com/AngryMaciek/hypercomplex/actions?query=workflow%3Acpplint)
[![CodeFactor](https://www.codefactor.io/repository/github/angrymaciek/hypercomplex/badge)](https://www.codefactor.io/repository/github/angrymaciek/hypercomplex)
[![docs](https://github.com/AngryMaciek/hypercomplex/workflows/docs/badge.svg?branch=master)](https://github.com/AngryMaciek/hypercomplex/actions?query=workflow%3Adocs)
[![DOI](https://joss.theoj.org/papers/10.21105/joss.05272/status.svg)](https://doi.org/10.21105/joss.05272)
Expand Down

0 comments on commit 3d8d27f

Please sign in to comment.