Skip to content

Commit

Permalink
slacky: init at 0.0.5
Browse files Browse the repository at this point in the history
  • Loading branch information
awwpotato committed Jan 23, 2025
1 parent a460792 commit 78e82bb
Showing 1 changed file with 66 additions and 0 deletions.
66 changes: 66 additions & 0 deletions pkgs/by-name/sl/slacky/package.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,66 @@
{
lib,
buildNpmPackage,
fetchFromGitHub,
electron,
copyDesktopItems,
makeDesktopItem,
}:
buildNpmPackage rec {
pname = "slacky";
version = "0.0.5";

src = fetchFromGitHub {
owner = "andirsun";
repo = "Slacky";
tag = "v${version}";
hash = "sha256-nDxmzZqi7xEe4hnY6iXJg+613lSKElWxvF3w8bRDW90=";
};

npmDepsHash = "sha256-9+4cxeQw2Elug+xIgzNvpaSMgDVlBFz/+TW1jJwDm40=";

npmPackFlags = [ "--ignore-scripts" ];

NODE_OPTIONS = "--openssl-legacy-provider";

nativeBuildInputs = [
electron
copyDesktopItems
];

env.ELECTRON_SKIP_BINARY_DOWNLOAD = "1";

postInstall = ''
mkdir -p $out/share/icons
ln -s $out/lib/node_modules/${pname}/build/icons/icon.png $out/share/icons/${pname}.png
makeWrapper ${electron}/bin/electron $out/bin/${pname} \
--add-flags $out/lib/node_modules/${pname}/
'';

desktopItems = lib.singleton (makeDesktopItem {
name = "slacky";
exec = "slacky %u";
icon = "slacky";
desktopName = "Slacky";
comment = "An unofficial Slack desktop client for arm64 Linux";
startupWMClass = "com.andersonlaverde.slacky";
type = "Application";
categories = [
"Network"
"InstantMessaging"
];
mimeTypes = [
"x-scheme-handler/slack"
];
});

meta = {
description = "Unofficial Slack desktop client for arm64 Linux";
homepage = "https://github.com/andirsun/Slacky";
changelog = "https://github.com/andirsun/Slacky/releases/tag/v${version}";
license = lib.licenses.mit;
maintainers = with lib.maintainers; [ awwpotato ];
platforms = [ "aarch64-linux" ];
mainProgram = "slacky";
};
}

0 comments on commit 78e82bb

Please sign in to comment.