Make device conf search relative to the current project

This commit is contained in:
TakeV 2023-03-29 16:10:55 -07:00
parent d1dc7fcc41
commit 0351d2098d
Signed by: TakeV
GPG Key ID: A64F41345C7400AF
1 changed files with 2 additions and 1 deletions

View File

@ -1,12 +1,13 @@
# welcome to saturnOS config, run nixos-help if you need it .
{ config, pkgs, lib, ... }:
let
PROJECT_ROOT = builtins.toString ./.;
unstableTarball = builtins.fetchTarball
"https://github.com/NixOS/nixpkgs/archive/nixos-unstable.tar.gz";
homeManagerTarball = builtins.fetchTarball
"https://github.com/nix-community/home-manager/archive/master.tar.gz";
homeManager = import "${homeManagerTarball}/nixos";
deviceConf = import "/home/${sysConf.user}/.saturn/hosts/${sysConf.host}/";
deviceConf = import "${PROJECT_ROOT}/hosts/${sysConf.host}/";
unstable = import unstableTarball config.nixpkgs.config;
sysConf = import ./saturn/system.nix;
in {