nix-config/home/nixpkgs/default.nix
Bruno BELANYI caa8357db8
All checks were successful
ci/woodpecker/push/check Pipeline was successful
home: nixpkgs: define 'GITHUB_API_TOKEN'
Turns out the nixpkgs scripts are not consistent in which environment
variable they expect to be defined...
2023-07-17 09:57:24 +00:00

21 lines
465 B
Nix

{ config, lib, pkgs, ... }:
let
cfg = config.my.home.nixpkgs;
in
{
options.my.home.nixpkgs = with lib; {
enable = mkEnableOption "nixpkgs configuration";
};
config = lib.mkIf cfg.enable {
home.packages = with pkgs; [
nixpkgs-review
];
home.sessionVariables = {
GITHUB_TOKEN = ''$(cat "${config.age.secrets."github/token".path}")'';
GITHUB_API_TOKEN = ''$(cat "${config.age.secrets."github/token".path}")'';
};
};
}