Commit graph

377 commits

Author SHA1 Message Date
John Soo efca7105c7 Silence more harmless warnings. 2022-04-27 04:08:01 +12:00
adisbladis 83773704be Add Python Black formatter 2022-04-26 21:40:31 +12:00
adisbladis 2a26070ea4 Add TOML formatter (prettier) 2022-04-26 21:40:31 +12:00
adisbladis fec10f2cfc src/nix-eval-jobs.cc: Reformat with clang-format 2022-04-26 21:20:24 +12:00
adisbladis 8b8f456765 Add clang-format 2022-04-26 21:20:24 +12:00
adisbladis 76f68a8605 Fix using erroneous Nix derivation in mkVariant based tests 2022-04-26 21:20:24 +12:00
adisbladis 05218ff30d Fix nix flake check warnings about deprecated attr names 2022-04-26 21:20:24 +12:00
adisbladis 516fdc8f6c Add treefmt
And use it in place of editorconfig/nixpkgs-fmt checks
2022-04-26 21:20:24 +12:00
adisbladis 9482b5ab3e
Merge pull request #64 from nix-community/dotted-attrs
Replace internal attr string representation with an array
2022-04-26 15:32:09 +07:00
adisbladis 61c9f4cfcc Replace internal attr string representation with an array
This ensures correct handling of attrnames with a dot in them and will
not throw errors about illegal attrnames.

Additionally this escapes any attributes containing dots in the JSON
output and adds another field called `attrPath` which contains the
attribute path as a list.

