Repository navigation
feat: Add .result for path-configured trees. - #5
Merged
Merged
Conversation
Contributor
There was a problem hiding this comment.
Pull Request Overview
This PR introduces a .result attribute to trees configured via paths, updates tests to use this new property, and refreshes documentation to show its usage.
- Add
resultfield todefault.nixfor returning the final leaf list without extra paths - Update
checkmate.nixtests to replaceleafs []with.leafs.resultand add an identity test - Revise
README.mdto document pre-configured subtree sharing and show.resultin examples
Reviewed Changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| default.nix | Added result = (self f) [ ]; and a brief comment |
| checkmate.nix | Swapped .leafs [] calls for .leafs.result, new test |
| README.md | Updated pattern links, renamed section, added .result example |
Comments suppressed due to low confidence (2)
default.nix:86
- [nitpick] The comment is a bit unclear. Consider clarifying what ‘empty’ refers to, e.g., “Returns the configured tree’s leaf list with no additional paths.”
# Applies empty (for already path-configured trees)
README.md:286
- [nitpick] Consider adding a short remark before this example explaining that
.resultextracts the final filtered leaf list from the configured tree, for clarity to new users.
(lib.pipe root [(on "vim") (off "emacs") (i: i.result)])
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.