Support relative path by github:MattSturgeon #83

Open
bryango wants to merge 1 commit from bryango/flake-compat:feature into main
Contributor

This is a sync from github:NixOS/flake-compat which implements relative path inputs such as path:./subdir. The corresponding upstream PR is:

This is a squashed commit of the following:

I believe Lix itself currently does not support relative path inputs? So this could be a very useful shim for users that would like to use Lix with flakes with relative path inputs.

This is a sync from github:NixOS/flake-compat which implements relative path inputs such as path:./subdir. The corresponding upstream PR is: - https://github.com/NixOS/flake-compat/pull/71 This is a squashed commit of the following: - https://git.lix.systems/bryango/flake-compat/compare/8b8c7c6bab4fc1d1b0d3eebe0f0f019a25dfdb2c...f387cd2afec9419c8ee37694406ca490c3f34ee5 I believe Lix itself currently does not support relative path inputs? So this could be a very useful shim for users that would like to use Lix with flakes with relative path inputs.
This is a sync from github:NixOS/flake-compat which implements relative
path inputs such as path:./subdir.

Squashed commit of the following:

commit f387cd2afec9419c8ee37694406ca490c3f34ee5
Merge: 9100a0f 77a761e
Author: Eelco Dolstra <edolstra@gmail.com>
Date:   Mon Oct 27 19:09:55 2025 +0100

    Merge pull request #71 from MattSturgeon/relative-path

    Support relative path inputs

commit 77a761e1abaad48179ec9f0124c593e9defbb0e5
Author: Matt Sturgeon <matt@sturgeon.me.uk>
Date:   Mon May 12 12:16:40 2025 +0100

    Use correct parent `outPath` for relative path inputs

    Ensure relative path inputs are relative to the parent node's _actual_
    `outPath`, instead of the subtly different `sourceInfo.outPath`.

    Additionally, non-flake inputs now also have a `sourceInfo` attribute.

    This fixes the relationship between `self.outPath` and
    `self.sourceInfo.outPath` in some edge cases.

    (cherry picked from commit 46beb9af76)
    (cherry picked from PR https://github.com/NixOS/nix/pull/13170)

commit 17b46650be8915f4f526ac0f3bbb03e311568451
Author: Robert Hensing <robert@roberthensing.nl>
Date:   Tue Apr 15 09:28:23 2025 +0200

    fix: Evaluate flake parent source without evaluating its outputs

    This requires that we refer to the `sourceInfo` instead of the
    `result`. However, `sourceInfo` does not create a chain of basedir
    resolution, so we add that back with `flakeDir`.

    (cherry picked from commit 2109a5a206)
    (cherry picked from PR https://github.com/NixOS/nix/pull/13026)

commit 98fed477b0a501881c4f4cd798ba89eaef53b211
Author: Robert Hensing <robert@roberthensing.nl>
Date:   Tue Apr 15 09:10:18 2025 +0200

    call-flake.nix: allNodes.${key} -> allNodes.${key}.result

    (cherry picked from commit 9de9410f29)
    (cherry picked from PR https://github.com/NixOS/nix/pull/13026)

commit a7bab49e4f8a7323e1e289ae7a7e0fe73a8d3c5d
Author: Robert Hensing <robert@roberthensing.nl>
Date:   Mon Apr 14 14:09:30 2025 +0200

    call-flake.nix: refactor: Bring mapAttrs into scope

    (cherry picked from commit 674375b021)
    (cherry picked from PR https://github.com/NixOS/nix/pull/13026)

commit 1b568a049aa5f4bf98351228c6a2fba9ab4f7f2c
Author: Eelco Dolstra <edolstra@gmail.com>
Date:   Thu Jan 16 14:21:27 2025 +0100

    Add support for relative path inputs

    (cherry picked from PR https://github.com/NixOS/nix/pull/10089)
This pull request can be merged automatically.
You are not authorized to merge this pull request.
View command line instructions

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u feature:bryango-feature
git switch bryango-feature

Merge

Merge the changes and update on Forgejo.

Warning: The "Autodetect manual merge" setting is not enabled for this repository, you will have to mark this pull request as manually merged afterwards.

git switch main
git merge --no-ff bryango-feature
git switch bryango-feature
git rebase main
git switch main
git merge --ff-only bryango-feature
git switch bryango-feature
git rebase main
git switch main
git merge --no-ff bryango-feature
git switch main
git merge --squash bryango-feature
git switch main
git merge --ff-only bryango-feature
git switch main
git merge bryango-feature
git push origin main
Sign in to join this conversation.
No description provided.