Example output:
```
{
  "attr": "hello",
  "attrPath": [
    "hello"
  ],
  "drvPath": "/nix/store/n204jib73z55cp9s0rmw1c5v5q528j7v-hello-2.12.drv",
  "name": "hello-2.12",
  "outputs": {
    "out": "/nix/store/h59dfk7dwrn7d2csykh9z9xm2miqmrnz-hello-2.12"
  },
  "system": "x86_64-linux"
}
```
2022-04-26 19:43:56 +12:00
adisbladis 2e58354a7e
Merge pull request #63 from nix-community/dependabot/github_actions/DeterminateSystems/update-flake-lock-9
Bump DeterminateSystems/update-flake-lock from 8 to 9
2022-04-26 10:33:38 +07:00
dependabot[bot] 859db1330b
Bump DeterminateSystems/update-flake-lock from 8 to 9
Bumps [DeterminateSystems/update-flake-lock](https://github.com/DeterminateSystems/update-flake-lock) from 8 to 9.
- [Release notes](https://github.com/DeterminateSystems/update-flake-lock/releases)
- [Commits](https://github.com/DeterminateSystems/update-flake-lock/compare/v8...v9)

---
updated-dependencies:
- dependency-name: DeterminateSystems/update-flake-lock
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-04-25 23:11:18 +00:00
adisbladis 5c9750eadd
Merge pull request #62 from nix-community/recurse-for-derivations
Add support for recurseForDerivations
2022-04-25 17:20:18 +07:00
adisbladis c1bbb11c5d Add support for recurseForDerivations
This will respect `recurseForDerivations` when iterating over attrsets.

Example expression:
``` nix
{ system ? builtins.currentSystem }:
{
  recurseForDerivations = true;

  # This should build as it's in the top-level attrset
  drvA = derivation {
    inherit system;
    name = "drvA";
    builder = ":";
  };

  dontRecurse = {
    # This shouldn't build as `recurseForDerivations = true;` is not set
    # recurseForDerivations = true;

    # This should not build
    drvB = derivation {
      inherit system;
      name = "drvA";
      builder = ":";
    };
  };

  recurse = {
    # This should build
    recurseForDerivations = true;

    # This should not build
    drvC = derivation {
      inherit system;
      name = "drvC";
      builder = ":";
    };
  };

}
```
2022-04-25 22:11:53 +12:00
adisbladis e303b2e43f
Merge pull request #61 from nix-community/nix-2_8_0-fix
Fix build with stable Nix
2022-04-24 09:16:19 +07:00
adisbladis 1ea8948eb7 Fix build with stable Nix 2022-04-24 14:08:34 +12:00
adisbladis 2e3405f2d1
Merge pull request #59 from nix-community/test-nested-jobs
Add test for a job with a nested attrset
2022-04-22 16:00:56 +07:00
adisbladis 813c5d7aae Add test for a job with a nested attrset 2022-04-22 20:36:52 +12:00
adisbladis 7a9f13831c
Merge pull request #56 from jsoo1/refactor-drv-parsing
Refactor derivation representation.
2022-04-22 14:52:03 +07:00
John Soo f98da2e00b
Cleanup worker json handling. 2022-04-22 00:36:54 -07:00
John Soo 7aa9835adb
Cleanup gcroots creation. 2022-04-22 00:36:13 -07:00
John Soo 8dd6426d15
Make Drv struct.
To facilitate collecting and jsonifying derivations in different
contexts
2022-04-22 00:35:30 -07:00
adisbladis 192fa87968
Merge pull request #58 from nix-community/disable-classic-checks
Disable nix-shell based checks
2022-04-22 14:34:04 +07:00
adisbladis 5f9d57e9b1
Merge pull request #55 from jsoo1/kill-zombies
Kill zombies.
2022-04-22 14:33:16 +07:00
adisbladis 8bb83e4c69 Disable nix-shell based checks
We are essentially testing the same thing in the Flake check, the
difference is in the nix-shell vs `nix develop` invocation.

I will admit (even though this is my making) that it's a bit silly to
essentially test the same thing twice.
2022-04-22 19:18:57 +12:00
adisbladis f72f05d81f
Merge pull request #51 from nix-community/ci
flake: switch back to original nixpkgs
2022-04-22 14:17:55 +07:00
John Soo b9a87464a0
Move collecting handler to separate function.
s/master/collector/g
2022-04-22 00:15:28 -07:00
John Soo a27faabd0a
Use Proc struct to manage forked processes.
Cleans up zombie processes.
2022-04-22 00:15:28 -07:00
John Soo 9d4c256fa0
Make a Proc struct for running processes. 2022-04-22 00:15:27 -07:00
adisbladis 353724df90 Fix querying output paths
The upstream function signature changed, we no longer have to pass onlyOutputsToInstall.
2022-04-22 19:07:40 +12:00
Jörg Thalheim c1b86245a1 fix for nixUnstable 2022-04-22 18:53:12 +12:00
Jörg Thalheim 3094e12732 flake: switch back to original nixpkgs 2022-04-22 18:53:12 +12:00
adisbladis 01dd2d0133
Merge pull request #54 from jsoo1/add-debug-symbols-to-shell
Add debug symbols to nix-shell.
2022-04-22 13:52:08 +07:00
adisbladis a07a22f94c
Merge pull request #53 from jsoo1/silence-irrelevant-warnings
Ignore -Wnon-virtual-dtor for static struct.
2022-04-22 13:51:36 +07:00
adisbladis 6ef1b314d7 Only add debug symbols to shell on Linux 2022-04-22 18:42:40 +12:00
John Soo 0aa88f2f49 Add debug symbols to nix-shell. 2022-04-22 18:42:40 +12:00
adisbladis 55d91140be
Merge pull request #57 from jsoo1/refactor-top-level-value-finding
Refactor top-level value finding.
2022-04-22 13:29:26 +07:00
adisbladis 2a491dd7fd
Merge pull request #52 from jsoo1/gc-dont-gc
Set GC_DONT_GC=1.
2022-04-22 13:18:11 +07:00
John Soo 0e0c6c44d0
Ignore -Wnon-virtual-dtor for static struct. 2022-04-21 15:44:01 -07:00
John Soo dd8a2e89a0
Simplify top-level value fetching. 2022-04-21 11:44:02 -07:00
John Soo e05e625411
Make function to get top-level value from a flake. 2022-04-21 11:40:00 -07:00
John Soo 4a3d2e0008
Make function to get top-level value from releaseExpr. 2022-04-21 11:34:49 -07:00
John Soo b062ac705d
Set GC_DONT_GC=1.
To avoid `Collecting from unknown thread'.
2022-04-21 09:31:53 -07:00
Jörg Thalheim 2871c7a3f4
Merge pull request #48 from nix-community/dependabot/github_actions/cachix/install-nix-action-17
Bump cachix/install-nix-action from 16 to 17
2022-04-12 10:39:26 +01:00
dependabot[bot] ed136e1396
Bump cachix/install-nix-action from 16 to 17
Bumps [cachix/install-nix-action](https://github.com/cachix/install-nix-action) from 16 to 17.
- [Release notes](https://github.com/cachix/install-nix-action/releases)
- [Commits](https://github.com/cachix/install-nix-action/compare/v16...v17)

---
updated-dependencies:
- dependency-name: cachix/install-nix-action
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-04-11 23:22:37 +00:00
Jörg Thalheim 4bab9e449d
Merge pull request #44 from nix-community/dependabot/github_actions/actions/checkout-3
Bump actions/checkout from 2.4.0 to 3
2022-03-13 17:12:30 +00:00
Jörg Thalheim eddea80690
Merge pull request #45 from nix-community/build-fix
fix build with nix 2.7
2022-03-13 17:12:11 +00:00
Jörg Thalheim d592323c6b fix build with nix 2.7 2022-03-13 17:47:15 +01:00
dependabot[bot] 4a08b3d7aa
Bump actions/checkout from 2.4.0 to 3
Bumps [actions/checkout](https://github.com/actions/checkout) from 2.4.0 to 3.
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](https://github.com/actions/checkout/compare/v2.4.0...v3)

---
updated-dependencies:
- dependency-name: actions/checkout
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-03-07 23:12:51 +00:00
mergify[bot] 9c2d7a8279
Merge pull request #39 from nix-community/update_flake_lock_action
flake.lock: Update
2022-02-24 01:09:43 +00:00