flake.nix.md

flake.nix

FlakeFlake inputs and outputs are understood here, with flake-aware hovers and completion.
{
  description = "A very cool Nix flake";

  inputs = {
    nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
  };

  outputs = { self, nixpkgs, ... }:
    let
      pkgs = nixpkgs.legacyPackages."x86_64-linux";
    in {
      devShells.x86_64-linux.default = pkgs.mkShell {
        packages = with pkgs; [
          git
          nodejs
        ];

        shellHook = ''
          echo "Nix shell ready"
        '';
      };
    };
}

Activate the shell

$ nix develop

Share your thoughts