Initial add Pidgin for IM
I've added the following myself: * mattermost * purple-signald (waiting for https://github.com/NixOS/nixpkgs/issues/188384) * purple-events * purple-libnotify and added slack from nixpkgs. I'm also trying to make signal integration work. Not sure whether I'll keep pidgin, as I expect video calls from within slack not to work. But would be cool to have a single open source messenger instead of x instances of chromium as wrapper around closed source web applications.
This commit is contained in:
parent
dfc7938891
commit
6d5f3cc626
1
home.nix
1
home.nix
|
@ -6,6 +6,7 @@
|
|||
./home/modules/programs/cmus.nix
|
||||
./home/modules/programs/languagetool.nix
|
||||
./home/modules/programs/mailhog.nix
|
||||
./home/modules/programs/signald.nix
|
||||
];
|
||||
|
||||
home = {
|
||||
|
|
|
@ -5,4 +5,5 @@ _:
|
|||
".profile".source = ./files/profile;
|
||||
".myclirc".source = ./files/myclirc;
|
||||
".agignore".source = ./files/agignore;
|
||||
".purple/gtkrc-2.0".source = ./files/purple/gtkrc-2.0;
|
||||
}
|
||||
|
|
5
home/files/purple/gtkrc-2.0
Normal file
5
home/files/purple/gtkrc-2.0
Normal file
|
@ -0,0 +1,5 @@
|
|||
gtk-font-name = "Roboto Mono Medium 16"
|
||||
style "purplerc_style"
|
||||
{
|
||||
}
|
||||
widget_class "*" style "purplerc_style"
|
38
home/modules/programs/signald.nix
Normal file
38
home/modules/programs/signald.nix
Normal file
|
@ -0,0 +1,38 @@
|
|||
{ config, lib, pkgs, ... }:
|
||||
|
||||
with lib;
|
||||
|
||||
let
|
||||
cfg = config.programs.signald;
|
||||
in {
|
||||
options.programs.signald = {
|
||||
enable = mkEnableOption "signald";
|
||||
|
||||
package = mkOption {
|
||||
type = types.package;
|
||||
default = pkgs.signald;
|
||||
description = "signald package to install.";
|
||||
};
|
||||
};
|
||||
|
||||
config = mkIf cfg.enable {
|
||||
systemd.user.services.signald = {
|
||||
Unit = {
|
||||
Description = "A daemon for interacting with the Signal Private Messenger";
|
||||
Wants = "network.target";
|
||||
After = "network.target";
|
||||
};
|
||||
|
||||
Service = {
|
||||
Type = "simple";
|
||||
ExecStart = "${cfg.package}/bin/signald";
|
||||
Restart = "on-failure";
|
||||
SuccessExitStatus = "143";
|
||||
};
|
||||
|
||||
Install = {
|
||||
WantedBy = [ "multi-user.target" ];
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
41
home/packages/purple-events/default.nix
Normal file
41
home/packages/purple-events/default.nix
Normal file
|
@ -0,0 +1,41 @@
|
|||
{
|
||||
stdenv,
|
||||
fetchFromGitHub,
|
||||
meson,
|
||||
ninja,
|
||||
lib,
|
||||
pidgin,
|
||||
libnotify
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "purple-events";
|
||||
version = "v0.99.2";
|
||||
src = fetchFromGitHub {
|
||||
owner = "sardemff7";
|
||||
repo = "purple-events";
|
||||
rev = version;
|
||||
sha256 = "sha256-np1Wo9xqRclBY24Ww2WnQ1lxKEsRsM16BxinkfyPgKc=";
|
||||
};
|
||||
|
||||
postPatch = ''
|
||||
substituteInPlace meson.build \
|
||||
--replace "purple.get_variable('datadir')" "'${placeholder "out"}/share'"
|
||||
substituteInPlace meson.build \
|
||||
--replace "purple.get_variable('plugindir')" "'${placeholder "out"}/lib/purple-2'"
|
||||
'';
|
||||
|
||||
buildInputs = [
|
||||
meson
|
||||
pidgin
|
||||
libnotify
|
||||
ninja
|
||||
];
|
||||
|
||||
meta = with lib; {
|
||||
homepage = "https://github.com/sardemff7/purple-events";
|
||||
description = "purple-events allows a fine-grained control over libpurple events (buddy signing on, new message).";
|
||||
license = licenses.gpl3;
|
||||
platforms = platforms.linux;
|
||||
};
|
||||
}
|
0
home/packages/purple-events/patch-datadir.patch
Normal file
0
home/packages/purple-events/patch-datadir.patch
Normal file
43
home/packages/purple-libnotify/default.nix
Normal file
43
home/packages/purple-libnotify/default.nix
Normal file
|
@ -0,0 +1,43 @@
|
|||
{
|
||||
stdenv,
|
||||
fetchFromGitHub,
|
||||
callPackage,
|
||||
meson,
|
||||
ninja,
|
||||
lib,
|
||||
pidgin,
|
||||
libnotify
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "purple-libnotify+";
|
||||
version = "v2.99.2";
|
||||
src = fetchFromGitHub {
|
||||
owner = "sardemff7";
|
||||
repo = "purple-libnotify-plus";
|
||||
rev = version;
|
||||
sha256 = "sha256-967VKfRjy5eQiFda5mqW3eLqvuPqWEDoIsixhZNNmsU=";
|
||||
};
|
||||
|
||||
postPatch = ''
|
||||
substituteInPlace meson.build \
|
||||
--replace "purple.get_variable('datadir')" "'${placeholder "out"}/share'"
|
||||
substituteInPlace meson.build \
|
||||
--replace "purple.get_variable('plugindir')" "'${placeholder "out"}/lib/purple-2'"
|
||||
'';
|
||||
|
||||
buildInputs = [
|
||||
meson
|
||||
ninja
|
||||
pidgin
|
||||
libnotify
|
||||
(callPackage ./../purple-events {})
|
||||
];
|
||||
|
||||
meta = with lib; {
|
||||
homepage = "https://github.com/sardemff7/purple-libnotify-plus/";
|
||||
description = "Plugin for Pidgin which adds support for notifications via libnotify";
|
||||
license = licenses.gpl3;
|
||||
platforms = platforms.linux;
|
||||
};
|
||||
}
|
40
home/packages/purple-mattermost/default.nix
Normal file
40
home/packages/purple-mattermost/default.nix
Normal file
|
@ -0,0 +1,40 @@
|
|||
{
|
||||
stdenv,
|
||||
fetchFromGitHub,
|
||||
lib,
|
||||
git,
|
||||
pidgin,
|
||||
glib,
|
||||
json-glib,
|
||||
discount # markdown implementation
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "purple-mattermost";
|
||||
version = "v2.1";
|
||||
src = fetchFromGitHub {
|
||||
owner = "EionRobb";
|
||||
repo = "purple-mattermost";
|
||||
rev = version;
|
||||
leaveDotGit = true;
|
||||
sha256 = "sha256-/lFGr6s4R/LQ2N60b6lJwQjjIoZxZTiKupmHV1APl9A=";
|
||||
};
|
||||
|
||||
PKG_CONFIG_PURPLE_PLUGINDIR = "${placeholder "out"}/lib/purple-2";
|
||||
PKG_CONFIG_PURPLE_DATAROOTDIR = "${placeholder "out"}/share";
|
||||
|
||||
nativeBuildInputs = [
|
||||
git
|
||||
glib
|
||||
json-glib
|
||||
discount
|
||||
pidgin
|
||||
];
|
||||
|
||||
meta = with lib; {
|
||||
homepage = "https://github.com/EionRobb/purple-mattermost";
|
||||
description = "Plugin for Pidgin which adds support for Mattermost";
|
||||
license = licenses.gpl3;
|
||||
platforms = platforms.linux;
|
||||
};
|
||||
}
|
31
home/packages/purple-signald/default.nix
Normal file
31
home/packages/purple-signald/default.nix
Normal file
|
@ -0,0 +1,31 @@
|
|||
{ lib, stdenv, fetchFromGitHub, pidgin, json-glib, signald }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "purple-signald";
|
||||
version = "0.11.0";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "hoehermann";
|
||||
repo = "libpurple-signald";
|
||||
rev = "v${version}";
|
||||
sha256 = "sha256-2LiHjVRBwdPbfravIVM+gvsh3Gq4bhjtRD6eWAbkWmc=";
|
||||
fetchSubmodules = true;
|
||||
};
|
||||
|
||||
buildInputs = [
|
||||
pidgin
|
||||
json-glib
|
||||
signald
|
||||
];
|
||||
|
||||
PKG_CONFIG_PURPLE_PLUGINDIR = "${placeholder "out"}/lib/purple-2";
|
||||
PKG_CONFIG_PIDGIN_DATADIR = "${placeholder "out"}/share";
|
||||
|
||||
meta = with lib; {
|
||||
homepage = "https://github.com/hoehermann/libpurple-signald";
|
||||
description = "Signal support for Pidgin / libpurple";
|
||||
license = licenses.gpl3Only;
|
||||
platforms = platforms.linux;
|
||||
maintainers = with maintainers; [ hufman ];
|
||||
};
|
||||
}
|
|
@ -49,6 +49,11 @@ in {
|
|||
firefox = import ./programs/firefox.nix {
|
||||
};
|
||||
|
||||
pidgin = import ./programs/pidgin.nix {
|
||||
inherit pkgs;
|
||||
};
|
||||
signald.enable = true;
|
||||
|
||||
# Media
|
||||
cmus.enable = true;
|
||||
}
|
||||
|
|
17
home/programs/pidgin.nix
Normal file
17
home/programs/pidgin.nix
Normal file
|
@ -0,0 +1,17 @@
|
|||
{ pkgs }:
|
||||
|
||||
{
|
||||
enable = true;
|
||||
|
||||
plugins = [
|
||||
pkgs.pidgin-window-merge
|
||||
pkgs.purple-slack
|
||||
# Waiting for https://github.com/NixOS/nixpkgs/issues/188384 to switch back to official package
|
||||
# pkgs.purple-signald
|
||||
(pkgs.callPackage ./../packages/purple-signald { })
|
||||
(pkgs.callPackage ./../packages/purple-mattermost { })
|
||||
(pkgs.callPackage ./../packages/purple-libnotify { })
|
||||
(pkgs.callPackage ./../packages/purple-events { }) # Dependency
|
||||
];
|
||||
|
||||
}
|
Loading…
Reference in a new issue