diff --git a/.gitea/workflows/test.yaml b/.gitea/workflows/test.yaml index 608aec3..9f1d9c7 100644 --- a/.gitea/workflows/test.yaml +++ b/.gitea/workflows/test.yaml @@ -1,9 +1,6 @@ -name: Verilator Unit Tests +name: Unit Tests on: [push] -defaults: - run: - shell: nix develop --command bash {0} jobs: test: name: Test @@ -12,11 +9,5 @@ jobs: - uses: actions/checkout@v4 - uses: DeterminateSystems/nix-installer-action@main - uses: DeterminateSystems/magic-nix-cache-action@main - - name: Build Testbench Simulator - run: | - cmake -B build/ -GNinja - cmake --build build/ - working-directory: ./sim - - name: Run Simulator - run: ./build/sim_test - working-directory: ./sim + - name: Build Groovylight + run: nix build . diff --git a/.gitignore b/.gitignore index a61aa27..93f5399 100644 --- a/.gitignore +++ b/.gitignore @@ -205,3 +205,5 @@ cython_debug/ # and can be added to the global gitignore or merged into this file. For a more nuclear # option (not recommended) you can uncomment the following to ignore the entire idea folder. #.idea/ + +result diff --git a/flake.nix b/flake.nix index cad3c3c..e000f79 100644 --- a/flake.nix +++ b/flake.nix @@ -29,6 +29,14 @@ system, ... }: + let + toolchain-pkgs = with pkgs; [ + yosys + nextpnr + trellis + openfpgaloader + ]; + in { formatter = pkgs.nixfmt-rfc-style; packages.default = pkgs.python3.pkgs.buildPythonPackage { @@ -45,32 +53,28 @@ ]; doCheck = true; - nativeCheckInputs = with pkgs; [ - python3.pkgs.pytestCheckHook - yosys - nextpnr - trellis - openfpgaloader - ]; + nativeCheckInputs = + with pkgs; + [ + python3.pkgs.pytestCheckHook + ] + ++ toolchain-pkgs; }; devShells.default = pkgs.mkShell { - packages = with pkgs; [ - (python3.withPackages ( - pypkgs: with pypkgs; [ - amaranth - amaranth-boards - self'.packages.default - ] - )) - yosys - nextpnr - # support package - trellis - # loader - openfpgaloader - ecpdap # easier to poke probes. - ]; + packages = + with pkgs; + [ + (python3.withPackages ( + pypkgs: with pypkgs; [ + amaranth + amaranth-boards + self'.packages.default + ] + )) + ecpdap # easier to poke probes. + ] + ++ toolchain-pkgs; }; }; };