2022-10-28 17:51:20 -06:00
|
|
|
{
|
|
|
|
description = "xintray: a status indicator that lives in the tray";
|
|
|
|
|
2023-03-03 06:14:05 -07:00
|
|
|
inputs.nixpkgs.url = "nixpkgs/nixos-unstable";
|
2022-10-28 17:51:20 -06:00
|
|
|
|
|
|
|
outputs = { self, nixpkgs }:
|
|
|
|
let
|
|
|
|
supportedSystems =
|
|
|
|
[ "x86_64-linux" "x86_64-darwin" "aarch64-linux" "aarch64-darwin" ];
|
|
|
|
forAllSystems = nixpkgs.lib.genAttrs supportedSystems;
|
|
|
|
nixpkgsFor = forAllSystems (system: import nixpkgs { inherit system; });
|
|
|
|
in {
|
|
|
|
packages = forAllSystems (system:
|
|
|
|
let pkgs = nixpkgsFor.${system};
|
|
|
|
|
|
|
|
in {
|
2023-06-29 08:06:51 -06:00
|
|
|
xintray = with pkgs;
|
|
|
|
buildGo120Module rec {
|
|
|
|
pname = "xintray";
|
2023-09-05 06:35:42 -06:00
|
|
|
version = "v0.1.15";
|
2023-06-29 08:06:51 -06:00
|
|
|
src = ./.;
|
2022-10-28 17:51:20 -06:00
|
|
|
|
2023-06-29 08:06:51 -06:00
|
|
|
vendorHash =
|
2023-09-01 14:44:22 -06:00
|
|
|
"sha256-8ZdFY+uaLgUDgWCcg7NSy9KjUwmSDo+E+GaMYki51tQ=";
|
2023-06-29 08:06:51 -06:00
|
|
|
proxyVendor = true;
|
2022-10-28 17:51:20 -06:00
|
|
|
|
2023-06-29 08:06:51 -06:00
|
|
|
nativeBuildInputs = [ pkg-config copyDesktopItems ];
|
|
|
|
buildInputs = [
|
|
|
|
git
|
|
|
|
glfw
|
|
|
|
libGL
|
|
|
|
libGLU
|
|
|
|
openssh
|
|
|
|
pkg-config
|
|
|
|
xorg.libXcursor
|
|
|
|
xorg.libXi
|
|
|
|
xorg.libXinerama
|
|
|
|
xorg.libXrandr
|
|
|
|
xorg.libXxf86vm
|
|
|
|
xorg.xinput
|
|
|
|
];
|
|
|
|
|
|
|
|
desktopItems = [
|
|
|
|
(makeDesktopItem {
|
|
|
|
name = "Xin Tray";
|
|
|
|
exec = pname;
|
|
|
|
icon = pname;
|
|
|
|
desktopName = pname;
|
|
|
|
})
|
|
|
|
];
|
|
|
|
|
|
|
|
postInstall = ''
|
|
|
|
mkdir -p $out/share/
|
|
|
|
cp -r icons $out/share/
|
|
|
|
'';
|
|
|
|
};
|
2022-10-28 17:51:20 -06:00
|
|
|
});
|
|
|
|
|
|
|
|
defaultPackage = forAllSystems (system: self.packages.${system}.xintray);
|
|
|
|
devShells = forAllSystems (system:
|
|
|
|
let pkgs = nixpkgsFor.${system};
|
|
|
|
in {
|
|
|
|
default = pkgs.mkShell {
|
|
|
|
shellHook = ''
|
|
|
|
PS1='\u@\h:\@; '
|
2023-05-10 06:41:31 -06:00
|
|
|
nix run github:qbit/xin#flake-warn
|
2023-03-03 06:14:05 -07:00
|
|
|
echo "Go `${pkgs.go_1_20}/bin/go version`"
|
2022-10-28 17:51:20 -06:00
|
|
|
'';
|
|
|
|
buildInputs = with pkgs; [
|
|
|
|
git
|
2023-03-03 06:14:05 -07:00
|
|
|
go_1_20
|
2022-10-28 17:51:20 -06:00
|
|
|
gopls
|
|
|
|
go-tools
|
|
|
|
|
|
|
|
glfw
|
|
|
|
pkg-config
|
|
|
|
xorg.libXcursor
|
|
|
|
xorg.libXi
|
|
|
|
xorg.libXinerama
|
|
|
|
xorg.libXrandr
|
|
|
|
xorg.libXxf86vm
|
|
|
|
xorg.xinput
|
2023-06-27 20:07:15 -06:00
|
|
|
|
|
|
|
go-font
|
2022-10-28 17:51:20 -06:00
|
|
|
];
|
|
|
|
};
|
|
|
|
});
|
|
|
|
};
|
|
|
|
}
|
|
|
|
|