Skip to content

Commit

Permalink
Make names consistent
Browse files Browse the repository at this point in the history
  • Loading branch information
Joseph-Edwards committed May 10, 2024
1 parent fcae469 commit 9fe8e55
Show file tree
Hide file tree
Showing 8 changed files with 162 additions and 163 deletions.
120 changes: 60 additions & 60 deletions .github/actions/test_with_valgrind/action.yml
Original file line number Diff line number Diff line change
@@ -1,88 +1,88 @@
name: 'Run package tests'
description: 'Run package tests'
name: Run package tests
description: Run package tests
inputs:
NO_COVERAGE:
description: 'set to a non-empty string to suppress gathering coverage'
description: set to a non-empty string to suppress gathering coverage
required: false
type: string
default: ''
default: ""
GAP_TESTFILE:
description: 'Name of the GAP file to be read for executing the package tests (overrides TestFile in PackageInfo.g)'
description: Name of the GAP file to be read for executing the package tests (overrides TestFile in PackageInfo.g)
required: false
type: string
default: ''
default: ""
only-needed:
description: 'If set to true then only needed dependencies of the package being tested are loaded'
description: If set to true then only needed dependencies of the package being tested are loaded
required: false
type: boolean
default: false
pre-gap:
description: 'Commands to be prepended to gap'
description: Commands to be prepended to gap
required: false
type: string
default: ''
default: ""

env:
CHERE_INVOKING: 1

runs:
using: "composite"
using: composite
steps:
- name: "Run tests"
run: |
set -ex
- name: Run tests
run: |
set -ex
GAPROOT=${GAPROOT-$HOME/gap}
GAPROOT=${GAPROOT-$HOME/gap}
# set up a custom GAP root containing only this package, so that
# we can force GAP to load the correct version of this package
# (we already did that in build_pkg.sh, but we do it again here,
# to allow the occasional instance where a package wants to also
# run the tests of others packages, by invoking this script multiple
# times in different directories)
mkdir -p /tmp/gaproot/pkg/
ln -f -s $PWD /tmp/gaproot/pkg/
# set up a custom GAP root containing only this package, so that
# we can force GAP to load the correct version of this package
# (we already did that in build_pkg.sh, but we do it again here,
# to allow the occasional instance where a package wants to also
# run the tests of others packages, by invoking this script multiple
# times in different directories)
mkdir -p /tmp/gaproot/pkg/
ln -f -s $PWD /tmp/gaproot/pkg/
# start GAP with custom GAP root, to ensure correct package version is loaded
GAP="${{ inputs.pre-gap }} $GAPROOT/gap -l /tmp/gaproot; --quitonbreak"
# start GAP with custom GAP root, to ensure correct package version is loaded
GAP="${{ inputs.pre-gap }} $GAPROOT/gap -l /tmp/gaproot; --quitonbreak"
if ${{ inputs.only-needed }} = 'true' ; then
GAP="$GAP -A"
fi
if ${{ inputs.only-needed }} = 'true' ; then
GAP="$GAP -A"
fi
# Unless explicitly turned off by setting the NO_COVERAGE environment variable,
# we collect coverage data
if [[ -z "${{ inputs.NO_COVERAGE }}" ]]; then
mkdir -p ${COVDIR-coverage}
GAP="$GAP --cover ${COVDIR-coverage}/$(mktemp XXXXXX).coverage"
fi
# Unless explicitly turned off by setting the NO_COVERAGE environment variable,
# we collect coverage data
if [[ -z "${{ inputs.NO_COVERAGE }}" ]]; then
mkdir -p ${COVDIR-coverage}
GAP="$GAP --cover ${COVDIR-coverage}/$(mktemp XXXXXX).coverage"
fi
cat > __TEST_RUNNNER__.g <<EOF
cat > __TEST_RUNNNER__.g <<EOF
GAP_TESTFILE:="${{ inputs.GAP_TESTFILE }}";
Read("PackageInfo.g");
info := GAPInfo.PackageInfoCurrent;
if IsEmpty(GAP_TESTFILE) or not IsExistingFile(GAP_TESTFILE) then
GAP_TESTFILE := info.TestFile;
fi;
# Load the package with debug info
SetInfoLevel(InfoPackageLoading, PACKAGE_DEBUG);
SetPackagePath(info.PackageName, "/tmp/gaproot/pkg/$(basename $PWD)");
if ${{ inputs.only-needed }} = true then
LoadPackage(info.PackageName : OnlyNeeded);
else
LoadPackage(info.PackageName);
fi;
SetInfoLevel(InfoPackageLoading, PACKAGE_ERROR);
Print("Now running tests from ", GAP_TESTFILE, "\n");
if EndsWith(GAP_TESTFILE, ".tst") then
QUIT_GAP(Test(GAP_TESTFILE, rec(compareFunction := "uptowhitespace")));
else
Read(GAP_TESTFILE);
Error("Package TestFile did not exit gap");
fi;
EOF
GAP_TESTFILE:="${{ inputs.GAP_TESTFILE }}";
Read("PackageInfo.g");
info := GAPInfo.PackageInfoCurrent;
if IsEmpty(GAP_TESTFILE) or not IsExistingFile(GAP_TESTFILE) then
GAP_TESTFILE := info.TestFile;
fi;
# Load the package with debug info
SetInfoLevel(InfoPackageLoading, PACKAGE_DEBUG);
SetPackagePath(info.PackageName, "/tmp/gaproot/pkg/$(basename $PWD)");
if ${{ inputs.only-needed }} = true then
LoadPackage(info.PackageName : OnlyNeeded);
else
LoadPackage(info.PackageName);
fi;
SetInfoLevel(InfoPackageLoading, PACKAGE_ERROR);
Print("Now running tests from ", GAP_TESTFILE, "\n");
if EndsWith(GAP_TESTFILE, ".tst") then
QUIT_GAP(Test(GAP_TESTFILE, rec(compareFunction := "uptowhitespace")));
else
Read(GAP_TESTFILE);
Error("Package TestFile did not exit gap");
fi;
EOF
$GAP __TEST_RUNNNER__.g
$GAP __TEST_RUNNNER__.g
shell: bash
shell: bash
6 changes: 3 additions & 3 deletions .github/workflows/codespell.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: codespell
name: Codespell
on:
workflow_dispatch:
pull_request:
Expand All @@ -10,5 +10,5 @@ jobs:
codespell:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: codespell-project/actions-codespell@v2
- uses: actions/checkout@v4
- uses: codespell-project/actions-codespell@v2
42 changes: 21 additions & 21 deletions .github/workflows/config_options.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: "Config-options"
name: Config-options
on:
workflow_dispatch:
pull_request:
Expand All @@ -8,22 +8,22 @@ on:
- stable-*.*
schedule:
# Every day at 3:30 AM UTC
- cron: "30 3 * * *"
- cron: 30 3 * * *
env:
NO_COVERAGE: true

