Create flake.nix devShell, Start working on the default package too
This commit is contained in:
parent
e21daaf521
commit
277bafb535
42
flake.nix
42
flake.nix
|
@ -1,5 +1,5 @@
|
|||
{
|
||||
description = "Sketches in Quil";
|
||||
description = "Reproducible Environment for anish.lakhwara.com";
|
||||
|
||||
inputs = {
|
||||
nixpkgs.url = "github:nixos/nixpkgs";
|
||||
|
@ -8,14 +8,34 @@
|
|||
|
||||
outputs = { self, nixpkgs, flake-utils }:
|
||||
flake-utils.lib.eachDefaultSystem (system:
|
||||
let pkgs = nixpkgs.legacyPackages.${system};
|
||||
in {
|
||||
devShell = pkgs.mkShell {
|
||||
buildInputs = [
|
||||
pkgs.leiningen
|
||||
pkgs.jdk11
|
||||
pkgs.clojure
|
||||
];
|
||||
};
|
||||
});
|
||||
let
|
||||
pkgs = nixpkgs.legacyPackages.${system};
|
||||
my-python = pkgs.python3;
|
||||
python-with-my-packages = my-python.withPackages (p: with p; [
|
||||
icecream
|
||||
python-ctags3
|
||||
jinja2
|
||||
click
|
||||
pypandoc
|
||||
# other python packages you want
|
||||
]);
|
||||
in
|
||||
{
|
||||
devShell = pkgs.mkShell {
|
||||
buildInputs = [
|
||||
python-with-my-packages
|
||||
pkgs.pandoc
|
||||
];
|
||||
shellHook = ''
|
||||
PYTHONPATH=${python-with-my-packages}/${python-with-my-packages.sitePackages}
|
||||
# This only works when you have ~/vimwiki locally, since I'm not putting my unfiltered kitaab online
|
||||
alias build='python3 src/kitaab-public/main.py'
|
||||
# maybe set more env-vars
|
||||
'';
|
||||
};
|
||||
defaultPackage = pkgs.buildPythonPackage {
|
||||
# We should probably only call grab from main.py here
|
||||
|
||||
};
|
||||
});
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue