about summary refs log tree commit diff
path: root/lib
Commit message (Collapse)AuthorAge
* lib/licenses: add missing spdxidsjopejoe12023-12-26
|
* Merge pull request #272083 from tweag/lib-contribSilvan Mosberger2023-12-19
|\ | | | | lib: Add contribution guidelines
| * lib: Add contribution guidelinesSilvan Mosberger2023-12-05
| | | | | | | | Co-Authored-By: Robert Hensing <robert@roberthensing.nl>
* | Merge pull request #273893 from tweag/fileset.gitTracked-storeDirSilvan Mosberger2023-12-19
|\ \ | | | | | | `lib.fileset.gitTracked`: Support out-of-tree builds
| * | Remove --simulate-pure-evalSilvan Mosberger2023-12-19
| | |
| * | lib.fileset.gitTracked: Support out-of-tree buildsSilvan Mosberger2023-12-19
| | |
| * | lib.fileset.fetchGit: RefactoringSilvan Mosberger2023-12-19
| | |
* | | Merge pull request #270537 from 9999years/packagesFromDirectorySilvan Mosberger2023-12-19
|\ \ \ | | | | | | | | lib.packagesFromDirectoryRecursive: init
| * | | lib.packagesFromDirectoryRecursive: initRebecca Turner2023-12-19
| | |/ | |/| | | | | | | Co-authored-by: Gabriella Gonzalez <GenuineGabriella@gmail.com>
* | | lib: `modules.sh` should check JSON output for predictabilityRebecca Turner2023-12-19
| | | | | | | | | | | | | | | | | | | | | | | | | | | Currently, the `lib/tests/modules.sh` test checks the output of `nix-instantiate --eval` without `--json`, which outputs an unspecified human-readable format. This patch modifies `modules.sh` to use the `--json` output instead, to be robust against future changes to `nix-instantiate` output.
* | | lib.generators: made toLua accept derivations tooMatthieu Coudron2023-12-15
| | | | | | | | | | | | While trying to extend generateLuarocksConfig, I had infinite loops caused by toLua considering derivations as attrSets
* | | lib/tests/release.nix: temporary reference to pkgs/test/releaseAdam Joseph2023-12-15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This commit temporarily adds pkgs/test/release to the lib/tests/release.nix test suite, because ofborg already knows about that entry point. We should move the list of test entry points out of ofborg and into a central place in nixpkgs: https://github.com/NixOS/nixpkgs/issues/272591 Once we do that we won't need to have this ugly kludge in an inappropriate place.
* | | treewide: add __attrsFailEvaluation and __recurseIntoDerivationForReleaseJobsAdam Joseph2023-12-15
| | |
* | | Merge pull request #269551 from tejing1/nixos-stub-ldRobert Hensing2023-12-13
|\ \ \ | | | | | | | | nixos/stub-ld: init module
| * | | lib.systems.elaborate: add libDir attributeJeff Huffman2023-12-03
| |/ /
* | | Merge pull request #273704 from adisbladis/lib-getexe-efficiencySilvan Mosberger2023-12-13
|\ \ \ | | | | | | | | lib.getExe: Make more efficient
| * | | lib.getExe: Make more efficientadisbladis2023-12-12
| | | |
* | | | Merge pull request #274022 from hercules-ci/doc-attrsets-operatorsSilvan Mosberger2023-12-13
|\ \ \ \ | |_|_|/ |/| | | lib/attrsets: Document and link Nix language operators
| * | | lib/attrsets: Document and link Nix language operatorsRobert Hensing2023-12-13
| | | |
* | | | lib.path.hasStorePathPrefix: initSilvan Mosberger2023-12-13
| | | | | | | | | | | | | | | | Co-authored-by: Robert Hensing <roberth@users.noreply.github.com>
* | | | Merge pull request #273664 from tweag/fileset.gitTracked-improvementsSilvan Mosberger2023-12-13
|\ \ \ \ | |_|/ / |/| | | `lib.fileset.gitTracked,gitTrackedWith`: Minor improvements
| * | | lib.fileset.gitTracked: Improve error when passing filesSilvan Mosberger2023-12-11
| | | |
| * | | lib.fileset: Refactor gitTracked and gitTrackedWithSilvan Mosberger2023-12-11
| | |/ | |/| | | | | | | | | | Introduce an internal function for them to share more behavior. This makes future changes easier.
* | | Merge pull request #273473 from adisbladis/lib-isConvertibleToString-static-listSilvan Mosberger2023-12-11
|\ \ \ | | | | | | | | lib.isConvertibleToString: Statically compute types list
| * | | lib.isConvertibleToString: Statically compute types listadisbladis2023-12-11
| | | |
* | | | Merge pull request #273470 from adisbladis/lib-tohexstring-static-valuesSilvan Mosberger2023-12-11
|\ \ \ \ | | | | | | | | | | lib.toHexString: Statically compute hexDigits attrset
| * | | | lib.toHexString: Statically compute hexDigits attrsetadisbladis2023-12-11
| |/ / /
* | | | Merge pull request #273474 from adisbladis/lib-cmakeOptionType-static-listSilvan Mosberger2023-12-11
|\ \ \ \ | | | | | | | | | | lib.cmakeOptionType: Statically compute types list
| * | | | lib.cmakeOptionType: Statically compute types listadisbladis2023-12-11
| |/ / /
* | | | Merge pull request #273467 from adisbladis/lib-pipe-no-letSilvan Mosberger2023-12-11
|\ \ \ \ | | | | | | | | | | lib.pipe: Avoid creating a scope
| * | | | lib.pipe: Avoid creating scopesadisbladis2023-12-11
| |/ / /
* | | | Merge pull request #273004 from hercules-ci/attrset-path-longest-prefixRobert Hensing2023-12-11
|\ \ \ \ | | |_|/ | |/| | lib.attrsets.longestValidPathPrefix: init
| * | | lib.attrsets.hasAttrByPath: Document law and laziness, and test itRobert Hensing2023-12-08
| | | |
| * | | lib.attrsets.longestValidPathPrefix: initRobert Hensing2023-12-08
| | | | | | | | | | | | | | | | | | | | Allows finding the most specific path that exists. This is useful for error messages relating to attribute paths.
* | | | Merge pull request #257100 from Ma27/version-info-libRobert Hensing2023-12-11
|\ \ \ \ | |_|/ / |/| | | flake: fix `lib.trivial.version` when used from a flake
| * | | flake/version overlay: review fixesMaximilian Bosch2023-12-10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Improves the comments of `lib/flake-version-info.nix` and drops the `__`-prefix from the filename. * `lib'` -> `lib0` in `nixpkgs/lib`. * Drop the declaration of `trivial.version` in the overlay because this declaration already uses the final expressions of `versionSuffix` and `release` now. * No need to fall back to `self.lastModified` anymore, this was a workaround for pre2.4 Nix. Co-authored-by: Robert Hensing <robert@roberthensing.nl> Co-authored-by: Silvan Mosberger <contact@infinisil.com>
| * | | lib/trivial: drop `rec` in favor of `lib` fixpointMaximilian Bosch2023-12-10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | That way each expression uses the final version of other lib.trivial declarations. For instance, when replacing `versionSuffix` with the string `"fnord"` in a lib overlay, `trivial.version` uses `"fnord"` as suffix now rather than `pre-git`.
| * | | flake: also provide proper version info for lib's flakeMaximilian Bosch2023-12-09
| |/ / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This effectively means that nixpkgs$ nix eval ./lib#lib.trivial.version "23.11.20231020.ee0d6b5" now gives meaningful results as well. See https://github.com/NixOS/nixpkgs/pull/257100#discussion_r1352075369 for the discussion around this.
* | | lib.strings: Dont create scopes for getName/getVersionadisbladis2023-12-11
| | | | | | | | | | | | We can create the `parse` function in a scope one level up to avoid recomputing it every time.
* | | Merge pull request #272709 from hercules-ci/module-system-test-pr-131205Maximilian Bosch2023-12-10
|\ \ \ | | | | | | | | lib/modules: Test optionless module errors from #131205
| * | | lib/modules: Clarify test assertionsRobert Hensing2023-12-09
| | | |
| * | | lib/modules: Test optionless module errors from #131205Robert Hensing2023-12-09
| | |/ | |/|
* | | Merge pull request #272183 from infinisil/nixpkgs-referenceRobert Hensing2023-12-10
|\ \ \ | | | | | | | | doc: Rename to Nixpkgs reference manual and restate purpose
| * | | doc: Rename to Nixpkgs reference manual and state purposeSilvan Mosberger2023-12-08
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | For the time being, we're moving towards https://nix.dev/ containing all tutorials and guides. The Nixpkgs manual is reinforced to be a _reference_ manual. While it's not just reference for now, that's what the docs team is working towards. This commits rewrites the Nixpkgs manual introduction to reflect that and point to some more useful links. The contribution docs are updated similarly so it's not missed. Co-authored-by: Valentin Gagarin <valentin.gagarin@tweag.io> Co-authored-by: Robert Hensing <roberth@users.noreply.github.com>
* | | | Merge pull request #272764 from tweag/anyBoolRobert Hensing2023-12-10
|\ \ \ \ | |_|_|/ |/| | | lib.types.anyBool: init
| * | | lib.types.boolByOr: initSilvan Mosberger2023-12-08
| | |/ | |/| | | | | | | | | | | | | | | | This type is necessary to have correct merging behavior for `allowUnfreePredicate` and `allowInsecurePredicate` Co-authored-by: Robert Hensing <roberth@users.noreply.github.com>
* | | lib.sort: Make doc consistent with sortOnRobert Hensing2023-12-08
| | |
* | | lib.callPackageWith: Optimize levenshtein sortRobert Hensing2023-12-08
| | | | | | | | | | | | | | | Probably not significant because of the limits already applied. This is mostly cleanup.
* | | lib.sortOn: initRobert Hensing2023-12-08
|/ / | | | | | | | | | | | | | | | | | | | | A more efficient sort in some cases, and often convenient. This exposes `lib.lists.sortOn` immediately on `lib`, because it is a sibling of `sort`, which is already present there. Omitting it would lead to more confusion, and worse outcomes. There's no confusion about the types `sort` or `sortOn` operate on. Haskell agrees about the type for `sortOn`, and it is in its `base`.
* | lib/customisation: fix eval error (attribute "levenshtein" missing)Someone Serge2023-12-03
| |