diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 9dc3eccc2..c6c3a7dc6 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -1,6 +1,6 @@ # This is a basic workflow to help you get started with Actions -name: CI +name: docker CI # Controls when the action will run. Triggers the workflow on push or pull request # events but only for the master branch @@ -11,19 +11,6 @@ on: branches: [ master ] jobs: - nix: - runs-on: ubuntu-latest - - steps: - - uses: actions/checkout@v2 - with: - fetch-depth: 0 - - uses: cachix/install-nix-action@v12 - - uses: cachix/cachix-action@v8 - with: - name: coq - - run: nix-build - opam: runs-on: ubuntu-latest strategy: diff --git a/.github/workflows/nix.yml b/.github/workflows/nix.yml new file mode 100644 index 000000000..7b840d580 --- /dev/null +++ b/.github/workflows/nix.yml @@ -0,0 +1,43 @@ +# This is a basic workflow to help you get started with Actions + +name: nix CI + +# Controls when the action will run. Triggers the workflow on push or pull request +# events but only for the master branch +on: + push: + branches: [ master ] + pull_request: + branches: [ master ] + +jobs: + nix: + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v2 + with: + fetch-depth: 0 + - uses: cachix/install-nix-action@v12 + - uses: cachix/cachix-action@v8 + with: + name: math-comp + extraPullNames: coq + authToken: '${{ secrets.CACHIX_AUTH_TOKEN }}' + - run: nix-build + + nixci: + runs-on: ubuntu-latest + needs: nix + + steps: + - uses: actions/checkout@v2 + with: + fetch-depth: 0 + - uses: cachix/install-nix-action@v12 + - uses: cachix/cachix-action@v8 + with: + name: math-comp + extraPullNames: coq + authToken: '${{ secrets.CACHIX_AUTH_TOKEN }}' + - run: nix-build --arg ci true diff --git a/.nix/config.nix b/.nix/config.nix index eadab65be..535edc14c 100644 --- a/.nix/config.nix +++ b/.nix/config.nix @@ -6,5 +6,7 @@ select = "coq-8.13"; inputs."coq-8.13".coqPackages = { coq.override.version = "8.13"; + mathcomp.override.version = "gares:hierarchy-builder"; + mathcomp-single.ci = true; }; } diff --git a/.nix/coq-overlays/mathcomp-single/default.nix b/.nix/coq-overlays/mathcomp-single/default.nix new file mode 100644 index 000000000..228f5f62d --- /dev/null +++ b/.nix/coq-overlays/mathcomp-single/default.nix @@ -0,0 +1,7 @@ +{ mathcomp, coq-elpi, hierarchy-builder, version ? null }: +(mathcomp.override {single = true;}).overrideAttrs (old: { + buildPhase = "make -j $(max_jobs) -C mathcomp ./algebra/ssralg.vo"; + propagatedBuildInputs = old.propagatedBuildInputs ++ + [ coq-elpi hierarchy-builder ]; + installPhase = "echo NO INSTALL"; +})