File tree Expand file tree Collapse file tree 1 file changed +12
-0
lines changed Expand file tree Collapse file tree 1 file changed +12
-0
lines changed Original file line number Diff line number Diff line change 1
1
{
2
+ # Description of the application
2
3
description = "A tool for viewing and editing your nix configuration as a tree" ;
3
4
5
+ # Importing nixpkgs (the package repository) and poetry for building the application
4
6
inputs = {
5
7
nixpkgs . url = "github:NixOS/nixpkgs/nixos-unstable" ;
6
8
poetry2nix . url = "github:nix-community/poetry2nix" ;
7
9
} ;
8
10
9
11
outputs = { self , nixpkgs , poetry2nix } :
10
12
let
13
+ # Setting system to 64 bit linux
11
14
system = "x86_64-linux" ;
15
+
16
+ # Adding poetry to our nixpkgs, and setting the pkgs variable as this
12
17
pkgs = nixpkgs . legacyPackages . ${ system } . extend poetry2nix . overlays . default ;
18
+
19
+ # Setting the lib variable (for licenses and maintainers)
13
20
lib = nixpkgs . lib ;
21
+
22
+ # Extract mkPoetryApplication from mkPoetry2Nix for buikding our application
14
23
inherit ( poetry2nix . lib . mkPoetry2Nix { inherit pkgs ; } ) mkPoetryApplication ;
15
24
in
16
25
{
26
+ # The section that builds our application
17
27
defaultPackage . x86_64-linux = mkPoetryApplication {
18
28
type = "app" ;
29
+
30
+ # The project is found at the root of the repository
19
31
projectDir = ./. ;
20
32
21
33
# To copy over the full options json
You can’t perform that action at this time.
0 commit comments