feat: simplify flake.nix

This commit is contained in:
Ryan Yin
2023-07-26 20:07:42 +08:00
parent eebbb9f5e6
commit 204cb03922
70 changed files with 1183 additions and 1165 deletions
+2 -4
View File
@@ -1,8 +1,6 @@
{ pkgs, ... }:
{
{pkgs, ...}: {
##########################################################################
#
#
# MacOS specific home configuration
#
##########################################################################
+4 -6
View File
@@ -1,9 +1,7 @@
{ ... }:
{
{ username, ... }: {
imports = [
../base/desktop
./core.nix
./nushell.nix
./rime-squirrel.nix
@@ -12,9 +10,9 @@
# Home Manager needs a bit of information about you and the
# paths it should manage.
home = {
username = "ryan";
username = username;
# set homeDirectory make build fail
homeDirectory = "/Users/ryan";
homeDirectory = "/Users/${username}";
# This value determines the Home Manager release that your
# configuration is compatible with. This helps avoid breakage
+2 -2
View File
@@ -1,4 +1,4 @@
{ config, ... }: {
{config, ...}: {
# nix-darwin do not set PATH for nushell! so we need to do it manually
# this is a workaround to add nix's PATH to nushell
programs.nushell.extraConfig = ''
@@ -15,4 +15,4 @@
($env.PATH | split row (char esep))
] | flatten)
'';
}
}
+5 -3
View File
@@ -1,8 +1,10 @@
{ lib, pkgs, ... }:
{
lib,
pkgs,
...
}: {
# remove existing rime data (squirrel)
home.activation.removeExistingRimeData = lib.hm.dag.entryBefore [ "checkLinkTargets" ] ''
home.activation.removeExistingRimeData = lib.hm.dag.entryBefore ["checkLinkTargets"] ''
rm -rf "~/Library/Rime/build/flypy.prism.bin"
'';