Add flake

This commit is contained in:
Jez Cope 2021-06-29 21:17:17 +01:00
parent b57bb82073
commit 613714c3aa
3 changed files with 59 additions and 6 deletions

42
flake.lock Normal file
View File

@ -0,0 +1,42 @@
{
"nodes": {
"flake-utils": {
"locked": {
"lastModified": 1623875721,
"narHash": "sha256-A8BU7bjS5GirpAUv4QA+QnJ4CceLHkcXdRp4xITDB0s=",
"owner": "numtide",
"repo": "flake-utils",
"rev": "f7e004a55b120c02ecb6219596820fcd32ca8772",
"type": "github"
},
"original": {
"owner": "numtide",
"repo": "flake-utils",
"type": "github"
}
},
"nixpkgs": {
"locked": {
"lastModified": 1624992828,
"narHash": "sha256-whhfrjqOa1BUQAQu4J0QSRUG+iZbTeJpnsl52kLPBfc=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "520da1d00f26d2f4d31eb3cd3c5dc8b3a1e998c6",
"type": "github"
},
"original": {
"owner": "NixOS",
"repo": "nixpkgs",
"type": "github"
}
},
"root": {
"inputs": {
"flake-utils": "flake-utils",
"nixpkgs": "nixpkgs"
}
}
},
"root": "root",
"version": 7
}

15
flake.nix Normal file
View File

@ -0,0 +1,15 @@
{
description = "A very basic flake";
inputs.nixpkgs.url = "github:NixOS/nixpkgs";
inputs.flake-utils.url = "github:numtide/flake-utils";
outputs = { self, nixpkgs, flake-utils }:
flake-utils.lib.eachDefaultSystem
(system:
let pkgs = nixpkgs.legacyPackages.${system}; in
{
devShell = import ./shell.nix { inherit pkgs; };
}
);
}

View File

@ -1,8 +1,4 @@
{ pkgs ? import (builtins.fetchTarball {
name = "nixos-unstable-erambler";
url = "https://github.com/nixos/nixpkgs/archive/f9d90fdbbfea5ac0349cd7d5a7025a2434dace1c.tar.gz";
sha256 = "14lsfish1sxfbz7sqw8nzvc915j7g3asliqa45hjnpyg35cfslwf";
}) { } }:
{ pkgs, ... }:
let
python = pkgs.python38;
@ -31,5 +27,5 @@ let
my_yaspin
]);
in pkgs.mkShell {
buildInputs = with pkgs; [ pythonWithPackages yarn ];
buildInputs = with pkgs; [ pythonWithPackages yarn hugo ];
}