From dfd5f1a12265b35e88dfcdb157d1fa5e4287e4a9 Mon Sep 17 00:00:00 2001 From: Sergei Zimmerman Date: Sat, 13 Apr 2024 18:53:47 +0300 Subject: [PATCH] ci: add build-all job --- .github/workflows/build.yaml | 9 +++++++++ justfile | 5 +++++ projects/chisel-practice/default.nix | 5 +++-- projects/default.nix | 1 + 4 files changed, 18 insertions(+), 2 deletions(-) create mode 100644 .github/workflows/build.yaml diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml new file mode 100644 index 0000000..9454427 --- /dev/null +++ b/.github/workflows/build.yaml @@ -0,0 +1,9 @@ +on: + - push +jobs: + build-all: + runs-on: ubuntu-22.04 + steps: + - uses: actions/checkout@v4 + - uses: cachix/install-nix-action@v24 + - run: nix run nixpkgs#just build-all diff --git a/justfile b/justfile index 4306276..79357d6 100644 --- a/justfile +++ b/justfile @@ -25,5 +25,10 @@ update-inputs: echo $(cd $(dirname $i) && nix flake update) done +build-all: + nix build .#blinky -L --show-trace + nix build .#chisel-blinky -L --show-trace + nix build .#chisel-practice -L --show-trace + addlicense: @find . -type f \( -name "*.cpp" -o -name "*.hpp" -o -name "*.cc" -o -name "*.h" \) -exec addlicense -f LICENSE -l mit {} \; diff --git a/projects/chisel-practice/default.nix b/projects/chisel-practice/default.nix index 95f950b..d126ebe 100644 --- a/projects/chisel-practice/default.nix +++ b/projects/chisel-practice/default.nix @@ -36,9 +36,10 @@ mkSbtDerivation { runHook postBuild ''; - depsSha256 = "sha256-jeLxdCXKVIrWjLtXGyu80halnMckL92AR9BumR2Lsew="; + depsSha256 = "sha256-g1aqoVPugEIxSrmw7S0+MM6TnD4O0IzdFZiRpmQCHQI="; installPhase = '' - install -Dm 444 -T blinky.fs $out/share/blinky.fs + mkdir -p $out/share + install -Dm 444 *.fs -t $out/share ''; } diff --git a/projects/default.nix b/projects/default.nix index 694787b..1b0077b 100644 --- a/projects/default.nix +++ b/projects/default.nix @@ -4,5 +4,6 @@ blinky = pkgs.callPackage ./blinky { }; blinkygen-chisel = pkgs.callPackage ./chisel-blinky { }; chisel-blinky = pkgs.callPackage ./chisel-blinky { }; + chisel-practice = pkgs.callPackage ./chisel-practice { }; }; }