diff --git a/.github/workflows/update.yml b/.github/workflows/update.yml new file mode 100644 index 0000000..19b5340 --- /dev/null +++ b/.github/workflows/update.yml @@ -0,0 +1,20 @@ +name: update-flake-lock +on: + workflow_dispatch: + schedule: + - cron: '0 0 * * 0' + +jobs: + lockfile: + runs-on: ubuntu-22.04 + steps: + - name: Checkout + uses: actions/checkout@v3 + - name: Install Nix + uses: DeterminateSystems/nix-installer-action@main + - name: Enable magic Nix cache + uses: DeterminateSystems/magic-nix-cache-action@main + - name: Check flake + uses: DeterminateSystems/flake-checker-action@main + - name: Update flake.lock + uses: DeterminateSystems/update-flake-lock@main diff --git a/flake.lock b/flake.lock index ef0df67..8cfb651 100644 --- a/flake.lock +++ b/flake.lock @@ -98,11 +98,11 @@ }, "nixlib_2": { "locked": { - "lastModified": 1698540503, - "narHash": "sha256-YN6DJQc7SMe6ep9FhD2BGl92bo24NPNRWjADEJE4xeU=", + "lastModified": 1703983607, + "narHash": "sha256-YECXW8P0bqFM5e65Mu2fL4wZlonNWCuNEk7UQPsuJZ0=", "owner": "nix-community", "repo": "nixpkgs.lib", - "rev": "ce2acb20a405bf6f910081c2adc988bbc8100e4c", + "rev": "a6c99b57d2e58f7fc6d52a08b0ba40160e75f738", "type": "github" }, "original": { diff --git a/src/haumea/nixosModules.nix b/src/haumea/nixosModules.nix index f0ecf47..d6cc441 100644 --- a/src/haumea/nixosModules.nix +++ b/src/haumea/nixosModules.nix @@ -25,20 +25,8 @@ let f ]; - callModuleLazily = - inputs: path: - let - importer = l.scopedImport inputs; - f = toFunction (importer path); - in - lazyArgsPerParameter f inputs; - - callModuleLazily' = - inputs: path: importer: - let - f = toFunction (importer path); - in - lazyArgsPerParameter f inputs; + callModuleLazily = haumea.lib.loaders.scoped; + callModuleLazily' = haumea.lib.loaders.default; removeFileSuffix = l.removeSuffix ".nix"; removeDefault = l.removeSuffix "/default"; @@ -134,7 +122,7 @@ let if (l.isFunction v) then lazyArgsPerParameter v (moduleArgs // extraArgs) else if (l.isPath v) then - callModuleLazily' (moduleArgs // extraArgs) v import + callModuleLazily' (moduleArgs // extraArgs) v else v ;