mirror of
https://github.com/keanuplayz/dotfiles.git
synced 2024-08-15 02:33:12 +00:00
Compare commits
No commits in common. "fdcefe5c7e2efe9d875529b9bbb92fa49cbfe60b" and "8b82caf336465850e381790c172483a2ec491360" have entirely different histories.
fdcefe5c7e
...
8b82caf336
2 changed files with 15 additions and 35 deletions
|
@ -1,6 +1,5 @@
|
||||||
{ pkgs, specialArgs, lib, dotfiles, ... }:
|
{ pkgs, lib, dotfiles, ... }:
|
||||||
|
|
||||||
with lib;
|
|
||||||
let
|
let
|
||||||
textEditor = "nvim";
|
textEditor = "nvim";
|
||||||
|
|
||||||
|
@ -67,14 +66,9 @@ let
|
||||||
ffmpeg
|
ffmpeg
|
||||||
];
|
];
|
||||||
|
|
||||||
fonts = [
|
everything = system ++ base ++ languages ++ programs ++ multimedia;
|
||||||
nerdfonts
|
|
||||||
];
|
|
||||||
|
|
||||||
everything = system ++ base ++ languages ++ programs ++ multimedia ++ fonts;
|
|
||||||
};
|
};
|
||||||
|
|
||||||
# Old solution kept for posterity {{{
|
|
||||||
# We've got a small issue here. I tested this in a repl, and what I've
|
# We've got a small issue here. I tested this in a repl, and what I've
|
||||||
# observed is that listFilesRecursive spits out [ /full/path/to/default.nix ],
|
# observed is that listFilesRecursive spits out [ /full/path/to/default.nix ],
|
||||||
# while builtins.readDir spits out { "default.nix" = "regular"; }
|
# while builtins.readDir spits out { "default.nix" = "regular"; }
|
||||||
|
@ -92,30 +86,19 @@ let
|
||||||
# be generated from the entire directory listing, it isn't going to work out.
|
# be generated from the entire directory listing, it isn't going to work out.
|
||||||
# The solution was slightly modified from this Reddit answer:
|
# The solution was slightly modified from this Reddit answer:
|
||||||
# <https://www.reddit.com/r/NixOS/comments/j5pa9o/comment/g81dvop/>
|
# <https://www.reddit.com/r/NixOS/comments/j5pa9o/comment/g81dvop/>
|
||||||
|
# So, let's get all files in the current directory...
|
||||||
|
importMap = map
|
||||||
|
(n: "${n}")
|
||||||
|
(lib.filesystem.listFilesRecursive ./.);
|
||||||
# importMap = map
|
# importMap = map
|
||||||
# (n: "${n}")
|
# (n: "${./.}/${n}")
|
||||||
# (lib.filesystem.listFilesRecursive ./.);
|
# (builtins.attrNames (builtins.readDir ./.));
|
||||||
# importsFiltered =
|
|
||||||
# builtins.filter
|
|
||||||
# (x: !lib.strings.hasInfix "default" x)
|
|
||||||
# importMap;
|
|
||||||
# }}}
|
|
||||||
|
|
||||||
getDir = dir: mapAttrs
|
# And filter out default.nix
|
||||||
(file: type:
|
importsFiltered =
|
||||||
if type == "directory" then getDir "${dir}/${file}" else type
|
builtins.filter
|
||||||
)
|
(x: !lib.strings.hasInfix "default" x)
|
||||||
(builtins.readDir dir);
|
importMap;
|
||||||
|
|
||||||
files = dir: collect isString (mapAttrsRecursive
|
|
||||||
(path: type: concatStringsSep "/" path)
|
|
||||||
(getDir dir));
|
|
||||||
|
|
||||||
validFiles = dir: map
|
|
||||||
(file: ./. + "/${file}")
|
|
||||||
(filter
|
|
||||||
(file: hasSuffix ".nix" file && file != "default.nix")
|
|
||||||
(files dir));
|
|
||||||
|
|
||||||
in
|
in
|
||||||
{
|
{
|
||||||
|
@ -144,8 +127,8 @@ in
|
||||||
useUserPackages = true;
|
useUserPackages = true;
|
||||||
extraSpecialArgs = { inherit dotfiles; };
|
extraSpecialArgs = { inherit dotfiles; };
|
||||||
users.alyxia = { pkgs, ... }: {
|
users.alyxia = { pkgs, ... }: {
|
||||||
# Defined further above, generates a list of files to import.
|
# Defined further above, a list of files to import.
|
||||||
imports = validFiles ./.;
|
imports = importsFiltered;
|
||||||
|
|
||||||
home = {
|
home = {
|
||||||
packages = packageSets.everything;
|
packages = packageSets.everything;
|
||||||
|
@ -205,7 +188,6 @@ in
|
||||||
"itch"
|
"itch"
|
||||||
"iterm2"
|
"iterm2"
|
||||||
"obs"
|
"obs"
|
||||||
"plexamp"
|
|
||||||
"raycast"
|
"raycast"
|
||||||
"sequel-ace"
|
"sequel-ace"
|
||||||
"shottr"
|
"shottr"
|
||||||
|
|
|
@ -8,8 +8,6 @@
|
||||||
source ${dotfiles}/zsh/zshrc
|
source ${dotfiles}/zsh/zshrc
|
||||||
|
|
||||||
export PATH="$PATH:$HOME/.npm-packages/bin"
|
export PATH="$PATH:$HOME/.npm-packages/bin"
|
||||||
export FRENYARD_SCALE=2.40
|
|
||||||
export RETHINK_API="https://rethink.alyxia.dev"
|
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue