import -> callPackage

This commit is contained in:
EdenQwQ 2025-03-14 10:05:43 +08:00
parent 835edc5466
commit 5522f31f19
6 changed files with 14 additions and 26 deletions

View file

@ -3,7 +3,7 @@ let
colors = config.lib.stylix.colors.withHashtag;
in
{
home.packages = with (import ../../../pkgs/R.nix pkgs); [
home.packages = with (pkgs.callPackage ../../../pkgs/R.nix { }); [
(config.lib.misc.addFlags
"--enable-features=UseOzonePlatform --ozone-platform=wayland --use-gl=angle --wayland-text-input-version=3"
"rstudio"

View file

@ -1,13 +1,7 @@
{ pkgs, lib, ... }:
{
home.packages = [
(import ../../../pkgs/fonts/kose.nix {
inherit pkgs lib;
inherit (pkgs) stdenvNoCC;
})
(import ../../../pkgs/fonts/hugmetight.nix {
inherit pkgs lib;
inherit (pkgs) stdenvNoCC;
})
(pkgs.callPackage ../../../pkgs/fonts/kose.nix { })
(pkgs.callPackage ../../../pkgs/fonts/hugmetight.nix { })
];
}

View file

@ -1,8 +1,6 @@
{ pkgs, ... }:
let
zju-connect = import ../../../pkgs/zju-connect.nix {
inherit (pkgs) lib buildGoModule fetchFromGitHub;
};
zju-connect = pkgs.callPackage ../../../pkgs/zju-connect.nix { };
zjuconnect = pkgs.writeShellScriptBin "zjuconnect" ''exec ${zju-connect}/bin/zju-connect --config ~/.config/zju-connect/config.toml'';
in
{

View file

@ -4,7 +4,7 @@
...
}:
let
edenfetch = import ../../../pkgs/edenfetch.nix { inherit (pkgs) lib fetchFromGitHub rustPlatform; };
edenfetch = pkgs.callPackage ../../../pkgs/edenfetch.nix { };
in
{
home.packages = with pkgs; [

View file

@ -1,14 +1,6 @@
{ pkgs, ... }:
let
swhkd = import ../../pkgs/swhkd.nix {
inherit (pkgs)
lib
rustPlatform
fetchFromGitHub
pkg-config
udev
;
};
swhkd = pkgs.callPackage ../../pkgs/swhkd.nix { };
in
{
environment.systemPackages = [

View file

@ -1,6 +1,10 @@
pkgs:
{
rPackages,
rWrapper,
rstudioWrapper,
}:
let
rPkgs = with pkgs.rPackages; [
rPkgs = with rPackages; [
ggplot2
dplyr
tidyverse
@ -13,10 +17,10 @@ let
];
in
{
myR = pkgs.rWrapper.override {
myR = rWrapper.override {
packages = rPkgs;
};
myRstudio = pkgs.rstudioWrapper.override {
myRstudio = rstudioWrapper.override {
packages = rPkgs;
};
}