-
Notifications
You must be signed in to change notification settings - Fork 101
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
110 changed files
with
3,696 additions
and
3,111 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,78 +1,85 @@ | ||
{ | ||
description = "A Bar/Panel for Hyprland with extensive customizability."; | ||
|
||
inputs = { | ||
nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable"; | ||
ags.url = "github:Aylur/ags"; | ||
nixpkgs.url = "github:nixos/nixpkgs?ref=nixos-unstable"; | ||
ags.url = "github:aylur/ags"; | ||
astal.url = "github:aylur/astal"; | ||
}; | ||
|
||
outputs = inputs: let | ||
outputs = { self, nixpkgs, ags, astal }: let | ||
systems = [ | ||
"x86_64-linux" | ||
"x86_64-darwin" | ||
"aarch64-darwin" | ||
"aarch64-linux" | ||
]; | ||
forEachSystem = inputs.nixpkgs.lib.genAttrs systems; | ||
pkgsFor = forEachSystem ( | ||
system: | ||
import inputs.nixpkgs { | ||
inherit system; | ||
config.allowUnfree = true; | ||
} | ||
); | ||
|
||
devShellFor = system: | ||
inputs.nixpkgs.lib.genAttrs ["default"] ( | ||
_: | ||
inputs.nixpkgs.legacyPackages.${system}.mkShell { | ||
buildInputs = [ | ||
pkgsFor.${system}.esbuild | ||
pkgsFor.${system}.fish | ||
pkgsFor.${system}.typescript | ||
pkgsFor.${system}.bun | ||
pkgsFor.${system}.libnotify | ||
pkgsFor.${system}.dart-sass | ||
pkgsFor.${system}.fd | ||
pkgsFor.${system}.btop | ||
pkgsFor.${system}.bluez | ||
pkgsFor.${system}.libgtop | ||
pkgsFor.${system}.gobject-introspection | ||
pkgsFor.${system}.glib | ||
pkgsFor.${system}.bluez-tools | ||
pkgsFor.${system}.grimblast | ||
pkgsFor.${system}.gpu-screen-recorder | ||
pkgsFor.${system}.brightnessctl | ||
pkgsFor.${system}.gnome-bluetooth | ||
pkgsFor.${system}.python3 | ||
pkgsFor.${system}.matugen | ||
inputs.ags.packages.${system}.agsWithTypes | ||
]; | ||
nativeBuildInputs = with pkgsFor.${system}; [ | ||
nixfmt-rfc-style | ||
nil | ||
]; | ||
shellHook = '' | ||
export GDK_BACKEND=wayland | ||
export GI_TYPELIB_PATH=${pkgsFor.${system}.libgtop}/lib/girepository-1.0:${pkgsFor.${system}.glib}/lib/girepository-1.0:$GI_TYPELIB_PATH | ||
''; | ||
} | ||
); | ||
forEachSystem = nixpkgs.lib.genAttrs systems; | ||
in { | ||
devShells = forEachSystem devShellFor; | ||
packages = forEachSystem (system: let | ||
pkgs = nixpkgs.legacyPackages.${system}; | ||
in { | ||
default = ags.lib.bundle { | ||
inherit pkgs; | ||
src = ./.; | ||
name = "hyprpanel"; # name of executable | ||
entry = "app.ts"; | ||
|
||
# additional libraries and executables to add to gjs' runtime | ||
extraPackages = [ | ||
ags.packages.${system}.agsFull | ||
astal.packages.${system}.tray | ||
astal.packages.${system}.hyprland | ||
astal.packages.${system}.io | ||
astal.packages.${system}.apps | ||
astal.packages.${system}.battery | ||
astal.packages.${system}.bluetooth | ||
astal.packages.${system}.mpris | ||
astal.packages.${system}.network | ||
astal.packages.${system}.notifd | ||
astal.packages.${system}.powerprofiles | ||
astal.packages.${system}.wireplumber | ||
pkgs.fish | ||
pkgs.typescript | ||
pkgs.libnotify | ||
pkgs.dart-sass | ||
pkgs.fd | ||
pkgs.btop | ||
pkgs.bluez | ||
pkgs.libgtop | ||
pkgs.gobject-introspection | ||
pkgs.glib | ||
pkgs.bluez-tools | ||
pkgs.grimblast | ||
pkgs.gpu-screen-recorder | ||
pkgs.brightnessctl | ||
pkgs.gnome-bluetooth | ||
(pkgs.python3.withPackages (python-pkgs: with python-pkgs; [ | ||
gpustat | ||
dbus-python | ||
pygobject3 | ||
])) | ||
pkgs.matugen | ||
pkgs.hyprpicker | ||
pkgs.hyprsunset | ||
pkgs.hypridle | ||
pkgs.wireplumber | ||
pkgs.networkmanager | ||
pkgs.upower | ||
pkgs.gvfs | ||
pkgs.swww | ||
pkgs.pywal | ||
]; | ||
}; | ||
}); | ||
|
||
# Define .overlay to expose the package as pkgs.hyprpanel based on the system | ||
overlay = final: prev: { | ||
hyprpanel = | ||
if final ? callPackage | ||
then (final.callPackage ./nix {inherit inputs;}).desktop.script | ||
else inputs.self.packages.${prev.stdenv.system}.default; | ||
hyprpanel = prev.writeShellScriptBin "hyprpanel" '' | ||
if [ "$#" -eq 0 ]; then | ||
exec ${self.packages.${final.stdenv.system}.default}/bin/hyprpanel | ||
else | ||
exec ${astal.packages.${final.stdenv.system}.io}/bin/astal -i hyprpanel "$@" | ||
fi | ||
''; | ||
}; | ||
packages = forEachSystem ( | ||
system: let | ||
pkgs = pkgsFor.${system}; | ||
in { | ||
default = (pkgs.callPackage ./nix {inherit inputs;}).desktop.script; | ||
} | ||
); | ||
}; | ||
} |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.