diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml deleted file mode 100644 index 4f3169c..0000000 --- a/.github/workflows/ci.yml +++ /dev/null @@ -1,52 +0,0 @@ -name: Flake Check CI -on: - workflow_dispatch: - push: - branches: [main] - paths-ignore: - - ".github/**" - - "*.md" - - justfile - pull_request: - branches: [main] - paths-ignore: - - ".github/**" - - "*.md" - - justfile -jobs: - check-eval: - name: Eval / Get Checks - runs-on: ubuntu-latest - outputs: - matrix: ${{ steps.checks-matrix.outputs.matrix }} - steps: - - name: Checkout - uses: actions/checkout@v4 - with: - fetch-depth: 0 - ref: ${{ github.head_ref }} - - name: Setup Nix - uses: DeterminateSystems/nix-installer-action@v16 - - name: Show Flake - run: nix flake show - - name: Output Checks Matrix - id: checks-matrix - run: | - echo "matrix=$(nix eval --json .#checks.x86_64-linux --apply "c: {check = (builtins.attrNames c);}")" >> $GITHUB_OUTPUT - run-checks: - name: Run Check - needs: check-eval - runs-on: ubuntu-latest - strategy: - matrix: ${{fromJSON(needs.check-eval.outputs.matrix)}} - steps: - - name: Checkout - uses: actions/checkout@v4 - with: - fetch-depth: 0 - ref: ${{ github.head_ref }} - - name: Setup Nix - uses: DeterminateSystems/nix-installer-action@v16 - - name: Run Check ${{matrix.check}} - run: nix build .#checks.x86_64-linux.${{matrix.check}} - diff --git a/flake.nix b/flake.nix index 7cc8b67..784367a 100644 --- a/flake.nix +++ b/flake.nix @@ -15,10 +15,10 @@ }; flakelight.builtinFormatters = false; - formatters = { - "*.nix" = "alejandra ."; - "*.{js,ts,jsx,tsx,md,json}" = "prettier --write . --config frontend/.prettierrc.yaml"; - "*.rs" = "cd backend; cargo fmt"; + formatters = pkgs: { + "*.nix" = "${pkgs.alejandra}/bin/alejandra ."; + "*.{js,ts,jsx,tsx,md,json}" = "${pkgs.prettier}/bin/prettier --write . --config frontend/.prettierrc.yaml"; + "*.rs" = "${pkgs.rustfmt}"; }; devShell = pkgs: let