This commit is contained in:
Motiejus Jakštys 2024-12-07 22:09:32 +02:00
parent 97c575cf1a
commit 6aed3374e3
3 changed files with 2 additions and 74 deletions

24
flake.lock generated
View File

@ -187,29 +187,6 @@
"type": "github"
}
},
"nixgl": {
"inputs": {
"flake-utils": [
"flake-utils"
],
"nixpkgs": [
"nixpkgs"
]
},
"locked": {
"lastModified": 1713543440,
"narHash": "sha256-lnzZQYG0+EXl/6NkGpyIz+FEOc/DSEG57AP1VsdeNrM=",
"owner": "guibou",
"repo": "nixGL",
"rev": "310f8e49a149e4c9ea52f1adf70cdc768ec53f8a",
"type": "github"
},
"original": {
"owner": "guibou",
"repo": "nixGL",
"type": "github"
}
},
"nixos-hardware": {
"locked": {
"lastModified": 1733481457,
@ -333,7 +310,6 @@
"home-manager": "home-manager",
"kolide-launcher": "kolide-launcher",
"nix-index-database": "nix-index-database",
"nixgl": "nixgl",
"nixos-hardware": "nixos-hardware",
"nixpkgs": "nixpkgs",
"nixpkgs-unstable": "nixpkgs-unstable",

View File

@ -30,14 +30,6 @@
};
};
nixgl = {
url = "github:guibou/nixGL";
inputs = {
nixpkgs.follows = "nixpkgs";
flake-utils.follows = "flake-utils";
};
};
zig = {
url = "github:mitchellh/zig-overlay";
inputs = {
@ -89,7 +81,6 @@
pre-commit-hooks,
nur,
zig,
nixgl,
kolide-launcher,
...
}@inputs:
@ -97,9 +88,8 @@
myData = import ./data.nix;
overlays = [
nur.overlay
nur.overlays.default
zig.overlays.default
nixgl.overlay
(_self: super: { deploy-rs-pkg = super.deploy-rs; })
deploy-rs.overlay

View File

@ -9,43 +9,6 @@
...
}:
let
# from https://github.com/Gerg-L/demoninajar/blob/39964f198dbfa34c21f81c35370fab312b476051/homes/veritas_manjaro/nixGL.nix#L42
mkWrapped =
wrap: orig-pkg: execName:
pkgs.makeOverridable (
attrs:
let
pkg = orig-pkg.override attrs;
outs = pkg.meta.outputsToInstall;
paths = pkgs.lib.attrsets.attrVals outs pkg;
nonTrivialOuts = pkgs.lib.lists.remove "out" outs;
metaAttributes = pkgs.lib.attrsets.getAttrs (
[
"name"
"pname"
"version"
"meta"
]
++ nonTrivialOuts
) pkg;
in
pkgs.symlinkJoin (
{
inherit paths;
nativeBuildInputs = [ pkgs.makeWrapper ];
postBuild = ''
mv $out/bin/${execName} $out/bin/.${execName}-mkWrapped-original
makeWrapper \
${wrap}/bin/${wrap.name} $out/bin/${execName} \
--add-flags $out/bin/.${execName}-mkWrapped-original
'';
}
// metaAttributes
)
) { };
glintel = mkWrapped pkgs.nixgl.nixGLIntel;
firefox =
if (pkgs.stdenv.hostPlatform.system == "x86_64-linux") then pkgs.firefox-bin else pkgs.firefox;
homeDirectory = "/home/${username}";
in
{
@ -109,8 +72,7 @@ in
};
firefox = lib.mkIf devTools {
enable = true;
# firefox doesn't need the wrapper on the personal laptop
package = if hmOnly then (glintel firefox "firefox") else firefox;
package = pkgs.firefox-bin;
policies.DisableAppUpdate = true;
profiles = {
xdefault = {