GithubHelp home page GithubHelp logo

Nixpkgs module about flake-parts HOT 4 OPEN

hercules-ci avatar hercules-ci commented on June 2, 2024 1
Nixpkgs module

from flake-parts.

Comments (4)

roberth avatar roberth commented on June 2, 2024 3

Good idea. The root nixpkgs.* options could be permanent aliases for nixpkgsSets.pkgs or something.

from flake-parts.

Atry avatar Atry commented on June 2, 2024 1

I would just use https://github.com/NixOS/nixpkgs/blob/3b4e70e987a42792196294560a233d285b1c1d10/nixos/modules/misc/nixpkgs.nix

    ml-ops.inputs.flake-parts.lib.mkFlake { inherit inputs; } {
      perSystem = { pkgs, system, ... }:
        {
          imports = [
            "${inputs.nixpkgs}/nixos/modules/misc/nixpkgs.nix"
          ];
          nixpkgs = {
            hostPlatform = system;
            
            
            # other options, e.g. 
            # config.allowUnfree = true;
          };
       };
    }

from flake-parts.

srid avatar srid commented on June 2, 2024

Could we have more than one pkgs as a result? For, eg., native pkgs and a rosetta pkgs (on aarch64-darwin).

from flake-parts.

roberth avatar roberth commented on June 2, 2024

For Rosetta, you can already get a pkgs via getSystem and/or withSystem. Those will also give you access to your own packages for that system.
The feature still makes a lot of sense for having different versions of Nixpkgs, but for mixed-system and cross, it'd be better to use and improve the perSystem infrastructure.

from flake-parts.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.