jobs:
with-external-planarity-bliss:
name: "${{ matrix.bliss }} ${{ matrix.planarity }}"
runs-on: "ubuntu-latest"
name: ${{ matrix.bliss }} ${{ matrix.planarity }}
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
planarity:
- "--with-external-planarity"
- --with-external-planarity
- ""
bliss:
- "--with-external-bliss"
- --with-external-bliss
- ""
exclude:
- planarity: ""
Expand All @@ -33,38 +33,38 @@ jobs:
shell: bash -l {0}
steps:
- uses: actions/checkout@v4
- name: Output g++ version
- name: Output g++ version . . .
run: g++ --version
- name: "Install micromamba environment from environment.yml . . ."
- name: Install micromamba environment from environment.yml . . .
uses: mamba-org/setup-micromamba@v1
with:
environment-name: digraphs
cache-environment: true
create-args: ${{ matrix.bliss && 'bliss' || '' }} ${{ matrix.planarity && 'planarity' || ''}}
- name: "Set environment variables . . ."
- name: Set environment variables . . .
run: |
echo "PKG_CONFIG_PATH=$MAMBA_ROOT_PREFIX/envs/digraphs/lib/pkgconfig:$MAMBA_ROOT_PREFIX/envs/digraphs/share/pkgconfig" >> $GITHUB_ENV
echo "LD_LIBRARY_PATH=$MAMBA_ROOT_PREFIX/envs/digraphs/lib" >> $GITHUB_ENV
echo "CFLAGS=-I$MAMBA_ROOT_PREFIX/envs/digraphs/include" >> $GITHUB_ENV
echo "LDFLAGS=-L$MAMBA_ROOT_PREFIX/envs/digraphs/lib" >> $GITHUB_ENV
- name: "Install GAP and clone/compile necessary packages"
- name: Install GAP and clone/compile necessary packages . . .
uses: gap-actions/setup-gap@v2
with:
GAP_PKGS_TO_CLONE: "NautyTracesInterface digraphs/graphviz"
GAP_PKGS_TO_BUILD: "io orb datastructures grape NautyTracesInterface"
GAP_PKGS_TO_CLONE: NautyTracesInterface digraphs/graphviz
GAP_PKGS_TO_BUILD: io orb datastructures grape NautyTracesInterface
GAPBRANCH: stable-4.13
- name: "Build Digraphs"
- name: Build Digraphs . . .
uses: gap-actions/build-pkg@v1
with:
CONFIGFLAGS: ${{ matrix.bliss }} ${{ matrix.planarity }}
- name: "Run Digraphs package's tst/teststandard.g"
- name: Run Digraphs package's tst/teststandard.g . . .
uses: gap-actions/run-pkg-tests@v2
with:
NO_COVERAGE: true

all-options:
name: ${{ matrix.debug }} ${{ matrix.warnings }} ${{ matrix.without-intrinsics }}
runs-on: "ubuntu-latest"
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
Expand All @@ -84,17 +84,17 @@ jobs:

steps:
- uses: actions/checkout@v4
- name: Output g++ version
- name: Output g++ version . . .
run: g++ --version
- name: "Install GAP and clone/compile necessary packages"
- name: Install GAP and clone/compile necessary packages . . .
uses: gap-actions/setup-gap@v2
with:
GAP_PKGS_TO_CLONE: "NautyTracesInterface digraphs/graphviz"
GAP_PKGS_TO_BUILD: "io orb datastructures grape NautyTracesInterface"
GAP_PKGS_TO_CLONE: NautyTracesInterface digraphs/graphviz
GAP_PKGS_TO_BUILD: io orb datastructures grape NautyTracesInterface
GAPBRANCH: stable-4.13
- name: "Build Digraphs"
- name: Build Digraphs . . .
uses: gap-actions/build-pkg@v1
with:
CONFIGFLAGS: ${{ matrix.debug }} ${{ matrix.without-intrinsics }} ${{ matrix.warnings && '--enable-compile-warnings WARNING_CXXFLAGS="-Werror" WARNING_CFLAGS="-Werror"' || '' }}
- name: "Run Digraphs package's tst/teststandard.g"
- name: Run Digraphs package's tst/teststandard.g . . .
uses: gap-actions/run-pkg-tests@v2
23 changes: 11 additions & 12 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: "Lint"
name: Lint
on:
workflow_dispatch:
pull_request:
Expand All @@ -8,11 +8,11 @@ on:
- stable-*.*
schedule:
# Every day at 3:30 AM UTC
- cron: '30 3 * * *'
- cron: 30 3 * * *

jobs:
lint:
name: "${{ matrix.linter }}"
name: ${{ matrix.linter }}
runs-on: ubuntu-latest
strategy:
fail-fast: false
Expand All @@ -21,12 +21,11 @@ jobs:
- gaplint
- cpplint
steps:
- name: "Check out the repository"
uses: actions/checkout@v4
- name: "Set up Python"
uses: actions/setup-python@v5
- name: "Install ${{ matrix.linter }} with pip"
run: pip install ${{ matrix.linter }}
- name: "Run ${{ matrix.linter }} on the Digraphs package"
run: bash etc/${{ matrix.linter }}.sh

- name: Check out the repository . . .
uses: actions/checkout@v4
- name: Set up Python . . .
uses: actions/setup-python@v5
- name: Install ${{ matrix.linter }} with pip . . .
run: pip install ${{ matrix.linter }}
- name: Run ${{ matrix.linter }} on the Digraphs package . . .
run: bash etc/${{ matrix.linter }}.sh
16 changes: 8 additions & 8 deletions .github/workflows/manual.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: "Manual"
name: Manual
on:
workflow_dispatch:
pull_request:
Expand All @@ -8,15 +8,15 @@ on:
- stable-*.*
schedule:
# Every day at 3:20 AM UTC
- cron: '20 3 * * *'
- cron: "20 3 * * *"

jobs:
manual:
name: "compile and upload manual"
name: compile and upload manual
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: "Install TeX Live"
- name: Install TeX Live . . .
run: |
packages=(
texlive-latex-base
Expand All @@ -30,14 +30,14 @@ jobs:
sudo apt-get install "${packages[@]}"
- uses: gap-actions/setup-gap@v2
env:
GAP_BOOTSTRAP: "minimal"
GAP_BOOTSTRAP: minimal
with:
GAP_PKGS_TO_BUILD: ''
GAP_PKGS_TO_BUILD: ""
- uses: gap-actions/build-pkg-docs@v1
- name: "Upload compiled manuals"
- name: Upload compiled manuals . . .
uses: actions/upload-artifact@v4
with:
name: "Digraphs manual"
name: Digraphs manual
retention-days: 7
path: |
doc/manual.pdf
Expand Down
Loading

0 comments on commit 9fe8e55

Please sign in to comment.