Skip to content

Comments

Dev shell improvements #11803

Merged
Ericson2314 merged 4 commits intoNixOS:masterfrom
obsidiansystems:factor-out-dev-shell
Nov 6, 2024
Merged

Dev shell improvements #11803
Ericson2314 merged 4 commits intoNixOS:masterfrom
obsidiansystems:factor-out-dev-shell

Conversation

@Ericson2314
Copy link
Member

Motivation

These are good in general, but in particular (except for the code motion) are needed before we drop the old make build system.

Context

#2503

Priorities and Process

Add 👍 to pull requests you find important.

The Nix maintainer team uses a GitHub project board to schedule and track reviews.

It had gotten rather big. Hopefully we'll eventually have some generic
infra for a "multi-package dev shell" and not need so much code for
this, but until then it's better in a separate file.
We have per-stdenv package sets, so we should be using them.
When we get rid of the make build system, we would be missing things.
Incuding these packages' deps ensure we don't miss things.
@Ericson2314 Ericson2314 requested a review from edolstra as a code owner November 4, 2024 20:49
@roberth roberth changed the title Dev shell improvments Dev shell improvements Nov 5, 2024
;
});
in
makeShell = import ./packaging/dev-shell.nix { inherit lib devFlake; };
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

callPackage might be nice, but also a bigger change.

(pkgs.nix.override { forDevShell = true; }).overrideAttrs (attrs:

let
stdenv = pkgs.nixDependencies.stdenv;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If the shell were part of nixComponents, this would just be a stdenv parameter and it all works out.

`lib.concatMapAttrs` instead of `lib.mapAttrs'` and `lib.nameValuePair`

Co-authored-by: Robert Hensing <[email protected]>
@Ericson2314 Ericson2314 enabled auto-merge November 6, 2024 04:22
@Ericson2314
Copy link
Member Author

Applied the one suggestion, happy to keep reworking things re the others. Just wanted to do enough to unblock the full Meson switchover PR.

@Ericson2314 Ericson2314 merged commit bf19e5c into NixOS:master Nov 6, 2024
@Ericson2314 Ericson2314 deleted the factor-out-dev-shell branch August 14, 2025 00:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants